Re: [PATCH 2/4] ARM: dts: replace opp-v1 tables by opp-v2 for omap34xx and omap36xx
On Sat, Sep 7, 2019 at 12:47 PM H. Nikolaus Schaller wrote: > > In addition, move omap3 from whitelist to blacklist in cpufreq-dt-platdev > in the same patch, because doing either first breaks operation and > may make trouble in bisect. > > We also can remove opp-v1 table for omap3-n950-n9 since it is now > automatically detected. > > We also fix a wrong OPP4 voltage for omap3430 which must be > 0.6V + 54*12.5mV = 1275mV. Otherwise the twl4030 driver will reject > this OPP. > thank you for your work on this. I tested it on a a Logit PD DM3730 Torpedo + Wireless kit, and appears to operate normally, but i have not tested it at temperature. Tested-by: Adam Ford > Signed-off-by: H. Nikolaus Schaller > Acked-by: Tony Lindgren > --- > arch/arm/boot/dts/omap3-n950-n9.dtsi | 7 --- > arch/arm/boot/dts/omap34xx.dtsi | 65 > arch/arm/boot/dts/omap36xx.dtsi | 53 +++ > drivers/cpufreq/cpufreq-dt-platdev.c | 2 +- > 4 files changed, 102 insertions(+), 25 deletions(-) > > diff --git a/arch/arm/boot/dts/omap3-n950-n9.dtsi > b/arch/arm/boot/dts/omap3-n950-n9.dtsi > index 5441e9ffdbb4..e98b0c615f19 100644 > --- a/arch/arm/boot/dts/omap3-n950-n9.dtsi > +++ b/arch/arm/boot/dts/omap3-n950-n9.dtsi > @@ -11,13 +11,6 @@ > cpus { > cpu@0 { > cpu0-supply = <>; > - operating-points = < > - /* kHzuV */ > - 30 1012500 > - 60 120 > - 80 1325000 > - 100 1375000 > - >; > }; > }; > > diff --git a/arch/arm/boot/dts/omap34xx.dtsi b/arch/arm/boot/dts/omap34xx.dtsi > index f572a477f74c..91154829f86a 100644 > --- a/arch/arm/boot/dts/omap34xx.dtsi > +++ b/arch/arm/boot/dts/omap34xx.dtsi > @@ -16,19 +16,66 @@ > / { > cpus { > cpu: cpu@0 { > - /* OMAP343x/OMAP35xx variants OPP1-5 */ > - operating-points = < > - /* kHzuV */ > - 125000 975000 > - 25 1075000 > - 50 120 > - 55 127 > - 60 135 > - >; > + /* OMAP343x/OMAP35xx variants OPP1-6 */ > + operating-points-v2 = <_opp_table>; > + > clock-latency = <30>; /* From legacy driver */ > }; > }; > > + /* see Documentation/devicetree/bindings/opp/opp.txt */ > + cpu0_opp_table: opp-table { > + compatible = "operating-points-v2-ti-cpu"; > + syscon = <_conf>; > + > + opp1-12500 { > + opp-hz = /bits/ 64 <12500>; > + /* > +* we currently only select the max voltage from table > +* Table 3-3 of the omap3530 Data sheet (SPRS507F). > +* Format is: > +*/ > + opp-microvolt = <975000 975000 975000>; > + /* > +* first value is silicon revision bit mask > +* second one 720MHz Device Identification bit mask > +*/ > + opp-supported-hw = <0x 3>; > + }; > + > + opp2-25000 { > + opp-hz = /bits/ 64 <25000>; > + opp-microvolt = <1075000 1075000 1075000>; > + opp-supported-hw = <0x 3>; > + opp-suspend; > + }; > + > + opp3-5 { > + opp-hz = /bits/ 64 <5>; > + opp-microvolt = <120 120 120>; > + opp-supported-hw = <0x 3>; > + }; > + > + opp4-55000 { > + opp-hz = /bits/ 64 <55000>; > + opp-microvolt = <1275000 1275000 1275000>; > + opp-supported-hw = <0x 3>; > + }; > + > + opp5-6 { > + opp-hz = /bits/ 64 <6>; > + opp-microvolt = <135 135 135>; > + opp-supported-hw = <0x 3>; > + }; > + > + opp6-72000 { > + opp-hz = /bits/ 64 <72000>; > + opp-microvolt = <135 135 135>; > + /* only high-speed grade omap3530 devices */ > + opp-supported-hw = <0x 2>; > + }; > + }; > + >
[PATCH 2/4] ARM: dts: replace opp-v1 tables by opp-v2 for omap34xx and omap36xx
In addition, move omap3 from whitelist to blacklist in cpufreq-dt-platdev in the same patch, because doing either first breaks operation and may make trouble in bisect. We also can remove opp-v1 table for omap3-n950-n9 since it is now automatically detected. We also fix a wrong OPP4 voltage for omap3430 which must be 0.6V + 54*12.5mV = 1275mV. Otherwise the twl4030 driver will reject this OPP. Signed-off-by: H. Nikolaus Schaller Acked-by: Tony Lindgren --- arch/arm/boot/dts/omap3-n950-n9.dtsi | 7 --- arch/arm/boot/dts/omap34xx.dtsi | 65 arch/arm/boot/dts/omap36xx.dtsi | 53 +++ drivers/cpufreq/cpufreq-dt-platdev.c | 2 +- 4 files changed, 102 insertions(+), 25 deletions(-) diff --git a/arch/arm/boot/dts/omap3-n950-n9.dtsi b/arch/arm/boot/dts/omap3-n950-n9.dtsi index 5441e9ffdbb4..e98b0c615f19 100644 --- a/arch/arm/boot/dts/omap3-n950-n9.dtsi +++ b/arch/arm/boot/dts/omap3-n950-n9.dtsi @@ -11,13 +11,6 @@ cpus { cpu@0 { cpu0-supply = <>; - operating-points = < - /* kHzuV */ - 30 1012500 - 60 120 - 80 1325000 - 100 1375000 - >; }; }; diff --git a/arch/arm/boot/dts/omap34xx.dtsi b/arch/arm/boot/dts/omap34xx.dtsi index f572a477f74c..91154829f86a 100644 --- a/arch/arm/boot/dts/omap34xx.dtsi +++ b/arch/arm/boot/dts/omap34xx.dtsi @@ -16,19 +16,66 @@ / { cpus { cpu: cpu@0 { - /* OMAP343x/OMAP35xx variants OPP1-5 */ - operating-points = < - /* kHzuV */ - 125000 975000 - 25 1075000 - 50 120 - 55 127 - 60 135 - >; + /* OMAP343x/OMAP35xx variants OPP1-6 */ + operating-points-v2 = <_opp_table>; + clock-latency = <30>; /* From legacy driver */ }; }; + /* see Documentation/devicetree/bindings/opp/opp.txt */ + cpu0_opp_table: opp-table { + compatible = "operating-points-v2-ti-cpu"; + syscon = <_conf>; + + opp1-12500 { + opp-hz = /bits/ 64 <12500>; + /* +* we currently only select the max voltage from table +* Table 3-3 of the omap3530 Data sheet (SPRS507F). +* Format is: +*/ + opp-microvolt = <975000 975000 975000>; + /* +* first value is silicon revision bit mask +* second one 720MHz Device Identification bit mask +*/ + opp-supported-hw = <0x 3>; + }; + + opp2-25000 { + opp-hz = /bits/ 64 <25000>; + opp-microvolt = <1075000 1075000 1075000>; + opp-supported-hw = <0x 3>; + opp-suspend; + }; + + opp3-5 { + opp-hz = /bits/ 64 <5>; + opp-microvolt = <120 120 120>; + opp-supported-hw = <0x 3>; + }; + + opp4-55000 { + opp-hz = /bits/ 64 <55000>; + opp-microvolt = <1275000 1275000 1275000>; + opp-supported-hw = <0x 3>; + }; + + opp5-6 { + opp-hz = /bits/ 64 <6>; + opp-microvolt = <135 135 135>; + opp-supported-hw = <0x 3>; + }; + + opp6-72000 { + opp-hz = /bits/ 64 <72000>; + opp-microvolt = <135 135 135>; + /* only high-speed grade omap3530 devices */ + opp-supported-hw = <0x 2>; + }; + }; + ocp@6800 { omap3_pmx_core2: pinmux@480025d8 { compatible = "ti,omap3-padconf", "pinctrl-single"; diff --git a/arch/arm/boot/dts/omap36xx.dtsi b/arch/arm/boot/dts/omap36xx.dtsi index 6fb23ada1f64..44f25b0eb45b 100644 --- a/arch/arm/boot/dts/omap36xx.dtsi +++ b/arch/arm/boot/dts/omap36xx.dtsi @@ -19,15 +19,52 @@ }; cpus { - /* OMAP3630/OMAP37xx 'standard device' variants OPP50 to OPP130 */ +
Re: [PATCH 2/4] ARM: dts: replace opp-v1 tables by opp-v2 for omap34xx and omap36xx
* H. Nikolaus Schaller [190907 06:57]: > In addition, move omap3 from whitelist to blacklist in cpufreq-dt-platdev > in the same patch, because doing either first breaks operation and > may make trouble in bisect. > > We also can remove opp-v1 table for omap3-n950-n9 since it is now > automatically detected. > > We also fix a wrong OPP4 voltage for omap3430 which must be > 0.6V + 54*12.5mV = 1275mV. Otherwise the twl4030 driver will reject > this OPP. > > Signed-off-by: H. Nikolaus Schaller Acked-by: Tony Lindgren
[PATCH 2/4] ARM: dts: replace opp-v1 tables by opp-v2 for omap34xx and omap36xx
In addition, move omap3 from whitelist to blacklist in cpufreq-dt-platdev in the same patch, because doing either first breaks operation and may make trouble in bisect. We also can remove opp-v1 table for omap3-n950-n9 since it is now automatically detected. We also fix a wrong OPP4 voltage for omap3430 which must be 0.6V + 54*12.5mV = 1275mV. Otherwise the twl4030 driver will reject this OPP. Signed-off-by: H. Nikolaus Schaller --- arch/arm/boot/dts/omap3-n950-n9.dtsi | 7 --- arch/arm/boot/dts/omap34xx.dtsi | 65 arch/arm/boot/dts/omap36xx.dtsi | 53 +++ drivers/cpufreq/cpufreq-dt-platdev.c | 2 +- 4 files changed, 102 insertions(+), 25 deletions(-) diff --git a/arch/arm/boot/dts/omap3-n950-n9.dtsi b/arch/arm/boot/dts/omap3-n950-n9.dtsi index 5441e9ffdbb4..e98b0c615f19 100644 --- a/arch/arm/boot/dts/omap3-n950-n9.dtsi +++ b/arch/arm/boot/dts/omap3-n950-n9.dtsi @@ -11,13 +11,6 @@ cpus { cpu@0 { cpu0-supply = <>; - operating-points = < - /* kHzuV */ - 30 1012500 - 60 120 - 80 1325000 - 100 1375000 - >; }; }; diff --git a/arch/arm/boot/dts/omap34xx.dtsi b/arch/arm/boot/dts/omap34xx.dtsi index f572a477f74c..91154829f86a 100644 --- a/arch/arm/boot/dts/omap34xx.dtsi +++ b/arch/arm/boot/dts/omap34xx.dtsi @@ -16,19 +16,66 @@ / { cpus { cpu: cpu@0 { - /* OMAP343x/OMAP35xx variants OPP1-5 */ - operating-points = < - /* kHzuV */ - 125000 975000 - 25 1075000 - 50 120 - 55 127 - 60 135 - >; + /* OMAP343x/OMAP35xx variants OPP1-6 */ + operating-points-v2 = <_opp_table>; + clock-latency = <30>; /* From legacy driver */ }; }; + /* see Documentation/devicetree/bindings/opp/opp.txt */ + cpu0_opp_table: opp-table { + compatible = "operating-points-v2-ti-cpu"; + syscon = <_conf>; + + opp1-12500 { + opp-hz = /bits/ 64 <12500>; + /* +* we currently only select the max voltage from table +* Table 3-3 of the omap3530 Data sheet (SPRS507F). +* Format is: +*/ + opp-microvolt = <975000 975000 975000>; + /* +* first value is silicon revision bit mask +* second one 720MHz Device Identification bit mask +*/ + opp-supported-hw = <0x 3>; + }; + + opp2-25000 { + opp-hz = /bits/ 64 <25000>; + opp-microvolt = <1075000 1075000 1075000>; + opp-supported-hw = <0x 3>; + opp-suspend; + }; + + opp3-5 { + opp-hz = /bits/ 64 <5>; + opp-microvolt = <120 120 120>; + opp-supported-hw = <0x 3>; + }; + + opp4-55000 { + opp-hz = /bits/ 64 <55000>; + opp-microvolt = <1275000 1275000 1275000>; + opp-supported-hw = <0x 3>; + }; + + opp5-6 { + opp-hz = /bits/ 64 <6>; + opp-microvolt = <135 135 135>; + opp-supported-hw = <0x 3>; + }; + + opp6-72000 { + opp-hz = /bits/ 64 <72000>; + opp-microvolt = <135 135 135>; + /* only high-speed grade omap3530 devices */ + opp-supported-hw = <0x 2>; + }; + }; + ocp@6800 { omap3_pmx_core2: pinmux@480025d8 { compatible = "ti,omap3-padconf", "pinctrl-single"; diff --git a/arch/arm/boot/dts/omap36xx.dtsi b/arch/arm/boot/dts/omap36xx.dtsi index 6fb23ada1f64..44f25b0eb45b 100644 --- a/arch/arm/boot/dts/omap36xx.dtsi +++ b/arch/arm/boot/dts/omap36xx.dtsi @@ -19,15 +19,52 @@ }; cpus { - /* OMAP3630/OMAP37xx 'standard device' variants OPP50 to OPP130 */ + /* OMAP3630/OMAP37xx