linux-leds.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFC leds + net-next v3 0/2] Add support for LEDs on Marvell PHYs
@ 2020-07-24 16:46 Marek Behún
  2020-07-24 16:46 ` [PATCH RFC leds + net-next v3 1/2] net: phy: add API for LEDs controlled by PHY HW Marek Behún
  2020-07-24 16:46 ` [PATCH RFC leds + net-next v3 2/2] net: phy: marvell: add support for PHY LEDs via LED class Marek Behún
  0 siblings, 2 replies; 17+ messages in thread
From: Marek Behún @ 2020-07-24 16:46 UTC (permalink / raw)
  To: netdev
  Cc: linux-leds, Pavel Machek, jacek.anaszewski, Dan Murphy,
	Ondřej Jirman, Russell King, Thomas Petazzoni,
	Gregory Clement, Andrew Lunn, linux-kernel, Marek Behún

Hi,

this is v3 of my RFC adding support for LEDs connected to Marvell PHYs.

Please note that if you want to test this, you still need to first apply
the patch adding the LED private triggers support from Pavel's tree.
https://git.kernel.org/pub/scm/linux/kernel/git/pavel/linux-leds.git/commit/?h=for-next&id=93690cdf3060c61dfce813121d0bfc055e7fa30d

Changes since v2:
- to share code with other drivers which may want to also offer PHY HW
  control of LEDs some of the code was refactored and now resides in
  phy_hw_led_mode.c. This code is compiled in when config option
  LED_TRIGGER_PHY_HW is enabled. Drivers wanting to offer PHY HW control
  of LEDs should depend on this option.
- the "hw-control" trigger is renamed to "phydev-hw-mode" and is
  registered by the code in phy_hw_led_mode.c
- the "hw_control" sysfs file is renamed to "hw_mode"
- struct phy_driver is extended by three methods to support PHY HW LED
  control
- I renamed the various HW control modes offeret by Marvell PHYs to
  conform to other Linux mode names, for example the "1000/100/10/else"
  mode was renamed to "1Gbps/100Mbps/10Mbps", or "recv/else" was renamed
  to "rx" (this is the name of the mode in netdev trigger).

Marek

Marek Behún (2):
  net: phy: add API for LEDs controlled by PHY HW
  net: phy: marvell: add support for PHY LEDs via LED class

 drivers/net/phy/Kconfig           |  10 +
 drivers/net/phy/Makefile          |   1 +
 drivers/net/phy/marvell.c         | 364 ++++++++++++++++++++++++++++++
 drivers/net/phy/phy_hw_led_mode.c |  96 ++++++++
 include/linux/phy.h               |  15 ++
 5 files changed, 486 insertions(+)
 create mode 100644 drivers/net/phy/phy_hw_led_mode.c

-- 
2.26.2


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2020-08-07  9:11 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-24 16:46 [PATCH RFC leds + net-next v3 0/2] Add support for LEDs on Marvell PHYs Marek Behún
2020-07-24 16:46 ` [PATCH RFC leds + net-next v3 1/2] net: phy: add API for LEDs controlled by PHY HW Marek Behún
2020-07-25  9:21   ` Pavel Machek
2020-07-25  9:37     ` Marek Behun
2020-07-25 16:22   ` Andrew Lunn
2020-07-24 16:46 ` [PATCH RFC leds + net-next v3 2/2] net: phy: marvell: add support for PHY LEDs via LED class Marek Behún
2020-07-25  9:23   ` Pavel Machek
2020-07-25  9:34     ` Marek Behun
2020-07-25 15:03       ` Andrew Lunn
2020-07-25 17:39         ` Marek Behun
2020-07-25 17:47           ` Andrew Lunn
2020-07-25 17:23   ` Andrew Lunn
2020-07-25 18:02     ` Marek Behun
2020-07-25 18:23       ` Andrew Lunn
2020-07-25 18:48       ` Andrew Lunn
2020-07-25 20:58         ` Marek Behun
2020-08-07  9:11         ` Pavel Machek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).