Re: [PATCH v7 6/6] arm64: dts: lx2160a: drop the I2C bus recovery of i2c6 and i2c7
From: Vladimir Oltean
Date: Tue Nov 17 2026 - 16:32:43 EST
On Tue, Nov 17, 2026 at 03:53:16PM +0100, Vincent Jardin via B4 Relay wrote:
> From: Vincent Jardin <vjardin@xxxxxxx>
>
> IIC7 and IIC8, the i2c6 and i2c7 nodes, exist only on the SDHC2_DAT[7:4]
> pads, and one RCW field, SDHC2_DAT74_PMUX, muxes all four of them:
> - 0b010 gives both buses
> - 0b001 gives GPIO2[18:15]
>
> The bus recovery of one controller therefore switches the pads of the
> other one to GPIO too, and breaks a transfer of that bus, or its
> target role.
> No lock shared by the two drivers can avoid that.
>
> The description cannot work either: both nodes point at the same two
> states of the same pad-mux group, so the controller that probes second
> fails with "pin ... already requested".
> No board enables either bus, which is why it did not show.
>
> Drop the pinctrl and the recovery GPIOs of both nodes, and the two states
> nothing else uses. A board that uses one of the buses can add its own.
You bring a good point, not sure why you didn't bring it on v6 prior to
sending this new series?
As you say, a board may choose to use just one of iic7/iic8, and in that
case, bus recovery should work, as we don't care about the pin states of
the other unused bus. I failed to see this yesterday and deemed the
entire configuration as deletable.
Now I think it's pretty strange to delete the pinctrl and gpio phandles
from the common SoC dtsi and to tell board authors to duplicate them
themselves if they are in that situation.
I think a better alternative would be to add some comments like
"Bus recovery functional only if i2c7 is disabled" above i2c6, and
"Bus recovery functional only if i2c6 is disabled" above i2c7?
I'm not sure whether maintainers could just ignore this patch while
applying?
>
> Suggested-by: Vladimir Oltean <vladimir.oltean@xxxxxxx>
> Link: https://lore.kernel.org/all/avtsY-7-I7_pdyD0@xxxxxxxxxxxxxxxxxxxx/
> Signed-off-by: Vincent Jardin <vjardin@xxxxxxx>
> ---
> arch/arm64/boot/dts/freescale/fsl-lx216x.dtsi | 20 --------------------
> 1 file changed, 20 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/freescale/fsl-lx216x.dtsi b/arch/arm64/boot/dts/freescale/fsl-lx216x.dtsi
> index b0bb7bf944059..64903e935131b 100644
> --- a/arch/arm64/boot/dts/freescale/fsl-lx216x.dtsi
> +++ b/arch/arm64/boot/dts/freescale/fsl-lx216x.dtsi
> @@ -852,16 +852,6 @@ esdhc0_data75_pins: sdhc1-dir-sdhc-pins {
> groups = "sdhc1-dir";
> };
>
> - gpio1_18_15_pins: iic8-iic7-gpio-pins {
> - function = "gpio";
> - groups = "sdhc2-data74";
> - };
> -
> - i2c6_i2c7_pins: iic8-iic7-i2c-pins {
> - function = "i2c";
> - groups = "sdhc2-data74";
> - };
> -
> i2c0_pins: iic1-i2c-pins {
> function = "i2c";
> groups = "iic1";
> @@ -1038,11 +1028,6 @@ i2c6: i2c@2060000 {
> clock-names = "ipg";
> clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
> QORIQ_CLK_PLL_DIV(16)>;
> - pinctrl-names = "default", "gpio";
> - pinctrl-0 = <&i2c6_i2c7_pins>;
> - pinctrl-1 = <&gpio1_18_15_pins>;
> - scl-gpios = <&gpio1 16 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
> - sda-gpios = <&gpio1 15 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
> status = "disabled";
> };
>
> @@ -1055,11 +1040,6 @@ i2c7: i2c@2070000 {
> clock-names = "ipg";
> clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
> QORIQ_CLK_PLL_DIV(16)>;
> - pinctrl-names = "default", "gpio";
> - pinctrl-0 = <&i2c6_i2c7_pins>;
> - pinctrl-1 = <&gpio1_18_15_pins>;
> - scl-gpios = <&gpio1 18 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
> - sda-gpios = <&gpio1 17 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
> status = "disabled";
> };
>
>
> --
> 2.43.0
>
>