Skip to content

Commit b53ae6b

Browse files
konradybcioandersson
authored andcommitted
arm64: dts: qcom: sm8150: Add GPU speedbin support
SM8150 has (at least) two GPU speed bins. With the support added on the driver side, wire up bin detection in the DTS to restrict lower-quality SKUs from running at frequencies they were not validated at. Tested-by: Marijn Suijten <[email protected]> # On Sony Xperia 5 (speed bin 0x3) Reviewed-by: Marijn Suijten <[email protected]> Reviewed-by: Dmitry Baryshkov <[email protected]> Signed-off-by: Konrad Dybcio <[email protected]> Signed-off-by: Bjorn Andersson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 1642ab9 commit b53ae6b

File tree

1 file changed

+20
-1
lines changed

1 file changed

+20
-1
lines changed

arch/arm64/boot/dts/qcom/sm8150.dtsi

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -950,6 +950,17 @@
950950
status = "disabled";
951951
};
952952

953+
qfprom: efuse@784000 {
954+
compatible = "qcom,sm8150-qfprom", "qcom,qfprom";
955+
reg = <0 0x00784000 0 0x8ff>;
956+
#address-cells = <1>;
957+
#size-cells = <1>;
958+
959+
gpu_speed_bin: gpu_speed_bin@133 {
960+
reg = <0x133 0x1>;
961+
bits = <5 3>;
962+
};
963+
};
953964

954965
qupv3_id_0: geniqup@8c0000 {
955966
compatible = "qcom,geni-se-qup";
@@ -2165,44 +2176,52 @@
21652176

21662177
qcom,gmu = <&gmu>;
21672178

2179+
nvmem-cells = <&gpu_speed_bin>;
2180+
nvmem-cell-names = "speed_bin";
2181+
21682182
status = "disabled";
21692183

21702184
zap-shader {
21712185
memory-region = <&gpu_mem>;
21722186
};
21732187

2174-
/* note: downstream checks gpu binning for 675 Mhz */
21752188
gpu_opp_table: opp-table {
21762189
compatible = "operating-points-v2";
21772190

21782191
opp-675000000 {
21792192
opp-hz = /bits/ 64 <675000000>;
21802193
opp-level = <RPMH_REGULATOR_LEVEL_NOM_L1>;
2194+
opp-supported-hw = <0x2>;
21812195
};
21822196

21832197
opp-585000000 {
21842198
opp-hz = /bits/ 64 <585000000>;
21852199
opp-level = <RPMH_REGULATOR_LEVEL_NOM>;
2200+
opp-supported-hw = <0x3>;
21862201
};
21872202

21882203
opp-499200000 {
21892204
opp-hz = /bits/ 64 <499200000>;
21902205
opp-level = <RPMH_REGULATOR_LEVEL_SVS_L2>;
2206+
opp-supported-hw = <0x3>;
21912207
};
21922208

21932209
opp-427000000 {
21942210
opp-hz = /bits/ 64 <427000000>;
21952211
opp-level = <RPMH_REGULATOR_LEVEL_SVS_L1>;
2212+
opp-supported-hw = <0x3>;
21962213
};
21972214

21982215
opp-345000000 {
21992216
opp-hz = /bits/ 64 <345000000>;
22002217
opp-level = <RPMH_REGULATOR_LEVEL_SVS>;
2218+
opp-supported-hw = <0x3>;
22012219
};
22022220

22032221
opp-257000000 {
22042222
opp-hz = /bits/ 64 <257000000>;
22052223
opp-level = <RPMH_REGULATOR_LEVEL_LOW_SVS>;
2224+
opp-supported-hw = <0x3>;
22062225
};
22072226
};
22082227
};

0 commit comments

Comments
 (0)