drm/lima: enable runtime pm
authorQiang Yu <yuq825@gmail.com>
Tue, 21 Apr 2020 13:35:51 +0000 (21:35 +0800)
committerQiang Yu <yuq825@gmail.com>
Fri, 24 Apr 2020 12:51:24 +0000 (20:51 +0800)
commit50de2e9ebbc08e1ca27f9b3f0471d92abaaf834a
treefd7f824c060e7385a2b2f9631a3e5622d268df67
parent63945d51490f16aede6d635e785faf56521e5e4a
drm/lima: enable runtime pm

Enable runtime pm by default so GPU suspend when idle
for 200ms. This value can be changed by
autosuspend_delay_ms in device's power sysfs dir.

On Allwinner H3 lima_device_resume takes ~40us and
lima_device_suspend takes ~20us.

Tested-by: Bhushan Shah <bshah@kde.org>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200421133551.31481-11-yuq825@gmail.com
drivers/gpu/drm/lima/lima_drv.c
drivers/gpu/drm/lima/lima_sched.c