~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/Documentation/devicetree/bindings/leds/register-bit-led.yaml

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
  2 %YAML 1.2
  3 ---
  4 $id: http://devicetree.org/schemas/leds/register-bit-led.yaml#
  5 $schema: http://devicetree.org/meta-schemas/core.yaml#
  6 
  7 title: Register Bit LEDs
  8 
  9 maintainers:
 10   - Linus Walleij <linus.walleij@linaro.org>
 11 
 12 description: |+
 13   Register bit leds are used with syscon multifunctional devices where single
 14   bits in a certain register can turn on/off a single LED. The register bit LEDs
 15   appear as children to the syscon device, with the proper compatible string.
 16   For the syscon bindings see:
 17   Documentation/devicetree/bindings/mfd/syscon.yaml
 18 
 19 allOf:
 20   - $ref: /schemas/leds/common.yaml#
 21 
 22 properties:
 23   $nodename:
 24     description:
 25       The unit-address is in the form of @<reg addr>,<bit offset>
 26     pattern: '^led@[0-9a-f]+,[0-9a-f]{1,2}$'
 27 
 28   compatible:
 29     const: register-bit-led
 30 
 31   reg:
 32     description:
 33       The register address and size
 34     maxItems: 1
 35 
 36   mask:
 37     description:
 38       bit mask for the bit controlling this LED in the register
 39     $ref: /schemas/types.yaml#/definitions/uint32
 40     enum:
 41       [ 0x1, 0x2, 0x4, 0x8, 0x10, 0x20, 0x40, 0x80, 0x100, 0x200, 0x400, 0x800,
 42         0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000, 0x40000, 0x80000,
 43         0x100000, 0x200000, 0x400000, 0x800000, 0x1000000, 0x2000000, 0x4000000,
 44         0x8000000, 0x10000000, 0x20000000, 0x40000000, 0x80000000 ]
 45 
 46   offset:
 47     description:
 48       register offset to the register controlling this LED
 49     $ref: /schemas/types.yaml#/definitions/uint32
 50     deprecated: true
 51 
 52 required:
 53   - compatible
 54   - mask
 55   - reg
 56 
 57 unevaluatedProperties: false
 58 
 59 examples:
 60   - |
 61 
 62     syscon@10000000 {
 63         compatible = "arm,realview-pb1176-syscon", "syscon", "simple-mfd";
 64         reg = <0x10000000 0x1000>;
 65         #address-cells = <1>;
 66         #size-cells = <1>;
 67         ranges = <0x0 0x10000000 0x1000>;
 68 
 69         led@8,0 {
 70             compatible = "register-bit-led";
 71             reg = <0x08 0x04>;
 72             offset = <0x08>;
 73             mask = <0x01>;
 74             label = "versatile:0";
 75             linux,default-trigger = "heartbeat";
 76             default-state = "on";
 77         };
 78         led@8,1 {
 79             compatible = "register-bit-led";
 80             reg = <0x08 0x04>;
 81             offset = <0x08>;
 82             mask = <0x02>;
 83             label = "versatile:1";
 84             default-state = "off";
 85         };
 86         led@8,2 {
 87             compatible = "register-bit-led";
 88             reg = <0x08 0x04>;
 89             offset = <0x08>;
 90             mask = <0x04>;
 91             label = "versatile:2";
 92             default-state = "off";
 93         };
 94     };
 95 ...

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php