Skip to content

Commit b48fd56

Browse files
committed
drm: mcde: Fix forgotten user of drm->dev_private
Unable to handle kernel NULL pointer dereference at virtual address 00000918 pgd = (ptrval) [00000918] *pgd=00000000 Internal error: Oops: 5 [#1] SMP ARM Modules linked in: CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.7.0-15001-gfa384b50b96b-dirty #514 Hardware name: ST-Ericsson Ux5x0 platform (Device Tree Support) PC is at mcde_display_enable+0x78/0x7c0 LR is at mcde_display_enable+0x78/0x7c0 Fix this by using to_mcde() as in other functions. Fixes: fd7ee85 ("drm/mcde: Don't use drm_device->dev_private") Signed-off-by: Linus Walleij <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Cc: Daniel Vetter <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent b984b6d commit b48fd56

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpu/drm/mcde/mcde_display.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -812,7 +812,7 @@ static void mcde_display_enable(struct drm_simple_display_pipe *pipe,
812812
struct drm_crtc *crtc = &pipe->crtc;
813813
struct drm_plane *plane = &pipe->plane;
814814
struct drm_device *drm = crtc->dev;
815-
struct mcde *mcde = drm->dev_private;
815+
struct mcde *mcde = to_mcde(drm);
816816
const struct drm_display_mode *mode = &cstate->mode;
817817
struct drm_framebuffer *fb = plane->state->fb;
818818
u32 format = fb->format->format;

0 commit comments

Comments
 (0)