From: sashiko-bot@kernel.org
To: "Kathiravan Thirumoorthy" <kathiravan.thirumoorthy@oss.qualcomm.com>
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH 3/4] arm64: dts: qcom: ipq9650: add and enable various device nodes
Date: Fri, 20 Nov 2026 09:32:18 +0000 [thread overview]
Message-ID: <sashiko-outbox-224853@kernel.org> (raw)
In-Reply-To: <20261120-ipq9650_various_devices-v1-3-14f53b84c42c@oss.qualcomm.com>
Thank you for your contribution! Sashiko AI review found 8 potential
issues to consider:
- [High] arm64: dts: qcom: ipq9650 QUPv3 I2C/SPI nodes omit
assigned-clock-rates
- [Medium] arm64: dts: qcom: ipq9650 ssphy_0 reg size 0xa00 truncates
0xe00 pcs_usb
- [Medium] arm64: dts: qcom: ipq9650 usb3 swaps dp_hs_phy_irq and
dm_hs_phy_irq IRQs
- [Medium] arm64: dts: qcom: ipq9650 300 MHz OPP table attached to 200
MHz sdhc
- [Low] arm64: dts: qcom: ipq9650 missing #address-cells/#size-cells on
spi1 and i2c
- [Low] arm64: dts: qcom: ipq9650 sdhc_ice enabled in both common dtsi
and board dts
- [Low] arm64: dts: qcom: ipq9650 qpic_bam omits status disabled in SoC
dtsi
- [Low] arm64: dts: qcom: ipq9650 out-of-order DT nodes in soc@0 and
rdp488-common
--
commit 72adc63cd895671ec07ed6eae7e42757d9770778
Author: Kathiravan Thirumoorthy <kathiravan.thirumoorthy@oss.qualcomm.com>
arm64: dts: qcom: ipq9650: add and enable various device nodes
This commit adds SoC device tree nodes for QUPv3 SPI and I2C, TCSR download
mode, QPIC SPI NAND and BAM, CPU idle states, USB2/USB3 and PHYs, DSU PMU,
LLCC, SMMU, and eMMC ICE on IPQ9650, and enables several peripherals on
RDP488.
> diff --git a/arch/arm64/boot/dts/qcom/ipq9650-rdp488-common.dtsi b/arch/arm64/boot/dts/qcom/ipq9650-rdp488-common.dtsi
> index e51d75bb9576e..bc2caf42faf5d 100644
> --- a/arch/arm64/boot/dts/qcom/ipq9650-rdp488-common.dtsi
> +++ b/arch/arm64/boot/dts/qcom/ipq9650-rdp488-common.dtsi
[ ... ]
> @@ -73,11 +154,44 @@ &sdhc {
> pinctrl-names = "default";
> };
>
> +&sdhc_ice {
> + status = "okay";
> +};
[Severity: Low]
Should sdhc_ice only be enabled in ipq9650-rdp488.dts alongside sdhc rather
than in ipq9650-rdp488-common.dtsi?
ipq9650-rdp488.dts already enables sdhc_ice, so enabling it here duplicates
that override on the eMMC board and also probes the Inline Crypto Engine
(keeping GCC_SDCC1_ICE_CORE_CLK and GCC_SDCC1_AHB_CLK enabled) on NAND board
variants where sdhc is disabled.
> diff --git a/arch/arm64/boot/dts/qcom/ipq9650.dtsi b/arch/arm64/boot/dts/qcom/ipq9650.dtsi
> index 94269c9c8d6fe..a4091fd0c1eae 100644
> --- a/arch/arm64/boot/dts/qcom/ipq9650.dtsi
> +++ b/arch/arm64/boot/dts/qcom/ipq9650.dtsi
[ ... ]
> @@ -210,6 +270,61 @@ refgen_pcie: regulator@6c000 {
[ ... ]
> + ssphy_0: phy@7d000 {
> + compatible = "qcom,ipq9650-qmp-usb3-phy";
> + reg = <0x0 0x0007d000 0x0 0xa00>;
[Severity: Medium]
Does the 0xa00 reg size on ssphy_0 truncate the PCS_USB register block at
offset 0xe00?
In drivers/phy/qualcomm/phy-qcom-qmp-usb.c, ipq9650_usb3phy_cfg uses
qmp_usb_offsets_v4, which sets .pcs_usb = 0x0e00, and
ipq9650_usb3_pcs_usb_tbl programs registers up to offset 0x0e18. Because
qmp_usb_parse_dt() maps resource 0 and computes qmp->pcs_usb = base + 0x0e00,
qmp_usb_power_on() and runtime PM transitions access 0x400 bytes past the
declared 0xa00 resource range. Should the reg size be 0x1000?
[ ... ]
> @@ -399,6 +519,84 @@ qupv3: geniqup@1ac0000 {
> #size-cells = <2>;
> ranges;
>
> + spi0: spi@1a80000 {
> + compatible = "qcom,geni-spi";
> + reg = <0x0 0x01a80000 0x0 0x4000>;
> + clocks = <&gcc GCC_QUPV3_WRAP_SE0_CLK>;
> + clock-names = "se";
> + interrupts = <GIC_SPI 339 IRQ_TYPE_LEVEL_HIGH 0>;
> + #address-cells = <1>;
> + #size-cells = <0>;
> + assigned-clocks = <&gcc GCC_QUPV3_WRAP_SE0_CLK>;
> + operating-points-v2 = <&spi_opp_table_50mhz>;
> +
> + status = "disabled";
> + };
> +
> + i2c0: i2c@1a84000 {
> + compatible = "qcom,geni-i2c";
> + reg = <0x0 0x01a84000 0x0 0x4000>;
> + clocks = <&gcc GCC_QUPV3_WRAP_SE1_CLK>;
> + clock-names = "se";
> + clock-frequency = <400000>;
> + interrupts = <GIC_SPI 340 IRQ_TYPE_LEVEL_HIGH 0>;
> + assigned-clocks = <&gcc GCC_QUPV3_WRAP_SE1_CLK>;
> + operating-points-v2 = <&i2c_opp_table_32mhz>;
> +
> + status = "disabled";
> + };
[Severity: High]
Are spi0, spi1, and i2c0..i2c4 missing assigned-clock-rates to match their
assigned-clocks properties?
Without assigned-clock-rates, of_clk_set_defaults() leaves the serial engine
clocks at their boot rate. Unlike spi-geni-qcom, i2c-qcom-geni never calls
dev_pm_opp_set_rate() to apply i2c_opp_table_32mhz, and instead checks the
current rate of se.clk at probe time:
drivers/i2c/busses/i2c-qcom-geni.c:geni_i2c_clk_map_idx() {
if (clk_get_rate(gi2c->se.clk) == GENI_SE_CLK_32MHZ) {
req_freq = GENI_SE_CLK_32MHZ;
itr = geni_i2c_clk_map_32mhz;
} else {
req_freq = GENI_SE_CLK_19P2MHZ;
itr = geni_i2c_clk_map_19p2mhz;
}
}
In drivers/clk/qcom/gcc-ipq9650.c, ftbl_gcc_qupv3_wrap_se0_clk_src and
ftbl_gcc_qupv3_wrap_se4_clk_src are derived from a 24 MHz XO reference and
support 32 MHz, not 19.2 MHz. If GCC_QUPV3_WRAP_SE*_CLK is at its 24 MHz XO
default rather than pre-programmed to 32 MHz by firmware,
geni_se_clk_freq_match() fails with -EINVAL and i2c2 fails to probe on
RDP488.
[ ... ]
> + spi1: spi@1a94000 {
> + compatible = "qcom,geni-spi";
> + reg = <0x0 0x01a94000 0x0 0x4000>;
> + clocks = <&gcc GCC_QUPV3_WRAP_SE5_CLK>;
> + clock-names = "se";
> + interrupts = <GIC_SPI 344 IRQ_TYPE_LEVEL_HIGH 0>;
> + assigned-clocks = <&gcc GCC_QUPV3_WRAP_SE5_CLK>;
> + operating-points-v2 = <&spi_opp_table_50mhz>;
> +
> + status = "disabled";
> + };
[Severity: Low]
Should spi1 and i2c0..i2c4 define #address-cells = <1> and #size-cells = <0>
like spi0? Without them, DT schema validation fails and any child SPI or I2C
devices added under those controllers inherit #address-cells = <2> and
#size-cells = <1>.
Conversely, the flash@0 nodes under &qpic_nand and &spi0 in
ipq9650-rdp488-common.dtsi set #address-cells = <1> and #size-cells = <1>
with no child subnodes, which Documentation/devicetree/bindings/mtd/mtd.yaml
marks as deprecated.
[ ... ]
> @@ -408,6 +606,75 @@ uart1: serial@1a98000 {
[ ... ]
> + system-cache-controller@4000000 {
> + compatible = "qcom,ipq9650-llcc";
> + reg = <0x0 0x04000000 0x0 0x200000>;
> + reg-names = "llcc0_base";
> + interrupts = <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH 0>;
> + };
> +
> + usb2: usb@1e00000 {
[Severity: Low]
This isn't a bug, but system-cache-controller@4000000 is placed before
usb@1e00000 under soc@0 instead of in unit-address order. Similarly, in
ipq9650-rdp488-common.dtsi, &qusb_phy_0 and &qusb_phy_1 are placed before
&i2c2, &spi0 before &sleep_clk, and &usb2 and &usb3 before &uart1 instead of
in alphabetical order.
[ ... ]
> @@ -429,6 +696,102 @@ sdhc: mmc@7804000 {
> "core",
> "xo";
> non-removable;
> + qcom,ice = <&sdhc_ice>;
> + operating-points-v2 = <&sdhc_opp_table_300mhz>;
> + supports-cqe;
> +
> + status = "disabled";
> + };
> +
> + sdhc_ice: crypto@7808000 {
> + compatible = "qcom,ipq9650-inline-crypto-engine",
> + "qcom,inline-crypto-engine";
> + reg = <0x0 0x07808000 0x0 0x2000>;
> +
> + clocks = <&gcc GCC_SDCC1_ICE_CORE_CLK>,
> + <&gcc GCC_SDCC1_AHB_CLK>;
> + clock-names = "core",
> + "iface";
> +
> + status = "disabled";
> + };
[Severity: Medium]
Is sdhc_opp_table_300mhz (300 MHz) attached to sdhc instead of configuring
the 300 MHz core clock on sdhc_ice?
sdhci_msm_probe() binds sdhc's operating-points-v2 table to its "core" clock
(GCC_SDCC1_APPS_CLK), but in drivers/clk/qcom/gcc-ipq9650.c,
ftbl_gcc_sdcc1_apps_clk_src only supports up to 200 MHz (and
ipq9650-rdp488-common.dtsi sets max-frequency = <192000000>). 300 MHz is the
rate in ftbl_gcc_sdcc1_ice_core_clk_src for sdhc_ice's GCC_SDCC1_ICE_CORE_CLK,
which currently has no rate configured in DT or drivers/soc/qcom/ice.c.
Also, Documentation/devicetree/bindings/mmc/qcom,sdhci-msm.yaml requires
required-opps on every OPP entry in an sdhci-msm opp-table.
> +
> + qpic_bam: dma-controller@7984000 {
> + compatible = "qcom,bam-v1.7.4", "qcom,bam-v1.7.0";
> + reg = <0x0 0x7984000 0x0 0x1c000>;
> + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH 0>;
> + clocks = <&gcc GCC_QPIC_AHB_CLK>;
> + clock-names = "bam_clk";
> + #dma-cells = <1>;
> + qcom,ee = <0>;
> + };
[Severity: Low]
Should qpic_bam have status = "disabled" in ipq9650.dtsi like its consumer
qpic_nand? Leaving it enabled causes bam_dma_probe() to probe the QPIC BAM
controller, keep GCC_QPIC_AHB_CLK enabled, and claim IRQ 109 on eMMC board
variants where qpic_nand is disabled.
[ ... ]
> + usb3: usb@8a00000 {
[ ... ]
> + interrupts-extended = <&intc GIC_SPI 409 IRQ_TYPE_LEVEL_HIGH 0>,
> + <&intc GIC_SPI 412 IRQ_TYPE_LEVEL_HIGH 0>,
> + <&intc GIC_SPI 413 IRQ_TYPE_LEVEL_HIGH 0>,
> + <&intc GIC_SPI 423 IRQ_TYPE_LEVEL_HIGH 0>,
> + <&intc GIC_SPI 424 IRQ_TYPE_LEVEL_HIGH 0>;
> + interrupt-names = "dwc_usb3",
> + "pwr_event",
> + "qusb2_phy",
> + "dp_hs_phy_irq",
> + "dm_hs_phy_irq";
[Severity: Medium]
Are GIC_SPI 423 and GIC_SPI 424 swapped relative to "dp_hs_phy_irq" and
"dm_hs_phy_irq" on usb3?
On usb2 above (where GIC_SPI 388 is dp_hs_phy_irq and GIC_SPI 387 is
dm_hs_phy_irq) and on ipq5424.dtsi (where GIC_SPI 423 is dm_hs_phy_irq and
GIC_SPI 424 is dp_hs_phy_irq), the lower SPI number is DM and the higher SPI
number is DP. With 423 mapped to dp_hs_phy_irq and 424 mapped to
dm_hs_phy_irq, dwc3_qcom_enable_port_interrupts() monitors D- instead of D+
for High-Speed/Full-Speed devices and D+ instead of D- for Low-Speed devices
during suspend, breaking USB2 wakeup and disconnect detection on usb3.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261120-ipq9650_various_devices-v1-0-14f53b84c42c@oss.qualcomm.com?part=3
next prev parent reply other threads:[~2026-11-20 9:32 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-20 8:59 [PATCH 0/4] arm64: dts: qcom: ipq9650: add and enable various devices Kathiravan Thirumoorthy
2026-11-20 8:59 ` [PATCH 1/4] arm64: dts: qcom: ipq9650: fix the TCSR mutex address range Kathiravan Thirumoorthy
2026-11-20 8:59 ` [PATCH 2/4] arm64: dts: qcom: ipq9650: add RDP488 common DT file Kathiravan Thirumoorthy
2026-11-20 8:59 ` [PATCH 3/4] arm64: dts: qcom: ipq9650: add and enable various device nodes Kathiravan Thirumoorthy
2026-11-20 9:32 ` sashiko-bot [this message]
2026-11-20 8:59 ` [PATCH 4/4] arm64: dts: qcom: ipq9650: Add RDP488 NAND variant Kathiravan Thirumoorthy
2026-11-20 9:07 ` sashiko-bot
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-224853@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=kathiravan.thirumoorthy@oss.qualcomm.com \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox