Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ef0dcd75 authored by Subbaraman Narayanamurthy's avatar Subbaraman Narayanamurthy
Browse files

pwm: qpnp: support DTEST configuration for PWM subtype



Currently, DTEST configuration is supported only based on the
DTEST line and output values for LPG subtype. Though this will
help configuring DTEST mode for PWM subtype, input validation
has to be fixed for supporting the latter properly. Add support
for that.

Also, rename the "lpg-dtest-line" device tree property to
"dtest-line" as this will apply for both LPG and PWM subtypes.

CRs-Fixed: 949595
Change-Id: I96bf477a14bb135cf9196532cf4bf39a45c9ff77
Signed-off-by: default avatarSubbaraman Narayanamurthy <subbaram@codeaurora.org>
parent b2b64139
Loading
Loading
Loading
Loading
+15 −8
Original line number Diff line number Diff line
@@ -33,14 +33,21 @@ Optional device bindings:
- qcom,channel-owner:	A string value to supply owner information.
- qcom,mode-select:	0 = PWM mode
			1 = LPG mode
- qcom,lpg-dtest-line:  indicates which DTEST line to be configured for LPG
			output. Possible values are 1, 2, 3 and 4.
- qcom,dtest-line:  	indicates which DTEST line to be configured for LPG
			or PWM output. For LPG subtypes, possible values are 1,
			2, 3 and 4. For PWM subtype, possibe values are 1 and 2.
- qcom,dtest-output:	indicates the output configuration for DTEST line.
			For LPG subtypes, possible output values are:
				0 = Disabled
				1 = LPG output low
				2 = LPG output high
				3,4,5 = DTEST line specific configuration
				6,7 = Not used
			For PWM subtype, possible output values are:
				0 = Disabled
				1 = pwm_out for DTEST1 or reserved
				2 = pwm_out for DTEST2 or reserved
				3 = Not used
If this binding is specified along with the required bindings of PWM/LPG then
in addition to configure PWM/LPG the qpnp-pwm driver also enables the feature
at the probe time. In the case where the binding is not specified the qpnp-pwm
@@ -181,7 +188,7 @@ Example:
				qcom,ramp-index = <1>;
				qcom,force-pwm-size = <9>;
				qcom,period = <6000000>;
				qcom,lpg-dtest-line = <3>;
				qcom,dtest-line = <3>;
				qcom,dtest-output = <1>;
				status = "okay";

+1 −1
Original line number Diff line number Diff line
@@ -687,7 +687,7 @@
&spmi_bus {
	qcom,pm8994@1 {
		pwm@b100 {
			qcom,lpg-dtest-line = <4>;
			qcom,dtest-line = <4>;
			qcom,dtest-output = <1>;
			status = "okay";
		};
+1 −1
Original line number Diff line number Diff line
@@ -650,7 +650,7 @@
&spmi_bus {
	qcom,pm8994@1 {
		pwm@b100 {
			qcom,lpg-dtest-line = <4>;
			qcom,dtest-line = <4>;
			qcom,dtest-output = <1>;
			status = "okay";
		};
+1 −1
Original line number Diff line number Diff line
@@ -651,7 +651,7 @@
&spmi_bus {
	qcom,pm8994@1 {
		pwm@b100 {
			qcom,lpg-dtest-line = <4>;
			qcom,dtest-line = <4>;
			qcom,dtest-output = <1>;
			status = "okay";
		};
+1 −1
Original line number Diff line number Diff line
@@ -672,7 +672,7 @@

	qcom,pm8994@1 {
		pwm@b100 {
			qcom,lpg-dtest-line = <4>;
			qcom,dtest-line = <4>;
			qcom,dtest-output = <1>;
			status = "okay";
		};
Loading