Skip to content

leds: trigger: Improve handling of led_trigger_event() and simplify mute audio trigger

Heiner Kallweit linux-leds linux-mips linux-sound 2 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 13 repliesApplied
  2. v14 patches 16 repliesApplied

Changes in v2 from the cover letter

- Split out patch 3 from series and apply it separately via Input tree
- Improve bisectability and ensure that audio mute trigger can't be built twice between patches 2 and 4.

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/3leds: trigger: Store brightness set by led_trigger_event()drivers/leds/led-triggers.c include/linux/leds.h+19 -20 replies
2/3ALSA: control-led: Integrate mute led triggerdrivers/leds/trigger/Kconfig drivers/leds/trigger/Makefile sound/core/Kconfig +1 more+17 -120 replies
3/3leds: trigger: audio: Remove this triggerarch/mips/configs/ci20_defconfig drivers/leds/trigger/ledtrig-audio.c include/linux/leds.h+0 -820 replies

Reviews trailers per patch

None of the 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchTakashi Iwai
SeriesR-b
1/3
2/3
3/3

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/3] leds: trigger: Improve handling of led_trigger_event() and simplify mute audio trigger

If a simple trigger is assigned to a LED, then the LED may be off until the next led_trigger_event() call. This may be an issue for simple triggers with rare led_trigger_event() calls, e.g. power supply charging indicators (drivers/power/supply/power_supply_leds.c). Therefore persist the brightness value of the last led_trigger_event() call and use this value if the trigger is assigned to a LED. This change allows to use simple triggers in more cases.
As a first use case simplify handling of the mute audio trigger.

This series touches few subsystems. I'd propose to handle it via the LED subsystem.

v2:
- Split out patch 3 from series and apply it separately via Input tree
- Improve bisectability and ensure that audio mute trigger can't be built twice between patches 2 and 4.

Heiner Kallweit (3):
leds: trigger: Store brightness set by led_trigger_event()
ALSA: control-led: Integrate mute led trigger
leds: trigger: audio: Remove this trigger

 arch/mips/configs/ci20_defconfig     |  1 -
 drivers/leds/led-triggers.c          |  6 ++-
 drivers/leds/trigger/Kconfig         |  7 ---
 drivers/leds/trigger/Makefile        |  1 -
 drivers/leds/trigger/ledtrig-audio.c | 67 ----------------------------
 include/linux/leds.h                 | 29 ++++++------
 sound/core/Kconfig                   |  1 -
 sound/core/control_led.c             | 20 +++++++--
 8 files changed, 36 insertions(+), 96 deletions(-)
 delete mode 100644 drivers/leds/trigger/ledtrig-audio.c
Signature · 1 line
2.44.0