Skip to content

Commit a7adae0

Browse files
author
Christoph Rudorff
committed
arm64: qcom: gcc-msm8916 dts: msm8916 update gpu_opp_table
pick opp-table via efuse bits This still needs fixing a3xx PM otherwise transition from 310MHz will lock up gpu My devices haven't set the fuse but they happily run at 465MHz aswell Signed-off-by: Christoph Rudorff <chris@rudorff.com>
1 parent e6321af commit a7adae0

File tree

2 files changed

+48
-1
lines changed

2 files changed

+48
-1
lines changed

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

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -492,6 +492,16 @@
492492
#address-cells = <1>;
493493
#size-cells = <1>;
494494

495+
speedbin_efuse_version: speedbin@4{
496+
reg = <0x6 0x1>;
497+
bits = <2 2>;
498+
};
499+
500+
speedbin_efuse: speedbin@c{
501+
reg = <0xc 0x1>;
502+
bits = <2 3>;
503+
};
504+
495505
tsens_base1: base1@d0 {
496506
reg = <0xd0 0x1>;
497507
bits = <0 7>;
@@ -1828,14 +1838,50 @@
18281838
iommus = <&gpu_iommu 1>, <&gpu_iommu 2>;
18291839
status = "disabled";
18301840

1841+
// opp-avg-kBps / opp-peak-kBps:
1842+
// need CONFIG_INTERCONNECT=y working, it's bugged:
1843+
// interconnects = <&bimc MASTER_GRAPHICS_3D &bimc SLAVE_EBI_CH0>;
1844+
// interconnect-names = "gfx-mem";
1845+
1846+
// defining speed bin, we must define opp-supported-hw!
1847+
// if speedbin val is 0, driver must version 0x1
1848+
nvmem-cells = <&speedbin_efuse_version>, <&speedbin_efuse>;
1849+
nvmem-cell-names = "speed_bin_version", "speed_bin";
1850+
18311851
gpu_opp_table: opp-table {
18321852
compatible = "operating-points-v2";
18331853

1854+
opp-465000000 {
1855+
opp-hz = /bits/ 64 <465000000>;
1856+
opp-supported-hw = <0x02>;
1857+
// interconnect:
1858+
// opp-avg-kBps = <1190400>;
1859+
// opp-peak-kBps = <4761600>;
1860+
};
18341861
opp-400000000 {
18351862
opp-hz = /bits/ 64 <400000000>;
1863+
opp-supported-hw = <0xffffffff>;
1864+
// opp-avg-kBps = <1066000>;
1865+
// opp-peak-kBps = <4264000>;
1866+
};
1867+
opp-310000000 {
1868+
opp-hz = /bits/ 64 <310000000>;
1869+
opp-supported-hw = <0xffffffff>;
1870+
// opp-avg-kBps = <800000>;
1871+
// opp-peak-kBps = <3200000>;
1872+
};
1873+
opp-200000000 {
1874+
opp-hz = /bits/ 64 <200000000>;
1875+
opp-supported-hw = <0xffffffff>;
1876+
// opp-avg-kBps = <160000>;
1877+
// opp-peak-kBps = <1600000>;
18361878
};
18371879
opp-19200000 {
18381880
opp-hz = /bits/ 64 <19200000>;
1881+
opp-supported-hw = <0xffffffff>;
1882+
// opp-avg-kBps = <0>;
1883+
// opp-peak-kBps = <0>;
1884+
opp-suspend;
18391885
};
18401886
};
18411887
};

drivers/clk/qcom/gcc-msm8916.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ static const struct parent_map gcc_xo_gpll0a_gpll1_gpll2a_map[] = {
191191
{ P_XO, 0 },
192192
{ P_GPLL0_AUX, 3 },
193193
{ P_GPLL1, 1 },
194-
{ P_GPLL2_AUX, 2 },
194+
{ P_GPLL2, 2 },
195195
};
196196

197197
static const struct clk_parent_data gcc_xo_gpll0a_gpll1_gpll2a[] = {
@@ -488,6 +488,7 @@ static const struct freq_tbl ftbl_gcc_oxili_gfx3d_clk[] = {
488488
F(294912000, P_GPLL1, 3, 0, 0),
489489
F(310000000, P_GPLL2, 3, 0, 0),
490490
F(400000000, P_GPLL0_AUX, 2, 0, 0),
491+
F(465000000, P_GPLL2, 2, 0, 0),
491492
{ }
492493
};
493494

0 commit comments

Comments
 (0)