drm/mediatek: Detect CMDQ execution timeout
authorChun-Kuang Hu <chunkuang.hu@kernel.org>
Wed, 27 Oct 2021 02:18:54 +0000 (10:18 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Jul 2022 14:35:07 +0000 (16:35 +0200)
commitd3f15355704510e22fa395b4030bcd50e6b99969
tree08b982063b353a6322e086f202d9c47707631b16
parent6f77386ddb1cca97da95fb116c2975cc529936f5
drm/mediatek: Detect CMDQ execution timeout

[ Upstream commit eaf80126aba6fd1754837eec91e4c8bbd58ae52e ]

CMDQ is used to update display register in vblank period, so
it should be execute in next 2 vblank. One vblank interrupt
before send message (occasionally) and one vblank interrupt
after cmdq done. If it fail to execute in next 3 vblank,
tiemout happen.

Signed-off-by: Chun-Kuang Hu <chunkuang.hu@kernel.org>
Signed-off-by: jason-jh.lin <jason-jh.lin@mediatek.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/mediatek/mtk_drm_crtc.c