]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/blob - Documentation/devicetree/bindings/leds/leds-qcom-lpg.txt
UBUNTU: SAUCE: (snapdragon) DT: leds: Add Qualcomm Light Pulse Generator binding
[mirror_ubuntu-disco-kernel.git] / Documentation / devicetree / bindings / leds / leds-qcom-lpg.txt
1 Binding for Qualcomm Light Pulse Generator
2
3 The Qualcomm Light Pulse Generator consists of three different hardware blocks;
4 a ramp generator with lookup table, the light pulse generator and a three
5 channel current sink. These blocks are found in a wide range of Qualcomm PMICs.
6
7 Required properties:
8 - compatible: one of:
9 "qcom,pm8916-pwm",
10 "qcom,pm8941-lpg",
11 "qcom,pm8994-lpg",
12 "qcom,pmi8994-lpg",
13 "qcom,pmi8998-lpg",
14
15 Optional properties:
16 - qcom,power-source: power-source used to drive the output, as defined in the
17 datasheet. Should be specified if the TRILED block is
18 present
19 - qcom,dtest: configures the output into an internal test line of the
20 pmic. Specified by a list of u32 pairs, one pair per channel,
21 where each pair denotes the test line to drive and the second
22 configures how the value should be outputed, as defined in the
23 datasheet
24 - #pwm-cells: should be 2, see ../pwm/pwm.txt
25
26 LED subnodes:
27 A set of subnodes can be used to specify LEDs connected to the LPG. Channels
28 not associated with a LED are available as pwm channels, see ../pwm/pwm.txt.
29
30 Required properties:
31 - led-sources: list of channels associated with this LED, starting at 1 for the
32 first LPG channel
33
34 Optional properties:
35 - label: see Documentation/devicetree/bindings/leds/common.txt
36 - default-state: see Documentation/devicetree/bindings/leds/common.txt
37 - linux,default-trigger: see Documentation/devicetree/bindings/leds/common.txt
38
39 Example:
40 The following example defines a RGB LED attached to the PM8941.
41
42 &spmi_bus {
43 pm8941@1 {
44 lpg {
45 compatible = "qcom,pm8941-lpg";
46 qcom,power-source = <1>;
47
48 rgb {
49 led-sources = <7 6 5>;
50 };
51 };
52 };
53 };
54
55 The following example defines the single PWM channel of the PM8916, which can
56 be muxed by the MPP4 as a current sink.
57
58 &spmi_bus {
59 pm8916@1 {
60 pm8916_pwm: pwm {
61 compatible = "qcom,pm8916-pwm";
62
63 #pwm-cells = <2>;
64 };
65 };
66 };