Re: [PATCH 1/2] ARM: dts: mba6ulx: Add Ethernet PHY interrupt support

[email protected]
Newsgroups dev.linux.lists.imx,org.kernel.vger.linux-devicetree
Message-ID <[email protected]>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] Leftover `gpio-hog` nodes (`enet1_int-hog` and `enet2_int-hog`) for Ethernet PHY interrupt pins double-book GPIO resources.
--

--- Patch [1]: [PATCH 1/2] ARM: dts: mba6ulx: Add Ethernet PHY interrupt support ---
commit b452753cee9dad50d404387319c21ed7231c45d2
Author: Alexander Stein <[email protected]>

ARM: dts: mba6ulx: Add Ethernet PHY interrupt support

This commit adds interrupt-parent and interrupts properties to the ethphy0
and ethphy1 nodes in the device tree. It configures the Ethernet PHYs to
use level-low interrupts provided by the GPIO expander.

> diff --git a/arch/arm/boot/dts/nxp/imx/mba6ulx.dtsi b/arch/arm/boot/dts/nxp/imx/mba6ulx.dtsi
> --- a/arch/arm/boot/dts/nxp/imx/mba6ulx.dtsi
> +++ b/arch/arm/boot/dts/nxp/imx/mba6ulx.dtsi
> @@ -214,6 +214,8 @@ ethphy0: ethernet-phy@0 {
>  			clocks = <&clks IMX6UL_CLK_ENET_REF>;
>  			reg = <0>;
>  			max-speed = <100>;
> +			interrupt-parent = <&expander_in0>;
> +			interrupts = <6 IRQ_TYPE_LEVEL_LOW>;

[Severity: Medium]
Will this conflict with the existing enet1_int-hog in the expander_in0 node?

Further down in this file, expander_in0 still defines these pins as
gpio-hogs:

		enet1_int-hog {
			gpio-hog;
			gpios = <6 0>;
			input;
		};

		enet2_int-hog {
			gpio-hog;
			gpios = <7 0>;
			input;
		};

Does leaving these redundant gpio-hog nodes in place cause the device tree
to claim the same hardware resource twice? This might result in a resource
ownership conflict between the GPIO and IRQ subsystems, potentially causing
the IRQ request to fail and fall back to polling.

>  		};
>  
>  		ethphy1: ethernet-phy@1 {
>  			compatible = "ethernet-phy-ieee802.3-c22";
>  			clocks = <&clks IMX6UL_CLK_ENET2_REF_125M>;
>  			reg = <1>;
>  			max-speed = <100>;
> +			interrupt-parent = <&expander_in0>;
> +			interrupts = <7 IRQ_TYPE_LEVEL_LOW>;
>  		};
>  	};
>  };

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.