Skip to content

Commit 129a70a

Browse files
committed
dt-bindings: mtd: denali: Prevent NAND chip unevaluated properties
Ensure all raw NAND chip properties are valid by referencing the relevant schema and set unevaluatedProperties to false in the NAND chip section to avoid spurious additions of random properties. Doing this in one location also saves us from dupplicating the description of the NAND chip object. Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/linux-mtd/20230619092916.3028470-12-miquel.raynal@bootlin.com
1 parent 74b7e3b commit 129a70a

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

Documentation/devicetree/bindings/mtd/denali,nand.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,12 @@ properties:
6363
minItems: 1
6464
maxItems: 2
6565

66+
patternProperties:
67+
"^nand@[a-f0-9]$":
68+
type: object
69+
$ref: raw-nand-chip.yaml
70+
unevaluatedProperties: false
71+
6672
allOf:
6773
- $ref: nand-controller.yaml
6874

@@ -74,7 +80,6 @@ allOf:
7480
then:
7581
patternProperties:
7682
"^nand@[a-f0-9]$":
77-
type: object
7883
properties:
7984
nand-ecc-strength:
8085
enum:
@@ -92,7 +97,6 @@ allOf:
9297
then:
9398
patternProperties:
9499
"^nand@[a-f0-9]$":
95-
type: object
96100
properties:
97101
nand-ecc-strength:
98102
enum:
@@ -111,7 +115,6 @@ allOf:
111115
then:
112116
patternProperties:
113117
"^nand@[a-f0-9]$":
114-
type: object
115118
properties:
116119
nand-ecc-strength:
117120
enum:

0 commit comments

Comments
 (0)