[PATCH v3] dt-bindings: leds: Document commonly used LED triggers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This commit documents the LED triggers used commonly in the SoCs. Not
all triggers are documented as some of them are very application specific.
Most of the triggers documented here are currently used in devicetrees
of many SoCs.

While at it, let's also sort the triggers in ascending order.

Tested-by: Zhen Lei <thunder.leizhen@xxxxxxxxxx>
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@xxxxxxxxxx>
---

Changes in v3:

* Rebased on top of v6.1-rc1
* Added WLAN Rx trigger
* Added tested tag from Zhen Lei

Changes in v2:

* Added more triggers, fixed the regex
* Sorted triggers in ascending order

 .../devicetree/bindings/leds/common.yaml      | 79 ++++++++++++++-----
 1 file changed, 59 insertions(+), 20 deletions(-)

diff --git a/Documentation/devicetree/bindings/leds/common.yaml b/Documentation/devicetree/bindings/leds/common.yaml
index 3c14a98430e1..0ffed6bcbefd 100644
--- a/Documentation/devicetree/bindings/leds/common.yaml
+++ b/Documentation/devicetree/bindings/leds/common.yaml
@@ -80,26 +80,65 @@ properties:
     $ref: /schemas/types.yaml#/definitions/string
 
     oneOf:
-      - enum:
-            # LED will act as a back-light, controlled by the framebuffer system
-          - backlight
-            # LED will turn on (but for leds-gpio see "default-state" property in
-            # Documentation/devicetree/bindings/leds/leds-gpio.yaml)
-          - default-on
-            # LED "double" flashes at a load average based rate
-          - heartbeat
-            # LED indicates disk activity
-          - disk-activity
-            # LED indicates IDE disk activity (deprecated), in new implementations
-            # use "disk-activity"
-          - ide-disk
-            # LED flashes at a fixed, configurable rate
-          - timer
-            # LED alters the brightness for the specified duration with one software
-            # timer (requires "led-pattern" property)
-          - pattern
-        # LED is triggered by SD/MMC activity
-      - pattern: "^mmc[0-9]+$"
+      - items:
+          - enum:
+                # LED indicates mic mute state
+              - audio-micmute
+                # LED indicates audio mute state
+              - audio-mute
+                # LED will act as a back-light, controlled by the framebuffer system
+              - backlight
+                # LED indicates bluetooth power state
+              - bluetooth-power
+                # LED indicates activity of all CPUs
+              - cpu
+                # LED will turn on (but for leds-gpio see "default-state" property in
+                # Documentation/devicetree/bindings/leds/leds-gpio.yaml)
+              - default-on
+                # LED indicates disk activity
+              - disk-activity
+                # LED indicates disk read activity
+              - disk-read
+                # LED indicates disk write activity
+              - disk-write
+                # LED indicates camera flash state
+              - flash
+                # LED "double" flashes at a load average based rate
+              - heartbeat
+                # LED indicates IDE disk activity (deprecated), in new implementations
+                # use "disk-activity"
+              - ide-disk
+                # LED indicates MTD memory activity
+              - mtd
+                # LED indicates NAND memory activity (deprecated),
+                # in new implementations use "mtd"
+              - nand-disk
+                # No trigger assigned to the LED. This is the default mode
+                # if trigger is absent
+              - none
+                # LED alters the brightness for the specified duration with one software
+                # timer (requires "led-pattern" property)
+              - pattern
+                # LED flashes at a fixed, configurable rate
+              - timer
+                # LED indicates camera torch state
+              - torch
+                # LED indicates USB gadget activity
+              - usb-gadget
+                # LED indicates USB host activity
+              - usb-host
+      - items:
+            # LED indicates activity of [N]th CPU
+          - pattern: "^cpu[0-9]{1,2}$"
+      - items:
+            # LED indicates power status of [N]th Bluetooth HCI device
+          - pattern: "^hci[0-9]{1,2}-power$"
+      - items:
+            # LED indicates [N]th MMC storage activity
+          - pattern: "^mmc[0-9]{1,2}$"
+      - items:
+            # LED indicates [N]th WLAN Tx/Rx activity
+          - pattern: "^phy[0-9]{1,2}(tx|rx)$"
 
   led-pattern:
     description: |
-- 
2.25.1




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux