]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/msm: adreno: find bandwidth index of OPP and set it along freq index
authorNeil Armstrong <neil.armstrong@linaro.org>
Tue, 17 Dec 2024 14:51:17 +0000 (15:51 +0100)
committerRob Clark <robdclark@chromium.org>
Fri, 3 Jan 2025 15:20:27 +0000 (07:20 -0800)
commit7047e655a5679250fce9d8afac3f87c0bb4af621
tree41b506b92cb253a3647cc8e3b5b01e47a79f9e5d
parent8c1b9451d96b972d0c3b5a5df777dc21bf191b36
drm/msm: adreno: find bandwidth index of OPP and set it along freq index

The Adreno GPU Management Unit (GMU) can also scale the DDR Bandwidth
along the Frequency and Power Domain level, until now we left the OPP
core scale the OPP bandwidth via the interconnect path.

In order to enable bandwidth voting via the GPU Management
Unit (GMU), when an opp is set by devfreq we also look for
the corresponding bandwidth index in the previously generated
bw_table and pass this value along the frequency index to the GMU.

The GMU also takes another vote called AB which is a 16bit quantized
value of the floor bandwidth against the maximum supported bandwidth.

The AB is calculated with a default 25% of the bandwidth like the
downstream implementation too inform the GMU firmware the minimal
quantity of bandwidth we require for this OPP. Only pass the AB
vote starting from A750 GPUs.

Since we now vote for all resources via the GMU, setting the OPP
is no more needed, so we can completely skip calling
dev_pm_opp_set_opp() in this situation.

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Akhil P Oommen <quic_akhilpo@quicinc.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Patchwork: https://patchwork.freedesktop.org/patch/629397/
Signed-off-by: Rob Clark <robdclark@chromium.org>
drivers/gpu/drm/msm/adreno/a6xx_gmu.c
drivers/gpu/drm/msm/adreno/a6xx_gmu.h
drivers/gpu/drm/msm/adreno/a6xx_hfi.c
drivers/gpu/drm/msm/adreno/a6xx_hfi.h
drivers/gpu/drm/msm/adreno/adreno_gpu.h