[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <0bf7b7d5-087b-912e-412e-2b3b742448bd@mediatek.com>
Date: Wed, 21 Sep 2022 16:49:24 +0800
From: Allen-KH Cheng <allen-kh.cheng@...iatek.com>
To: AngeloGioacchino Del Regno
<angelogioacchino.delregno@...labora.com>,
Hsin-Yi Wang <hsinyi@...omium.org>,
Nícolas F. R. A. Prado
<nfraprado@...labora.com>
CC: Chun-Kuang Hu <chunkuang.hu@...nel.org>, <kernel@...labora.com>,
Daniel Vetter <daniel@...ll.ch>,
David Airlie <airlied@...ux.ie>,
Jitao Shi <jitao.shi@...iatek.com>,
Matthias Brugger <matthias.bgg@...il.com>,
Philipp Zabel <p.zabel@...gutronix.de>,
Rex-BC Chen <rex-bc.chen@...iatek.com>,
Xinlei Lee <xinlei.lee@...iatek.com>,
<dri-devel@...ts.freedesktop.org>,
<linux-arm-kernel@...ts.infradead.org>,
<linux-kernel@...r.kernel.org>,
<linux-mediatek@...ts.infradead.org>
Subject: Re: [PATCH] drm/mediatek: dsi: Move mtk_dsi_stop() call back to
mtk_dsi_poweroff()
On 9/19/22 21:32, AngeloGioacchino Del Regno wrote:
> Il 19/09/22 10:40, Hsin-Yi Wang ha scritto:
>> On Mon, Sep 19, 2022 at 4:39 PM Nícolas F. R. A. Prado
>> <nfraprado@...labora.com> wrote:
>>>
>>> As the comment right before the mtk_dsi_stop() call advises,
>>> mtk_dsi_stop() should only be called after
>>> mtk_drm_crtc_atomic_disable(). That's because that function calls
>>> drm_crtc_wait_one_vblank(), which requires the vblank irq to be enabled.
>>>
>>> Previously mtk_dsi_stop(), being in mtk_dsi_poweroff() and guarded by a
>>> refcount, would only be called at the end of
>>> mtk_drm_crtc_atomic_disable(), through the call to
>>> mtk_crtc_ddp_hw_fini().
>>> Commit cde7e2e35c28 ("drm/mediatek: Separate poweron/poweroff from
>>> enable/disable and define new funcs") moved the mtk_dsi_stop() call to
>>> mtk_output_dsi_disable(), causing it to be called before
>>> mtk_drm_crtc_atomic_disable(), and consequently generating vblank
>>> timeout warnings during suspend.
>>>
>>> Move the mtk_dsi_stop() call back to mtk_dsi_poweroff() so that we have
>>> a working vblank irq during mtk_drm_crtc_atomic_disable() and stop
>>> getting vblank timeout warnings.
>>>
>>> Fixes: cde7e2e35c28 ("drm/mediatek: Separate poweron/poweroff from
>>> enable/disable and define new funcs")
>>> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@...labora.com>
>>>
>> Tested-by: Hsin-Yi Wang <hsinyi@...omium.org>
>>
>
> Reviewed-by: AngeloGioacchino Del Regno
> <angelogioacchino.delregno@...labora.com>
>
>
Tested suspend/resume work properly on mt8188 and mt8186 .
Tested-by: Allen-KH Cheng <allen-kh.cheng@...iatek.com>
Powered by blists - more mailing lists