]> git.baikalelectronics.ru Git - kernel.git/commit
drm/mediatek: Check if fb is null
authorYongqiang Niu <yongqiang.niu@mediatek.com>
Mon, 11 Jan 2021 07:43:44 +0000 (15:43 +0800)
committerChun-Kuang Hu <chunkuang.hu@kernel.org>
Thu, 4 Feb 2021 14:52:55 +0000 (22:52 +0800)
commitda9255129761d9f9055a298a9eeaa3cf34be6603
treeacdf235b465c192691e35c8763073b8cfc9803b8
parentc73a6168484e41ab485315be9b3d627f2dd974da
drm/mediatek: Check if fb is null

It's possible that state->base.fb is null. Add a check before access its
format.

Fixes: 51be20ef4508 ("drm/mediatek: Turn off Alpha bit when plane format has no alpha")
Signed-off-by: Yongqiang Niu <yongqiang.niu@mediatek.com>
Signed-off-by: Chun-Kuang Hu <chunkuang.hu@kernel.org>
drivers/gpu/drm/mediatek/mtk_disp_ovl.c