Devicetree
 help / color / mirror / Atom feed
* [PATCH] Revert "dt-bindings: i2c: Describe SA8255p"
@ 2026-07-07  8:02 Shawn Guo
  2026-07-07  8:08 ` Krzysztof Kozlowski
  2026-07-07  8:13 ` sashiko-bot
  0 siblings, 2 replies; 5+ messages in thread
From: Shawn Guo @ 2026-07-07  8:02 UTC (permalink / raw)
  To: Andi Shyti
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Praveen Talari,
	linux-i2c, linux-arm-msm, devicetree, linux-kernel, Shawn Guo

This reverts commit fd359c0272bb4078f3a7ef34c1d53ee0deb59900.

Compatible "qcom,sa8255p-geni-i2c" had already been defined by
soc/qcom/qcom,sa8255p-geni-se-qup.yaml. Revert the change to avoid the
same compatible being defined by two bindings.

Signed-off-by: Shawn Guo <shengchao.guo@oss.qualcomm.com>
---
 .../bindings/i2c/qcom,sa8255p-geni-i2c.yaml   | 64 -------------------
 1 file changed, 64 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml

diff --git a/Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml b/Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml
deleted file mode 100644
index a61e40b5cbc1..000000000000
--- a/Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml
+++ /dev/null
@@ -1,64 +0,0 @@
-# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
-%YAML 1.2
----
-$id: http://devicetree.org/schemas/i2c/qcom,sa8255p-geni-i2c.yaml#
-$schema: http://devicetree.org/meta-schemas/core.yaml#
-
-title: Qualcomm SA8255p QUP GENI I2C Controller
-
-maintainers:
-  - Praveen Talari <praveen.talari@oss.qualcomm.com>
-
-properties:
-  compatible:
-    const: qcom,sa8255p-geni-i2c
-
-  reg:
-    maxItems: 1
-
-  dmas:
-    maxItems: 2
-
-  dma-names:
-    items:
-      - const: tx
-      - const: rx
-
-  interrupts:
-    maxItems: 1
-
-  power-domains:
-    maxItems: 2
-
-  power-domain-names:
-    items:
-      - const: power
-      - const: perf
-
-required:
-  - compatible
-  - reg
-  - interrupts
-  - power-domains
-
-allOf:
-  - $ref: /schemas/i2c/i2c-controller.yaml#
-
-unevaluatedProperties: false
-
-examples:
-  - |
-    #include <dt-bindings/interrupt-controller/arm-gic.h>
-    #include <dt-bindings/dma/qcom-gpi.h>
-
-    i2c@a90000 {
-        compatible = "qcom,sa8255p-geni-i2c";
-        reg = <0xa90000 0x4000>;
-        interrupts = <GIC_SPI 357 IRQ_TYPE_LEVEL_HIGH>;
-        dmas = <&gpi_dma0 0 0 QCOM_GPI_I2C>,
-               <&gpi_dma0 1 0 QCOM_GPI_I2C>;
-        dma-names = "tx", "rx";
-        power-domains = <&scmi0_pd 0>, <&scmi0_dvfs 0>;
-        power-domain-names = "power", "perf";
-    };
-...
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] Revert "dt-bindings: i2c: Describe SA8255p"
  2026-07-07  8:02 [PATCH] Revert "dt-bindings: i2c: Describe SA8255p" Shawn Guo
@ 2026-07-07  8:08 ` Krzysztof Kozlowski
  2026-07-07  8:43   ` Shawn Guo
  2026-07-07  8:13 ` sashiko-bot
  1 sibling, 1 reply; 5+ messages in thread
From: Krzysztof Kozlowski @ 2026-07-07  8:08 UTC (permalink / raw)
  To: Shawn Guo, Andi Shyti
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Praveen Talari,
	linux-i2c, linux-arm-msm, devicetree, linux-kernel

On 07/07/2026 10:02, Shawn Guo wrote:
> This reverts commit fd359c0272bb4078f3a7ef34c1d53ee0deb59900.
> 
> Compatible "qcom,sa8255p-geni-i2c" had already been defined by
> soc/qcom/qcom,sa8255p-geni-se-qup.yaml. Revert the change to avoid the
> same compatible being defined by two bindings.

This makes no sense and to prove it: are you going to revert all such
bindings, like 100 of them?

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Revert "dt-bindings: i2c: Describe SA8255p"
  2026-07-07  8:02 [PATCH] Revert "dt-bindings: i2c: Describe SA8255p" Shawn Guo
  2026-07-07  8:08 ` Krzysztof Kozlowski
@ 2026-07-07  8:13 ` sashiko-bot
  1 sibling, 0 replies; 5+ messages in thread
From: sashiko-bot @ 2026-07-07  8:13 UTC (permalink / raw)
  To: Shawn Guo; +Cc: devicetree, conor+dt, robh

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] Reverting the `qcom,sa8255p-geni-i2c.yaml` binding completely removes strict validation for the SA8255p GENI I2C nodes, allowing invalid device trees to silently pass validation.
--

--- Patch [1]: [PATCH] Revert "dt-bindings: i2c: Describe SA8255p" ---
commit 372cd0ac425472b6963cd0afcbe473297a95844e
Author: Shawn Guo <shengchao.guo@oss.qualcomm.com>

Revert "dt-bindings: i2c: Describe SA8255p"

This commit reverts the addition of the SA8255p GENI I2C binding, stating
that the compatible string is already defined in the geni-se-qup schema.

> diff --git a/Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml b/Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml
> deleted file mode 100644
> index a61e40b5cbc16..0000000000000
> --- a/Documentation/devicetree/bindings/i2c/qcom,sa8255p-geni-i2c.yaml
> +++ /dev/null
> @@ -1,64 +0,0 @@
> -# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> -%YAML 1.2
> ----
> -$id: http://devicetree.org/schemas/i2c/qcom,sa8255p-geni-i2c.yaml#
> -$schema: http://devicetree.org/meta-schemas/core.yaml#
> -
> -title: Qualcomm SA8255p QUP GENI I2C Controller

[Severity: Medium]
Does removing this dedicated schema drop strict validation for the SA8255p
GENI I2C nodes?

While the compatible string is listed in soc/qcom/qcom,sa8255p-geni-se-qup.yaml,
it appears that the wrapper schema defines additionalProperties: true for
the i2c@[0-9a-f]+$ child nodes.

The wrapper schema also lacks references to standard I2C constraints such as
/schemas/i2c/i2c-controller.yaml# and does not enforce required properties
like reg, interrupts, and power-domains.

Without this file, will device trees utilizing qcom,sa8255p-geni-i2c with
missing or invalid properties silently pass dt_binding_check?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260707080229.3795971-1-shengchao.guo@oss.qualcomm.com?part=1

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Revert "dt-bindings: i2c: Describe SA8255p"
  2026-07-07  8:08 ` Krzysztof Kozlowski
@ 2026-07-07  8:43   ` Shawn Guo
  2026-07-07  8:46     ` Krzysztof Kozlowski
  0 siblings, 1 reply; 5+ messages in thread
From: Shawn Guo @ 2026-07-07  8:43 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Praveen Talari, linux-i2c, linux-arm-msm, devicetree,
	linux-kernel

On Tue, Jul 07, 2026 at 10:08:09AM +0200, Krzysztof Kozlowski wrote:
> On 07/07/2026 10:02, Shawn Guo wrote:
> > This reverts commit fd359c0272bb4078f3a7ef34c1d53ee0deb59900.
> > 
> > Compatible "qcom,sa8255p-geni-i2c" had already been defined by
> > soc/qcom/qcom,sa8255p-geni-se-qup.yaml. Revert the change to avoid the
> > same compatible being defined by two bindings.
> 
> This makes no sense and to prove it: are you going to revert all such
> bindings, like 100 of them?

Nord compatible "qcom,sa8797p-geni-i2c" was added to
soc/qcom/qcom,sa8255p-geni-se-qup.yaml, as that's where Lemans compatible
"qcom,sa8255p-geni-i2c" is defined. CHECK_DTBS has been working fine by
matching geni-se-qup yaml.

  make CHECK_DTBS=y qcom/sa8797p-ride.dtb

Now with this geni-i2c yaml comes in play, CHECK_DTBS finds it instead
and starts complaining about Nord compatible missing there.

  DTC [C] arch/arm64/boot/dts/qcom/sa8797p-ride.dtb
arch/arm64/boot/dts/qcom/sa8797p-ride.dtb: i2c@880000 (qcom,sa8797p-geni-i2c): compatible:0: 'qcom,sa8255p-geni-i2c' was expected
        from schema $id: http://devicetree.org/schemas/i2c/qcom,sa8255p-geni-i2c.yaml
arch/arm64/boot/dts/qcom/sa8797p-ride.dtb: i2c@880000 (qcom,sa8797p-geni-i2c): compatible: ['qcom,sa8797p-geni-i2c', 'qcom,sa8255p-geni-i2c'] is too long
        from schema $id: http://devicetree.org/schemas/i2c/qcom,sa8255p-geni-i2c.yaml

What's your suggestion to fix the problem, add Nord compatible to
geni-se-qup yaml as well?

Shawn

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Revert "dt-bindings: i2c: Describe SA8255p"
  2026-07-07  8:43   ` Shawn Guo
@ 2026-07-07  8:46     ` Krzysztof Kozlowski
  0 siblings, 0 replies; 5+ messages in thread
From: Krzysztof Kozlowski @ 2026-07-07  8:46 UTC (permalink / raw)
  To: Shawn Guo
  Cc: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Praveen Talari, linux-i2c, linux-arm-msm, devicetree,
	linux-kernel

On 07/07/2026 10:43, Shawn Guo wrote:
> On Tue, Jul 07, 2026 at 10:08:09AM +0200, Krzysztof Kozlowski wrote:
>> On 07/07/2026 10:02, Shawn Guo wrote:
>>> This reverts commit fd359c0272bb4078f3a7ef34c1d53ee0deb59900.
>>>
>>> Compatible "qcom,sa8255p-geni-i2c" had already been defined by
>>> soc/qcom/qcom,sa8255p-geni-se-qup.yaml. Revert the change to avoid the
>>> same compatible being defined by two bindings.
>>
>> This makes no sense and to prove it: are you going to revert all such
>> bindings, like 100 of them?
> 
> Nord compatible "qcom,sa8797p-geni-i2c" was added to
> soc/qcom/qcom,sa8255p-geni-se-qup.yaml, as that's where Lemans compatible
> "qcom,sa8255p-geni-i2c" is defined. CHECK_DTBS has been working fine by
> matching geni-se-qup yaml.
> 
>   make CHECK_DTBS=y qcom/sa8797p-ride.dtb
> 
> Now with this geni-i2c yaml comes in play, CHECK_DTBS finds it instead
> and starts complaining about Nord compatible missing there.
> 
>   DTC [C] arch/arm64/boot/dts/qcom/sa8797p-ride.dtb
> arch/arm64/boot/dts/qcom/sa8797p-ride.dtb: i2c@880000 (qcom,sa8797p-geni-i2c): compatible:0: 'qcom,sa8255p-geni-i2c' was expected
>         from schema $id: http://devicetree.org/schemas/i2c/qcom,sa8255p-geni-i2c.yaml
> arch/arm64/boot/dts/qcom/sa8797p-ride.dtb: i2c@880000 (qcom,sa8797p-geni-i2c): compatible: ['qcom,sa8797p-geni-i2c', 'qcom,sa8255p-geni-i2c'] is too long
>         from schema $id: http://devicetree.org/schemas/i2c/qcom,sa8255p-geni-i2c.yaml
> 
> What's your suggestion to fix the problem, add Nord compatible to
> geni-se-qup yaml as well?

I don't understand what is the problem, but you also did not answer to
my question. If you answered my question, you would answer above, but in
case question was unclear so let me rephrase it: why do you revert only
this duplicated compatible but not 100 others?

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-07-07  8:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-07  8:02 [PATCH] Revert "dt-bindings: i2c: Describe SA8255p" Shawn Guo
2026-07-07  8:08 ` Krzysztof Kozlowski
2026-07-07  8:43   ` Shawn Guo
2026-07-07  8:46     ` Krzysztof Kozlowski
2026-07-07  8:13 ` sashiko-bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox