led.txt 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. LEDs connected to GPIO lines
  2. Required properties:
  3. - compatible : should be "gpio-leds".
  4. Each LED is represented as a sub-node of the gpio-leds device. Each
  5. node's name represents the name of the corresponding LED.
  6. LED sub-node properties:
  7. - gpios : Should specify the LED's GPIO, see "Specifying GPIO information
  8. for devices" in Documentation/powerpc/booting-without-of.txt. Active
  9. low LEDs should be indicated using flags in the GPIO specifier.
  10. - label : (optional) The label for this LED. If omitted, the label is
  11. taken from the node name (excluding the unit address).
  12. - linux,default-trigger : (optional) This parameter, if present, is a
  13. string defining the trigger assigned to the LED. Current triggers are:
  14. "backlight" - LED will act as a back-light, controlled by the framebuffer
  15. system
  16. "default-on" - LED will turn on
  17. "heartbeat" - LED "double" flashes at a load average based rate
  18. "ide-disk" - LED indicates disk activity
  19. "timer" - LED flashes at a fixed, configurable rate
  20. Examples:
  21. leds {
  22. compatible = "gpio-leds";
  23. hdd {
  24. label = "IDE Activity";
  25. gpios = <&mcu_pio 0 1>; /* Active low */
  26. linux,default-trigger = "ide-disk";
  27. };
  28. };
  29. run-control {
  30. compatible = "gpio-leds";
  31. red {
  32. gpios = <&mpc8572 6 0>;
  33. };
  34. green {
  35. gpios = <&mpc8572 7 0>;
  36. };
  37. }