Re: [PATCH v2] net: phy: Handle both led@0 and led subnode name for single-LED PHYs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jan 20, 2025 at 10:02:46AM +0100, Marek Vasut wrote:
> In case a PHY supports only one LED in total, like ADIN1300, and this LED
> is described in DT, it is currently necessary to include unit address in
> the LED node name and the address-cells have to be set to 1:
> 
> leds {
>   #address-cells = <1>;
>   ...
>   led@0 {
>     reg = <0>;
>     ...
>   };
> };
> 
> For a single LED PHY, this should not be necessary and plain 'led' node
> without unit should be acceptable as well:
> 
> leds {
>   ...
>   led {
>     ...
>   };
> };

So how do other subsystems handle this? SPI with only a single chip
select line? Standalone LED controllers with a single LED? A PWM with
a single output?

>  drivers/net/phy/phy_device.c | 15 +++++++++++++--

What about the device tree binding? Does it already have the reg
property as optional?

	Andrew




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux