Update dt configs for leds

Support blink and breathing.

Change-Id: Iaadea80742df8d0724f56ca09065673bfeb1d088
This commit is contained in:
Nickolay Semendyaev 2017-01-14 18:52:14 +06:00 committed by ‎Nickolay Semendyaev
parent 88aa0f6d13
commit b52f489f7b
5 changed files with 304 additions and 27 deletions

View File

@ -485,26 +485,82 @@
qcom,pmi8994@3 {
qcom,leds@d000 {
status = "okay";
qcom,rgb_sync = <1>;
qcom,rgb_sync = <0>;
qcom,rgb_0 {
label = "rgb";
qcom,id = <3>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_3 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <0>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "red";
qcom,use-blink;
somc,pwm-channel = <2>;
qcom,pwm-max-value = <154>;
linux,name = "led:rgb_red";
linux,default-trigger = "none";
};
qcom,rgb_1 {
somc,pwm-channel = <1>;
qcom,pwm-max-value = <511>;
linux,name = "led:rgb_green";
linux,default-trigger = "none";
label = "rgb";
qcom,id = <4>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_2 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <8>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "green";
qcom,use-blink;
somc,pwm-channel = <1>;
qcom,pwm-max-value = <511>;
linux,default-trigger = "none";
};
qcom,rgb_2 {
somc,pwm-channel = <0>;
qcom,pwm-max-value = <460>;
linux,name = "led:rgb_blue";
linux,default-trigger = "none";
label = "rgb";
qcom,id = <5>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_1 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <16>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "blue";
qcom,use-blink;
somc,pwm-channel = <0>;
qcom,pwm-max-value = <460>;
linux,default-trigger = "none";
};
};
qcom,leds@d800 {
qcom,fs-curr-ua = <24000>;

View File

@ -809,24 +809,77 @@
qcom,pmi8994@3 {
qcom,leds@d000 {
status = "okay";
qcom,rgb_sync = <1>;
qcom,rgb_sync = <0>;
qcom,rgb_0 {
label = "rgb";
qcom,id = <3>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_3 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <0>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "red";
qcom,use-blink;
somc,pwm-channel = <2>;
qcom,pwm-max-value = <220>;
linux,name = "led:rgb_red";
linux,default-trigger = "none";
};
qcom,rgb_1 {
label = "rgb";
qcom,id = <4>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_2 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <8>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "green";
qcom,use-blink;
somc,pwm-channel = <1>;
qcom,pwm-max-value = <511>;
linux,name = "led:rgb_green";
linux,default-trigger = "none";
};
qcom,rgb_2 {
label = "rgb";
qcom,id = <5>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_1 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <16>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "blue";
qcom,use-blink;
somc,pwm-channel = <0>;
qcom,pwm-max-value = <451>;
linux,name = "led:rgb_blue";
linux,default-trigger = "none";
};
};

View File

@ -807,24 +807,79 @@
qcom,pmi8994@3 {
qcom,leds@d000 {
status = "okay";
qcom,rgb_sync = <1>;
qcom,rgb_sync = <0>;
qcom,rgb_0 {
label = "rgb";
qcom,id = <3>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_3 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <0>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "red";
qcom,use-blink;
somc,pwm-channel = <2>;
qcom,pwm-max-value = <154>;
linux,name = "led:rgb_red";
linux,default-trigger = "none";
};
qcom,rgb_1 {
label = "rgb";
qcom,id = <4>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_2 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <8>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "green";
qcom,use-blink;
somc,pwm-channel = <1>;
qcom,pwm-max-value = <511>;
linux,name = "led:rgb_green";
linux,default-trigger = "none";
};
qcom,rgb_2 {
label = "rgb";
qcom,id = <5>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_1 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <16>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "blue";
qcom,use-blink;
somc,pwm-channel = <0>;
qcom,pwm-max-value = <460>;
linux,name = "led:rgb_blue";
linux,default-trigger = "none";
};
};

View File

@ -782,30 +782,87 @@
status = "disabled";
};
&spmi_bus {
qcom,pmi8994@3 {
qcom,leds@d000 {
status = "okay";
qcom,rgb_sync = <1>;
qcom,rgb_sync = <0>;
qcom,rgb_0 {
label = "rgb";
qcom,id = <3>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_3 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <0>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "red";
qcom,use-blink;
somc,pwm-channel = <2>;
qcom,pwm-max-value = <154>;
linux,name = "led:rgb_red";
linux,default-trigger = "none";
};
qcom,rgb_1 {
label = "rgb";
qcom,id = <4>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_2 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <8>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "green";
qcom,use-blink;
somc,pwm-channel = <1>;
qcom,pwm-max-value = <511>;
linux,name = "led:rgb_green";
linux,default-trigger = "none";
};
qcom,rgb_2 {
label = "rgb";
qcom,id = <5>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_1 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <16>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "blue";
qcom,use-blink;
somc,pwm-channel = <0>;
qcom,pwm-max-value = <460>;
linux,name = "led:rgb_blue";
linux,default-trigger = "none";
};
};
qcom,leds@d800 {
qcom,ilim-ma = <660>;
@ -817,7 +874,6 @@
};
};
};
&tlmm_pinmux {
/* GPIO_9: USB_SHELL_SEL */
msm_gpio_9 {

View File

@ -797,30 +797,87 @@
status = "ok";
};
&spmi_bus {
qcom,pmi8994@3 {
qcom,leds@d000 {
status = "okay";
qcom,rgb_sync = <1>;
qcom,rgb_sync = <0>;
qcom,rgb_0 {
label = "rgb";
qcom,id = <3>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_3 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <0>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "red";
qcom,use-blink;
somc,pwm-channel = <2>;
qcom,pwm-max-value = <90>;
linux,name = "led:rgb_red";
linux,default-trigger = "none";
};
qcom,rgb_1 {
label = "rgb";
qcom,id = <4>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_2 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <8>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "green";
qcom,use-blink;
somc,pwm-channel = <1>;
qcom,pwm-max-value = <150>;
linux,name = "led:rgb_green";
linux,default-trigger = "none";
};
qcom,rgb_2 {
label = "rgb";
qcom,id = <5>;
qcom,mode = "pwm";
pwms = <&pmi8994_pwm_1 0 0>;
qcom,pwm-us = <1000>;
qcom,max-current = <12>;
qcom,default-state = "off";
qcom,duty-pcts = [00 0c 19 25 32 48 55 64];
qcom,duty-ms = <50>;
qcom,start-idx = <16>;
qcom,idx-len = <8>;
qcom,lut-flags = <0x1f>;
qcom,ramp-step-ms = <100>;
qcom,pause-lo = <2000>;
qcom,pause-hi = <1000>;
linux,name = "blue";
qcom,use-blink;
somc,pwm-channel = <0>;
qcom,pwm-max-value = <200>;
linux,name = "led:rgb_blue";
linux,default-trigger = "none";
};
};
qcom,leds@d800 {
qcom,ilim-ma = <660>;