Documentation / devicetree / bindings / leds / backlight / lp855x-backlight.yaml


Based on kernel version 6.11. Page generated on 2024-09-24 08:21 EST.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/leds/backlight/lp855x-backlight.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Texas Instruments LP855X backlight controllers

maintainers:
  - Artur Weber <aweber.kernel@gmail.com>

properties:
  compatible:
    enum:
      - ti,lp8550
      - ti,lp8551
      - ti,lp8552
      - ti,lp8553
      - ti,lp8555
      - ti,lp8556
      - ti,lp8557

  reg:
    maxItems: 1

  dev-ctrl:
    $ref: /schemas/types.yaml#/definitions/uint8
    description:
      Value of device control register. This is a device-specific value.

  bl-name:
    $ref: /schemas/types.yaml#/definitions/string
    description: Backlight device name.

  init-brt:
    $ref: /schemas/types.yaml#/definitions/uint8
    description: Initial value of backlight brightness.

  power-supply:
    description: Regulator which controls the 3V rail.

  enable-supply:
    description: Regulator which controls the EN/VDDIO input.

  pwms:
    maxItems: 1
    description: |
      PWM channel to use for controlling the backlight; setting this
      enables the PWM-based backlight control mode.

  pwm-names: true

  pwm-period:
    $ref: /schemas/types.yaml#/definitions/uint32
    description:
      PWM period value. Deprecated; set the period value in the pwms
      property instead.
    deprecated: true

patternProperties:
  "^rom-[0-9a-f]{2}h$":
    type: object
    description: Nodes containing the values of configuration registers.
    additionalProperties: false
    properties:
      rom-addr:
        $ref: /schemas/types.yaml#/definitions/uint8
        description: Register address of ROM area to be updated.

      rom-val:
        $ref: /schemas/types.yaml#/definitions/uint8
        description: Value to write to the ROM register.

required:
  - compatible
  - reg
  - dev-ctrl

unevaluatedProperties: false

examples:
  - |
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;
 
        backlight@2c {
            compatible = "ti,lp8555";
            reg = <0x2c>;
 
            dev-ctrl = /bits/ 8 <0x00>;
 
            pwms = <&pwm 0 10000>;
            pwm-names = "lp8555";
 
            /* 4V OV, 4 output LED0 string enabled */
            rom-14h {
              rom-addr = /bits/ 8 <0x14>;
              rom-val = /bits/ 8 <0xcf>;
            };
 
            /* Heavy smoothing, 24ms ramp time step */
            rom-15h {
              rom-addr = /bits/ 8 <0x15>;
              rom-val = /bits/ 8 <0xc7>;
            };
 
            /* 4 output LED1 string enabled */
            rom-19h {
              rom-addr = /bits/ 8 <0x19>;
              rom-val = /bits/ 8 <0x0f>;
            };
        };
    };
  - |
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;
 
        backlight@2c {
            compatible = "ti,lp8556";
            reg = <0x2c>;
 
            bl-name = "lcd-bl";
            dev-ctrl = /bits/ 8 <0x85>;
            init-brt = /bits/ 8 <0x10>;
        };
      };
  - |
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;
 
        backlight@2c {
            compatible = "ti,lp8557";
            reg = <0x2c>;
            enable-supply = <&backlight_vddio>;
            power-supply = <&backlight_vdd>;
 
            dev-ctrl = /bits/ 8 <0x41>;
            init-brt = /bits/ 8 <0x0a>;
 
            /* 4V OV, 4 output LED string enabled */
            rom-14h {
              rom-addr = /bits/ 8 <0x14>;
              rom-val = /bits/ 8 <0xcf>;
            };
        };
    };