lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 10 Mar 2023 16:15:02 +0100
From:   Andrew Lunn <andrew@...n.ch>
To:     Linus Walleij <linus.walleij@...aro.org>
Cc:     Christian Marangi <ansuelsmth@...il.com>,
        Hans de Goede <hdegoede@...hat.com>,
        Pavel Machek <pavel@....cz>, Lee Jones <lee@...nel.org>,
        Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Florian Fainelli <f.fainelli@...il.com>,
        Vladimir Oltean <olteanv@...il.com>,
        "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>,
        Heiner Kallweit <hkallweit1@...il.com>,
        Russell King <linux@...linux.org.uk>,
        Jonathan Corbet <corbet@....net>,
        "Russell King (Oracle)" <rmk+kernel@...linux.org.uk>,
        Jacek Anaszewski <jacek.anaszewski@...il.com>,
        John Crispin <john@...ozen.org>, linux-leds@...r.kernel.org,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        netdev@...r.kernel.org, linux-doc@...r.kernel.org,
        Tim Harvey <tharvey@...eworks.com>,
        Alexander Stein <alexander.stein@...tq-group.com>,
        Rasmus Villemoes <rasmus.villemoes@...vas.dk>,
        Bagas Sanjaya <bagasdotme@...il.com>,
        Arun.Ramadoss@...rochip.com
Subject: Re: [PATCH v8 00/13] Adds support for PHY LEDs with offload triggers

On Fri, Mar 10, 2023 at 10:37:25AM +0100, Linus Walleij wrote:
> On Thu, Mar 9, 2023 at 4:22 PM Andrew Lunn <andrew@...n.ch> wrote:
> 
> > As to 'how a certain trigger on a certain LED is going to associate
> > itself with, say, a certain port' is clearly a property of the
> > hardware, when offloading is supported. I've not seen a switch you can
> > arbitrarily assign LEDs to ports. The Marvell switches have the LED
> > registers within the port registers, for example, two LEDs per port.
> 
> Aha so there is an implicit HW dependency between the port and the
> LED, that we just cannot see in the device tree. Okay, it makes sense.

Well, i would say the dependency is in the device tree, in that the
LEDs are described in the ports, not as a block of their own at a
higher level within the switch. And in some switches, they might
actually be a block of registers in there own space, rather than in
the port registers. But i still expect there is a fixed mapping
between LED and port.

> I think there will be a day when a switch without LED controller appears,
> but the system has a few LEDs for the ports connected to an
> arbitrary GPIO controller, and then we will need this. But we have
> not seen that yet :)

The microchip sparx5 might be going in that direction. It has what
looks like a reasonably generic sgpio controller:
drivers/pinctrl/pinctrl-microchip-sgpio.c

But this not just about switches. It is also plain NICs. And using
ledtrig-netdev, you could make your keyboard LED blink based on
network traffic etc. So yes, using a phandle to an LED could very well
be useful in the future.

   Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ