s5: kernel-5.15 regulator bringup [1/1]

PD#SWPL-108718

Problem:
1. need to support regulator at s5 k5.15;

Solution:
1. add regulator at dts;

Verify:
s5_s928x_ax201,v1.1, #157
s5_s928x_ax201,v2.0, 2 28

Change-Id: I016c37834c85140402046dfbc1652c3d3df57936
Signed-off-by: chengbing.wu <chengbing.wu@amlogic.com>
This commit is contained in:
chengbing.wu
2023-02-03 16:57:23 +08:00
committed by pengzhao.liu
parent 0bb4a43c9e
commit 8be4ab9f80
11 changed files with 420 additions and 100 deletions
-46
View File
@@ -626,52 +626,6 @@
status = "disabled";
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "disabled";
};
vdd_npu: fixedregulator@vdd_npu {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
regulator-name = "vdd_npu";
regulator-min-microvolt = <910000>;
regulator-max-microvolt = <910000>;
pinctrl-names = "default";
gpio = <&gpio GPIOE_4 GPIO_ACTIVE_LOW>;
startup-delay-us = <70000>;
enable-active-low;
regulator-boot-on;
//regulator-always-on;
};
a76_opp_table0: a76_opp_table0 {
compatible = "operating-points-v2";
opp-shared;
+49 -7
View File
@@ -921,6 +921,52 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vdd_npu: fixedregulator@vdd_npu {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
regulator-name = "vdd_npu";
regulator-min-microvolt = <910000>;
regulator-max-microvolt = <910000>;
pinctrl-names = "default";
gpio = <&gpio GPIOE_4 GPIO_ACTIVE_LOW>;
startup-delay-us = <70000>;
enable-active-low;
regulator-boot-on;
//regulator-always-on;
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2039,17 +2085,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -2068,7 +2114,3 @@
&vddcpub {
status = "okay";
};
&vddnpu {
status = "okay";
};
@@ -1001,6 +1001,52 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vdd_npu: fixedregulator@vdd_npu {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
regulator-name = "vdd_npu";
regulator-min-microvolt = <910000>;
regulator-max-microvolt = <910000>;
pinctrl-names = "default";
gpio = <&gpio GPIOE_4 GPIO_ACTIVE_LOW>;
startup-delay-us = <70000>;
enable-active-low;
regulator-boot-on;
//regulator-always-on;
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2148,17 +2194,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -907,6 +907,52 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vdd_npu: fixedregulator@vdd_npu {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
regulator-name = "vdd_npu";
regulator-min-microvolt = <910000>;
regulator-max-microvolt = <910000>;
pinctrl-names = "default";
gpio = <&gpio GPIOE_4 GPIO_ACTIVE_LOW>;
startup-delay-us = <70000>;
enable-active-low;
regulator-boot-on;
//regulator-always-on;
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2029,17 +2075,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -921,6 +921,38 @@
key_tolerance = <40 40 40>;
};
vddnpu_dvo_dos_vpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2039,17 +2071,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -2068,7 +2100,3 @@
&vddcpub {
status = "okay";
};
&vddnpu {
status = "okay";
};
@@ -1001,6 +1001,38 @@
key_tolerance = <40 40 40>;
};
vddnpu_dvo_dos_vpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2148,17 +2180,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -907,6 +907,38 @@
key_tolerance = <40 40 40>;
};
vddnpu_dvo_dos_vpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2029,17 +2061,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
+49 -7
View File
@@ -919,6 +919,52 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vdd_npu: fixedregulator@vdd_npu {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
regulator-name = "vdd_npu";
regulator-min-microvolt = <910000>;
regulator-max-microvolt = <910000>;
pinctrl-names = "default";
gpio = <&gpio GPIOE_4 GPIO_ACTIVE_LOW>;
startup-delay-us = <70000>;
enable-active-low;
regulator-boot-on;
//regulator-always-on;
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2035,17 +2081,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -2064,7 +2110,3 @@
&vddcpub {
status = "okay";
};
&vddnpu {
status = "okay";
};
@@ -919,6 +919,38 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -2035,17 +2067,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -2064,7 +2096,3 @@
&vddcpub {
status = "okay";
};
&vddnpu {
status = "okay";
};
+49 -7
View File
@@ -867,6 +867,52 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vdd_npu: fixedregulator@vdd_npu {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
regulator-name = "vdd_npu";
regulator-min-microvolt = <910000>;
regulator-max-microvolt = <910000>;
pinctrl-names = "default";
gpio = <&gpio GPIOE_4 GPIO_ACTIVE_LOW>;
startup-delay-us = <70000>;
enable-active-low;
regulator-boot-on;
//regulator-always-on;
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -1891,17 +1937,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -1920,7 +1966,3 @@
&vddcpub {
status = "okay";
};
&vddnpu {
status = "okay";
};
@@ -867,6 +867,38 @@
key_tolerance = <40 40 40>;
};
vddnpu: pwm_ef-regulator {
compatible = "pwm-regulator";
pwms = <&pwm_ef MESON_PWM_0 1500 0>;
regulator-name = "vddnpu";
regulator-min-microvolt = <720000>;
regulator-max-microvolt = <900000>;
//regulator-always-on;
max-duty-cycle = <1500>;
/* Voltage Duty-Cycle */
voltage-table =
<900000 0>,
<890000 5>,
<880000 11>,
<870000 17>,
<860000 21>,
<850000 28>,
<840000 33>,
<830000 39>,
<820000 44>,
<810000 50>,
<800000 56>,
<790000 61>,
<780000 67>,
<770000 72>,
<760000 78>,
<750000 83>,
<740000 89>,
<730000 95>,
<720000 100>;
status = "okay";
};
vddq_reg: fixedregulator@vddq {
compatible = "regulator-fixed";
vin-supply = <&vbat>;
@@ -1891,17 +1923,17 @@
&pwm_ab {
pinctrl-0 = <&pwm_a_pins1>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&pwm_cd {
status = "disabled";
status = "okay";
};
&pwm_ef {
pinctrl-0 = <&pwm_f_pins>;
pinctrl-names = "default";
status = "disabled";
status = "okay";
};
&irblaster {
@@ -1920,7 +1952,3 @@
&vddcpub {
status = "okay";
};
&vddnpu {
status = "okay";
};