media: drm/mediatek: Add pm runtime support for ovl and rdma
authorYongqiang Niu <yongqiang.niu@mediatek.com>
Mon, 17 Jan 2022 07:05:05 +0000 (08:05 +0100)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 28 Jan 2022 14:30:21 +0000 (15:30 +0100)
commit5db12f5d843b32733979d6f809bbb6974b42e90e
tree1e4dd8512ffaede62b8258924a1d4324323047f4
parent682c3cd8257268a25f46b456e886cc1fe2ad3767
media: drm/mediatek: Add pm runtime support for ovl and rdma

Prepare for smi cleaning up "mediatek,larb".

Display use the dispsys device to call pm_rumtime_get_sync before.
This patch add pm_runtime_xx with ovl and rdma device whose nodes has
"iommus" property, then display could help pm_runtime_get for smi via
ovl or rdma device.

(Yong: Use pm_runtime_resume_and_get instead of pm_runtime_get_sync)

CC: CK Hu <ck.hu@mediatek.com>
Signed-off-by: Yongqiang Niu <yongqiang.niu@mediatek.com>
Signed-off-by: Yong Wu <yong.wu@mediatek.com>
Acked-by: Chun-Kuang Hu <chunkuang.hu@kernel.org>
Tested-by: Frank Wunderlich <frank-w@public-files.de> # BPI-R2/MT7623
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/gpu/drm/mediatek/mtk_disp_ovl.c
drivers/gpu/drm/mediatek/mtk_disp_rdma.c
drivers/gpu/drm/mediatek/mtk_drm_crtc.c