From nobody Mon Feb 9 03:13:51 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 326E53D6677; Wed, 21 Jan 2026 19:57:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769025424; cv=none; b=U8EYxP7ju0n1MyLQfgiak9nWL7YAGkFcvHy9HeWLN2CVuzYBQoa3WeUwmgzozdqgEW4D3MZ6m4ijIWgtQ2WBcWceEXKYDjxoalIGKM7rANDNlaf/zInvZ2TogYhFkPd9GwMNbe6pYeUgBwlnfqX7RBlTvoun193/OxsevAyaMjI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769025424; c=relaxed/simple; bh=bA0IrXZIRAmvLVMEUnj2msq0bjns/r0LlSygkXY7W14=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ElySa7p+v6K5x5QsCCW8g27Ayh7ESypHIKrGI/BXVdbCLhLaWEFCwc2xfTAF/nBwdIGD0solDnA6gQXlqtfjWV/BgcfZSNFwPdd6Mgohe6nQ9Wrqua9xtVrz7Q3d44PUvGPW7jUIJ14lrv3NA1KaLb0bSXplawWMa82z6fis+mI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=ru4sJb+a; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="ru4sJb+a" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C862DC4CEF1; Wed, 21 Jan 2026 19:57:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1769025422; bh=bA0IrXZIRAmvLVMEUnj2msq0bjns/r0LlSygkXY7W14=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=ru4sJb+aJUJEHhmUlzhvQv36xoUGNyPg+YRCDt4jJBk0qYnPq6baZoCfgzYB3Gl5y owypAn504JSqmytb9A9I7TZ3kSJFtk+2TAsNkRhcdcHOA9VB//gD069/DzpU0/T5Ia MVnIyQcsIvG9+Zq/iEjRC5/D8F3zC9tL1E70um/6I1D/iDKuhkCVrnU9b0INMqoCrh JVUBgg/ATkL2p99x5eDOU8ZUdDqO2idOuBdlFajKBg9M4MTHUKUDvanXewwNMAz8we rK+S8Tb54JolMRoYhafvB1buf6uSML9xfUERS85XoSRCCbEkf8KJdK7PeCVSM5smAX 8yns/iR/aMHcg== From: "Rob Herring (Arm)" Date: Wed, 21 Jan 2026 13:56:40 -0600 Subject: [PATCH v3 07/10] dt-bindings: mtd: Ensure partition node properties are documented Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260121-dt-mtd-partitions-v3-7-ec3af93c8f93@kernel.org> References: <20260121-dt-mtd-partitions-v3-0-ec3af93c8f93@kernel.org> In-Reply-To: <20260121-dt-mtd-partitions-v3-0-ec3af93c8f93@kernel.org> To: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Krzysztof Kozlowski , Conor Dooley , Brian Norris , Kamal Dasu , William Zhang , Nick Terrell , David Sterba , =?utf-8?q?Rafa=C5=82_Mi=C5=82ecki?= , Simon Glass , Linus Walleij , Ulf Hansson , Marcus Folkesson , Tony Lindgren , Roger Quadros , Hauke Mehrtens Cc: linux-mtd@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org, Krzysztof Kozlowski X-Mailer: b4 0.15-dev Partition nodes without a compatible have no restrictions on additional properties. Fix this by ensuring 'unevaluatedProperties' is set when there's no compatible property. If there is a compatible property, then there should be a specific schema for it which will enforce 'unevaluatedProperties'. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Rob Herring (Arm) --- Documentation/devicetree/bindings/mtd/mtd.yaml | 8 ++------ .../devicetree/bindings/mtd/partitions/fixed-partitions.yaml | 2 +- .../devicetree/bindings/mtd/partitions/partition.yaml | 12 ++++++++= ++++ .../mtd/partitions/tplink,safeloader-partitions.yaml | 2 +- Documentation/devicetree/bindings/mtd/partitions/u-boot.yaml | 2 +- Documentation/devicetree/bindings/mtd/ti,gpmc-onenand.yaml | 2 +- 6 files changed, 18 insertions(+), 10 deletions(-) diff --git a/Documentation/devicetree/bindings/mtd/mtd.yaml b/Documentation= /devicetree/bindings/mtd/mtd.yaml index e56dba83f00a..5a2d06c96c0d 100644 --- a/Documentation/devicetree/bindings/mtd/mtd.yaml +++ b/Documentation/devicetree/bindings/mtd/mtd.yaml @@ -36,12 +36,8 @@ properties: - compatible =20 patternProperties: - "@[0-9a-f]+$": - $ref: partitions/partition.yaml - deprecated: true - - "^partition@[0-9a-f]+": - $ref: partitions/partition.yaml + "(^partition)?@[0-9a-f]+$": + $ref: /schemas/mtd/partitions/partition.yaml#/$defs/partition-node deprecated: true =20 "^otp(-[0-9]+)?$": diff --git a/Documentation/devicetree/bindings/mtd/partitions/fixed-partiti= ons.yaml b/Documentation/devicetree/bindings/mtd/partitions/fixed-partition= s.yaml index 26bef777353d..4d79f786fcd5 100644 --- a/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml +++ b/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml @@ -33,7 +33,7 @@ properties: =20 patternProperties: "@[0-9a-f]+$": - $ref: partition.yaml# + $ref: partition.yaml#/$defs/partition-node =20 required: - "#address-cells" diff --git a/Documentation/devicetree/bindings/mtd/partitions/partition.yam= l b/Documentation/devicetree/bindings/mtd/partitions/partition.yaml index fe2f7d622e8b..51fd48af55ec 100644 --- a/Documentation/devicetree/bindings/mtd/partitions/partition.yaml +++ b/Documentation/devicetree/bindings/mtd/partitions/partition.yaml @@ -149,6 +149,18 @@ then: # This is a generic file other binding inherit from and extend additionalProperties: true =20 +$defs: + partition-node: + type: object + if: + not: + required: [ compatible ] + then: + $ref: '#' + unevaluatedProperties: false + else: + $ref: '#' + examples: - | partitions { diff --git a/Documentation/devicetree/bindings/mtd/partitions/tplink,safelo= ader-partitions.yaml b/Documentation/devicetree/bindings/mtd/partitions/tpl= ink,safeloader-partitions.yaml index a24bbaac3a90..40e6eaab03ce 100644 --- a/Documentation/devicetree/bindings/mtd/partitions/tplink,safeloader-pa= rtitions.yaml +++ b/Documentation/devicetree/bindings/mtd/partitions/tplink,safeloader-pa= rtitions.yaml @@ -38,7 +38,7 @@ properties: =20 patternProperties: "^partition-.*$": - $ref: partition.yaml# + $ref: partition.yaml#/$defs/partition-node =20 required: - partitions-table-offset diff --git a/Documentation/devicetree/bindings/mtd/partitions/u-boot.yaml b= /Documentation/devicetree/bindings/mtd/partitions/u-boot.yaml index 327fa872c001..d51bdcb7e585 100644 --- a/Documentation/devicetree/bindings/mtd/partitions/u-boot.yaml +++ b/Documentation/devicetree/bindings/mtd/partitions/u-boot.yaml @@ -29,7 +29,7 @@ properties: =20 patternProperties: "^partition-.*$": - $ref: partition.yaml# + $ref: partition.yaml#/$defs/partition-node =20 unevaluatedProperties: false =20 diff --git a/Documentation/devicetree/bindings/mtd/ti,gpmc-onenand.yaml b/D= ocumentation/devicetree/bindings/mtd/ti,gpmc-onenand.yaml index 7d3ace4f5505..8db991dee7eb 100644 --- a/Documentation/devicetree/bindings/mtd/ti,gpmc-onenand.yaml +++ b/Documentation/devicetree/bindings/mtd/ti,gpmc-onenand.yaml @@ -36,7 +36,7 @@ properties: =20 patternProperties: "@[0-9a-f]+$": - $ref: /schemas/mtd/partitions/partition.yaml + $ref: /schemas/mtd/partitions/partition.yaml#/$defs/partition-node =20 allOf: - $ref: /schemas/memory-controllers/ti,gpmc-child.yaml --=20 2.51.0