Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a36c9867 authored by Meng Yi's avatar Meng Yi Committed by Stefan Agner
Browse files

drm: fsl-dcu: Fix no fb check bug



For state->fb or state->crtc may be NULL in fsl_dcu_drm_plane_atomic_check
function, if so, return 0.

Signed-off-by: default avatarMeng Yi <meng.yi@nxp.com>
Signed-off-by: default avatarJianwei Wang <jianwei.wang.chn@gmail.com>
Signed-off-by: default avatarStefan Agner <stefan@agner.ch>
parent bc66757a
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -41,6 +41,9 @@ static int fsl_dcu_drm_plane_atomic_check(struct drm_plane *plane,
{
	struct drm_framebuffer *fb = state->fb;

	if (!state->fb || !state->crtc)
		return 0;

	switch (fb->pixel_format) {
	case DRM_FORMAT_RGB565:
	case DRM_FORMAT_RGB888: