drm/panfrost: Consolidate reset handling
Runtime PM resume and job timeouts both call the same sequence of functions, so consolidate them to a common function. This will make changing the reset related code easier. The MMU also needs some re-initialization on reset, so rework its call. In the process, we hide the address space details within the MMU code in preparation to support multiple address spaces. Cc: Tomeu Vizoso <tomeu.vizoso@collabora.com> Cc: David Airlie <airlied@linux.ie> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: Robin Murphy <robin.murphy@arm.com> Cc: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Reviewed-by: Steven Price <steven.price@arm.com> Signed-off-by: Rob Herring <robh@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20190808222200.13176-7-robh@kernel.org
此提交包含在:
@@ -395,12 +395,7 @@ static void panfrost_job_timedout(struct drm_sched_job *sched_job)
|
||||
/* panfrost_core_dump(pfdev); */
|
||||
|
||||
panfrost_devfreq_record_transition(pfdev, js);
|
||||
panfrost_gpu_soft_reset(pfdev);
|
||||
|
||||
/* TODO: Re-enable all other address spaces */
|
||||
panfrost_mmu_enable(pfdev, 0);
|
||||
panfrost_gpu_power_on(pfdev);
|
||||
panfrost_job_enable_interrupts(pfdev);
|
||||
panfrost_device_reset(pfdev);
|
||||
|
||||
for (i = 0; i < NUM_JOB_SLOTS; i++)
|
||||
drm_sched_resubmit_jobs(&pfdev->js->queue[i].sched);
|
||||
|
新增問題並參考
封鎖使用者