1What: /sys/class/leds/<led>/brightness 2Date: March 2006 3KernelVersion: 2.6.17 4Contact: Richard Purdie <rpurdie@rpsys.net> 5Description: 6 Set the brightness of the LED. 7 8 Most LEDs don't have hardware brightness support, so will 9 just be turned on for non-zero brightness settings. 10 11 .. Note:: 12 13 For multicolor LEDs, writing to this file will update all 14 LEDs within the group to a calculated percentage of what 15 each color LED intensity is set to. 16 17 The percentage is calculated for each grouped LED via 18 the equation below:: 19 20 led_brightness = brightness * multi_intensity/max_brightness 21 22 For additional details please refer to 23 Documentation/leds/leds-class-multicolor.rst. 24 25 The value is between 0 and /sys/class/leds/<led>/max_brightness 26 and is represented by as a decimal. 27 28 Writing 0 to this file clears active trigger. 29 30 Writing non-zero to this file while trigger is active changes the 31 top brightness trigger is going to use, unless the current 32 trigger is offloaded to hardware (in which case writing any 33 value will deactivate the trigger). 34 35 36 37What: /sys/class/leds/<led>/max_brightness 38Date: March 2006 39KernelVersion: 2.6.17 40Contact: Richard Purdie <rpurdie@rpsys.net> 41Description: 42 Maximum brightness level for this LED, default is 255 (LED_FULL). 43 44 If the LED does not support different brightness levels, this 45 should be 1. 46 47What: /sys/class/leds/<led>/brightness_hw_changed 48Date: January 2017 49KernelVersion: 4.11 50Description: 51 Last hardware set brightness level for this LED. Some LEDs 52 may be changed autonomously by hardware/firmware. Only LEDs 53 where this happens and the driver can detect this, will have 54 this file. 55 56 This file supports poll() to detect when the hardware changes 57 the brightness. 58 59 Reading this file will return the last brightness level set 60 by the hardware, this may be different from the current 61 brightness. Reading this file when no hw brightness change 62 event has happened will return an ENODATA error. 63 64What: /sys/class/leds/<led>/trigger 65Date: March 2006 66KernelVersion: 2.6.17 67Contact: Richard Purdie <rpurdie@rpsys.net> 68Description: 69 Set the trigger for this LED. A trigger is a kernel based source 70 of LED events. 71 72 You can change triggers in a similar manner to the way an IO 73 scheduler is chosen. Trigger specific parameters can appear in 74 /sys/class/leds/<led> once a given trigger is selected. For 75 their documentation see `sysfs-class-led-trigger-*`. 76 77 Writing "none" removes the trigger for this LED. 78 79 Writing "default" sets the trigger to the LED's default trigger 80 (which would often be configured in the device tree for the 81 hardware). 82 83What: /sys/class/leds/<led>/trigger_may_offload_to_hw 84Date: September 2026 85KernelVersion: 7.4 86Contact: linux-leds@vger.kernel.org 87Description: 88 Names and states of triggers that may be offloaded to hardware. 89 Such triggers are also called "hardware control trigger" in some 90 context. 91 92 Only exists when the LED supports trigger offload. 93 94 Reading this file returns a list of triggers that are capable to 95 be offloaded. The optional brackets around the trigger name 96 indicate the state of the current trigger: 97 98 - `foo_trigger`: the trigger is not selected, or selected but 99 falls back to software blink for some reasons, e.g., 100 incompatible trigger parameters. 101 - `[foo_trigger]`: the trigger is selected and offloaded to 102 hardware. 103 104 The "netdev" trigger also provides a custom attribute to 105 indicate its state, see `/sys/class/leds/<led>/offloaded`. 106 107What: /sys/class/leds/<led>/inverted 108Date: January 2011 109KernelVersion: 2.6.38 110Contact: Richard Purdie <rpurdie@rpsys.net> 111Description: 112 Invert the LED on/off state. This parameter is specific to 113 gpio and backlight triggers. In case of the backlight trigger, 114 it is useful when driving a LED which is intended to indicate 115 a device in a standby like state. 116