All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Louis-Alexis Eyraud" <louisalexis.eyraud@collabora.com>
Cc: linux-phy@lists.infradead.org, devicetree@vger.kernel.org,
	linux-scsi@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org,
	vkoul@kernel.org, neil.armstrong@linaro.org, olteanv@gmail.com
Subject: Re: [PATCH v16 02/23] dt-bindings: ufs: mediatek,ufs: Complete the binding
Date: Fri, 27 Nov 2026 16:17:02 +0000	[thread overview]
Message-ID: <sashiko-outbox-237859@kernel.org> (raw)
In-Reply-To: <20261127-mt8196-ufs-v16-2-6f2568f7c119@collabora.com>

Thank you for your contribution! Sashiko AI review found 4 potential
issues to consider:
- [Medium] dt-bindings: ufs: mediatek: incompatible schema breaks
  in-tree mt8195.dtsi
- [Low] dt-bindings: ufs: mediatek: MT8195 example uses ungated topckgen
  rx_symbol clocks
- [Low] dt-bindings: ufs: mediatek: non-canonical property order in
  example and schema
- [Low] dt-bindings: ufs: mediatek: redundant word binding in commit
  subject
--

commit e2ae6fefa9dc14389b243b607b0000f77a86ab97
Author: Nicolas Frattaroli <nicolas.frattaroli@collabora.com>

dt-bindings: ufs: mediatek,ufs: Complete the binding

This commit expands the MediaTek UFS binding with reset properties,
additional clocks and power supplies, operating-points-v2 support, and an
MT8195 example while disallowing freq-table-hz and renaming clock-names.

> dt-bindings: ufs: mediatek,ufs: Complete the binding

[Severity: Low]
This isn't a bug, but the dt-bindings: prefix already states that the patch
touches a binding, so repeating "binding" in the subject line is redundant.

> diff --git a/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml b/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml
> index 15c347f5e6604..945cb986b06b7 100644
> --- a/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml
> +++ b/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml
> @@ -19,11 +19,25 @@ properties:
>  
>    clocks:
>      minItems: 1
> -    maxItems: 8
> +    maxItems: 10
>  
>    clock-names:
>      minItems: 1
> -    maxItems: 8
> +    items:
> +      - const: main
> +      - const: aes
> +      - const: tick
> +      - const: unipro_sysclk
> +      - const: unipro_tick
> +      - const: unipro_mp_bclk
> +      - const: tx_symbol
> +      - const: mem_sub
> +      - const: rx_symbol0
> +      - const: rx_symbol1
> +
> +  operating-points-v2: true
> +
> +  freq-table-hz: false

[Severity: Medium]
Does renaming the existing clock-names, disallowing freq-table-hz, and
raising clocks minItems to 10 for mediatek,mt8195-ufshci break DT ABI and
dtbs_check for the in-tree MT8195 and MT8395 device trees?

The commit message notes that the binding is unused in mainline outside of
its example, but arch/arm64/boot/dts/mediatek/mt8195.dtsi already defines
ufshci@11270000 (enabled by mt8395-genio-1200-evk-ufs.dts and
mt8395-radxa-nio-12l.dts) with 8 clocks using the "ufs" and "ufs_*" names
along with freq-table-hz:

arch/arm64/boot/dts/mediatek/mt8195.dtsi:
		ufshci: ufshci@11270000 {
			compatible = "mediatek,mt8195-ufshci";
			...
			clock-names = "ufs", "ufs_aes", "ufs_tick",
					"unipro_sysclk", "unipro_tick",
					"unipro_mp_bclk", "ufs_tx_symbol",
					"ufs_mem_sub";
			freq-table-hz = <0 0>, <0 0>, <0 0>,
					<0 0>, <0 0>, <0 0>,
					<0 0>, <0 0>;

>    phys:
>      maxItems: 1
> @@ -31,8 +45,36 @@ properties:
>    reg:
>      maxItems: 1

[ ... ]

> @@ -94,9 +148,32 @@ examples:
>              phys = <&ufsphy>;
>  
>              clocks = <&infracfg_ao CLK_INFRA_UFS>;
> -            clock-names = "ufs";
> -            freq-table-hz = <0 0>;
> +            clock-names = "main";
>  
>              vcc-supply = <&mt_pmic_vemc_ldo_reg>;
>          };
>      };
> +  - |
> +    ufshci@11270000 {
> +        compatible = "mediatek,mt8195-ufshci";
> +        reg = <0x11270000 0x2300>;
> +        interrupts = <GIC_SPI 137 IRQ_TYPE_LEVEL_HIGH>;
> +        phys = <&ufsphy>;
> +        clocks = <&infracfg_ao 63>, <&infracfg_ao 64>, <&infracfg_ao 65>,
> +                 <&infracfg_ao 54>, <&infracfg_ao 55>, <&infracfg_ao 56>,
> +                 <&infracfg_ao 90>, <&infracfg_ao 93>, <&topckgen 212>,
> +                 <&topckgen 215>;
> +        clock-names = "main", "aes", "tick", "unipro_sysclk", "unipro_tick",
> +                      "unipro_mp_bclk", "tx_symbol", "mem_sub", "rx_symbol0",
> +                      "rx_symbol1";

[Severity: Low]
Should rx_symbol0 and rx_symbol1 in this example reference the infracfg_ao
gate clocks <&infracfg_ao 91> (CLK_INFRA_AO_UFS_RX_SYMBOL) and
<&infracfg_ao 92> (CLK_INFRA_AO_UFS_RX_SYMBOL1) rather than the ungated
topckgen fixed-rate parent clocks <&topckgen 212> and <&topckgen 215>?

In drivers/clk/mediatek/clk-mt8195-infra_ao.c, those topckgen clocks feed
the INFRA_AO4 gates alongside tx_symbol (<&infracfg_ao 90>):

drivers/clk/mediatek/clk-mt8195-infra_ao.c:
	GATE_INFRA_AO4(CLK_INFRA_AO_UFS_TX_SYMBOL, "infra_ao_ufs_tx_symbol", "ufs_tx_symbol", 22),
	GATE_INFRA_AO4(CLK_INFRA_AO_UFS_RX_SYMBOL, "infra_ao_ufs_rx_symbol", "ufs_rx_symbol", 23),
	GATE_INFRA_AO4(CLK_INFRA_AO_UFS_RX_SYMBOL1, "infra_ao_ufs_rx_symbol1", "ufs_rx_symbol1", 24),

Using the topckgen parent clocks directly leaves the INFRA_AO4 clock gates
for rx_symbol0 and rx_symbol1 unreferenced and disabled.

[Severity: Low]
This isn't a bug, but the property order here does not follow the canonical
DT binding order (compatible, reg, clocks, clock-names, interrupts, ...):
the example node lists interrupts and phys before clocks and clock-names,
and the schema properties: and required: blocks list reg after clocks,
clock-names, and phys rather than right after compatible.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261127-mt8196-ufs-v16-0-6f2568f7c119@collabora.com?part=2

-- 
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy

WARNING: multiple messages have this Message-ID (diff)
From: sashiko-bot@kernel.org
To: "Louis-Alexis Eyraud" <louisalexis.eyraud@collabora.com>
Cc: linux-phy@lists.infradead.org, devicetree@vger.kernel.org,
	linux-scsi@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org,
	vkoul@kernel.org, neil.armstrong@linaro.org, olteanv@gmail.com
Subject: Re: [PATCH v16 02/23] dt-bindings: ufs: mediatek,ufs: Complete the binding
Date: Fri, 27 Nov 2026 16:17:02 +0000	[thread overview]
Message-ID: <sashiko-outbox-237859@kernel.org> (raw)
In-Reply-To: <20261127-mt8196-ufs-v16-2-6f2568f7c119@collabora.com>

Thank you for your contribution! Sashiko AI review found 4 potential
issues to consider:
- [Medium] dt-bindings: ufs: mediatek: incompatible schema breaks
  in-tree mt8195.dtsi
- [Low] dt-bindings: ufs: mediatek: MT8195 example uses ungated topckgen
  rx_symbol clocks
- [Low] dt-bindings: ufs: mediatek: non-canonical property order in
  example and schema
- [Low] dt-bindings: ufs: mediatek: redundant word binding in commit
  subject
--

commit e2ae6fefa9dc14389b243b607b0000f77a86ab97
Author: Nicolas Frattaroli <nicolas.frattaroli@collabora.com>

dt-bindings: ufs: mediatek,ufs: Complete the binding

This commit expands the MediaTek UFS binding with reset properties,
additional clocks and power supplies, operating-points-v2 support, and an
MT8195 example while disallowing freq-table-hz and renaming clock-names.

> dt-bindings: ufs: mediatek,ufs: Complete the binding

[Severity: Low]
This isn't a bug, but the dt-bindings: prefix already states that the patch
touches a binding, so repeating "binding" in the subject line is redundant.

> diff --git a/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml b/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml
> index 15c347f5e6604..945cb986b06b7 100644
> --- a/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml
> +++ b/Documentation/devicetree/bindings/ufs/mediatek,ufs.yaml
> @@ -19,11 +19,25 @@ properties:
>  
>    clocks:
>      minItems: 1
> -    maxItems: 8
> +    maxItems: 10
>  
>    clock-names:
>      minItems: 1
> -    maxItems: 8
> +    items:
> +      - const: main
> +      - const: aes
> +      - const: tick
> +      - const: unipro_sysclk
> +      - const: unipro_tick
> +      - const: unipro_mp_bclk
> +      - const: tx_symbol
> +      - const: mem_sub
> +      - const: rx_symbol0
> +      - const: rx_symbol1
> +
> +  operating-points-v2: true
> +
> +  freq-table-hz: false

[Severity: Medium]
Does renaming the existing clock-names, disallowing freq-table-hz, and
raising clocks minItems to 10 for mediatek,mt8195-ufshci break DT ABI and
dtbs_check for the in-tree MT8195 and MT8395 device trees?

The commit message notes that the binding is unused in mainline outside of
its example, but arch/arm64/boot/dts/mediatek/mt8195.dtsi already defines
ufshci@11270000 (enabled by mt8395-genio-1200-evk-ufs.dts and
mt8395-radxa-nio-12l.dts) with 8 clocks using the "ufs" and "ufs_*" names
along with freq-table-hz:

arch/arm64/boot/dts/mediatek/mt8195.dtsi:
		ufshci: ufshci@11270000 {
			compatible = "mediatek,mt8195-ufshci";
			...
			clock-names = "ufs", "ufs_aes", "ufs_tick",
					"unipro_sysclk", "unipro_tick",
					"unipro_mp_bclk", "ufs_tx_symbol",
					"ufs_mem_sub";
			freq-table-hz = <0 0>, <0 0>, <0 0>,
					<0 0>, <0 0>, <0 0>,
					<0 0>, <0 0>;

>    phys:
>      maxItems: 1
> @@ -31,8 +45,36 @@ properties:
>    reg:
>      maxItems: 1

[ ... ]

> @@ -94,9 +148,32 @@ examples:
>              phys = <&ufsphy>;
>  
>              clocks = <&infracfg_ao CLK_INFRA_UFS>;
> -            clock-names = "ufs";
> -            freq-table-hz = <0 0>;
> +            clock-names = "main";
>  
>              vcc-supply = <&mt_pmic_vemc_ldo_reg>;
>          };
>      };
> +  - |
> +    ufshci@11270000 {
> +        compatible = "mediatek,mt8195-ufshci";
> +        reg = <0x11270000 0x2300>;
> +        interrupts = <GIC_SPI 137 IRQ_TYPE_LEVEL_HIGH>;
> +        phys = <&ufsphy>;
> +        clocks = <&infracfg_ao 63>, <&infracfg_ao 64>, <&infracfg_ao 65>,
> +                 <&infracfg_ao 54>, <&infracfg_ao 55>, <&infracfg_ao 56>,
> +                 <&infracfg_ao 90>, <&infracfg_ao 93>, <&topckgen 212>,
> +                 <&topckgen 215>;
> +        clock-names = "main", "aes", "tick", "unipro_sysclk", "unipro_tick",
> +                      "unipro_mp_bclk", "tx_symbol", "mem_sub", "rx_symbol0",
> +                      "rx_symbol1";

[Severity: Low]
Should rx_symbol0 and rx_symbol1 in this example reference the infracfg_ao
gate clocks <&infracfg_ao 91> (CLK_INFRA_AO_UFS_RX_SYMBOL) and
<&infracfg_ao 92> (CLK_INFRA_AO_UFS_RX_SYMBOL1) rather than the ungated
topckgen fixed-rate parent clocks <&topckgen 212> and <&topckgen 215>?

In drivers/clk/mediatek/clk-mt8195-infra_ao.c, those topckgen clocks feed
the INFRA_AO4 gates alongside tx_symbol (<&infracfg_ao 90>):

drivers/clk/mediatek/clk-mt8195-infra_ao.c:
	GATE_INFRA_AO4(CLK_INFRA_AO_UFS_TX_SYMBOL, "infra_ao_ufs_tx_symbol", "ufs_tx_symbol", 22),
	GATE_INFRA_AO4(CLK_INFRA_AO_UFS_RX_SYMBOL, "infra_ao_ufs_rx_symbol", "ufs_rx_symbol", 23),
	GATE_INFRA_AO4(CLK_INFRA_AO_UFS_RX_SYMBOL1, "infra_ao_ufs_rx_symbol1", "ufs_rx_symbol1", 24),

Using the topckgen parent clocks directly leaves the INFRA_AO4 clock gates
for rx_symbol0 and rx_symbol1 unreferenced and disabled.

[Severity: Low]
This isn't a bug, but the property order here does not follow the canonical
DT binding order (compatible, reg, clocks, clock-names, interrupts, ...):
the example node lists interrupts and phys before clocks and clock-names,
and the schema properties: and required: blocks list reg after clocks,
clock-names, and phys rather than right after compatible.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261127-mt8196-ufs-v16-0-6f2568f7c119@collabora.com?part=2

  reply	other threads:[~2026-11-27 16:17 UTC|newest]

Thread overview: 54+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-27 16:00 [PATCH v16 00/23] MediaTek UFS Cleanup and MT8196 Enablement Louis-Alexis Eyraud
2026-11-27 16:00 ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 01/23] dt-bindings: phy: Add mediatek,mt8196-ufsphy variant Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 02/23] dt-bindings: ufs: mediatek,ufs: Complete the binding Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:17   ` sashiko-bot [this message]
2026-11-27 16:17     ` sashiko-bot
2026-11-27 16:00 ` [PATCH v16 03/23] dt-bindings: ufs: mediatek,ufs: Add mt8196 variant Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 04/23] scsi: ufs: mediatek: Move MTK_SIP_UFS_CONTROL to mtk_sip_svc.h Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 05/23] phy: mediatek: ufs: Add support for resets Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 06/23] scsi: ufs: mediatek: Rework resets Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 07/23] scsi: ufs: mediatek: Rework 0.9V regulator Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 08/23] scsi: ufs: mediatek: Add dual 0.9V supply support Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 09/23] scsi: ufs: mediatek: Rework init function Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 10/23] scsi: ufs: mediatek: Rework the crypt-boost stuff Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 11/23] scsi: ufs: mediatek: Handle misc host voltage regulators Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 12/23] scsi: ufs: mediatek: Remove undocumented downstream reset cruft Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 13/23] scsi: ufs: mediatek: Remove vendor kernel quirks cruft Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:11   ` sashiko-bot
2026-11-27 16:11     ` sashiko-bot
2026-11-27 16:00 ` [PATCH v16 14/23] scsi: ufs: mediatek: Use the common PHY framework Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:14   ` sashiko-bot
2026-11-27 16:14     ` sashiko-bot
2026-11-27 16:00 ` [PATCH v16 15/23] scsi: ufs: mediatek: Remove mediatek,ufs-broken-rtc property Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 16/23] scsi: ufs: mediatek: Rework _ufs_mtk_clk_scale error paths Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 17/23] scsi: ufs: mediatek: Clean up logging prints Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 18/23] scsi: ufs: mediatek: Rework ufs_mtk_wait_idle_state Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 19/23] scsi: ufs: mediatek: Don't acquire dvfsrc-vcore twice Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 20/23] scsi: ufs: mediatek: Rework hardware version reading Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 21/23] scsi: ufs: mediatek: Remove ret local from link_startup_notify Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 22/23] scsi: ufs: mediatek: Remove undocumented "clk-scale-up-vcore-min" Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud
2026-11-27 16:00 ` [PATCH v16 23/23] scsi: ufs: mediatek: Add MT8196 compatible, update copyright Louis-Alexis Eyraud
2026-11-27 16:00   ` Louis-Alexis Eyraud

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=sashiko-outbox-237859@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-phy@lists.infradead.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=louisalexis.eyraud@collabora.com \
    --cc=neil.armstrong@linaro.org \
    --cc=olteanv@gmail.com \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    --cc=vkoul@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.