[PATCH v7 1/5] drm/imagination: Use pwrseq for TH1520 GPU power management

Michal Wilczynski m.wilczynski at samsung.com
Mon Jul 14 11:07:30 UTC 2025



On 7/3/25 12:21, Michal Wilczynski wrote:
> 
> 
> On 6/26/25 11:33, Michal Wilczynski wrote:
>> Update the Imagination PVR DRM driver to leverage the pwrseq framework
>> for managing the complex power sequence of the GPU on the T-HEAD TH1520
>> SoC.
>>
>> To cleanly separate platform specific logic from the generic driver,
>> this patch introduces a `pwr_power_sequence_ops` struct containing
>> function pointers for power_on and power_off operations. This allows for
>> different power management strategies to be selected at probe time based
>> on the device's compatible string.
>>
>> A `pvr_device_data` struct, associated with each compatible in the
>> of_device_id table, points to the appropriate ops table (manual or
>> pwrseq).
>>
>> At probe time, the driver inspects the assigned ops struct. If the
>> pwrseq variant is detected, the driver calls
>> devm_pwrseq_get("gpu-power"), deferring probe if the sequencer is not
>> yet available. Otherwise, it falls back to the existing manual clock and
>> reset handling. The runtime PM callbacks now call the appropriate
>> functions via the ops table.
>>
>> Reviewed-by: Ulf Hansson <ulf.hansson at linaro.org>
>> Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski at linaro.org>
>> Signed-off-by: Michal Wilczynski <m.wilczynski at samsung.com>
>> ---
>>  drivers/gpu/drm/imagination/pvr_device.c |  36 +++++++-
>>  drivers/gpu/drm/imagination/pvr_device.h |  17 ++++
>>  drivers/gpu/drm/imagination/pvr_drv.c    |  27 +++++-
>>  drivers/gpu/drm/imagination/pvr_power.c  | 139 ++++++++++++++++++++++---------
>>  drivers/gpu/drm/imagination/pvr_power.h  |  13 +++
>>  5 files changed, 185 insertions(+), 47 deletions(-)
>>
> 
> Hi,
> 
> I'm checking in on the status of my pwrseq patch above. Is this on track
> for the next merge window?
> 
> Please let me know if there's anything else needed from my end to help
> get it ready.
> 
> Best regards,


Hi Matt,

I was very happy to see the recent "pvr: various enablement changes" get
merged in Mesa [1]. Congratulations to the team on that progress.

I just wanted to check in and see if you have any more requests for this
series ?

[1] - https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33998

Best regards,
-- 
Michal Wilczynski <m.wilczynski at samsung.com>


More information about the dri-devel mailing list