From: Jocelyn Falempe Date: Thu, 18 Jul 2024 09:21:27 +0000 (+0200) Subject: drm/fb-helper: Set skip_panic if the drm driver supports drm panic X-Git-Tag: v6.12-rc1~126^2~24^2~81 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c2c2a91f3868515969a758042887fdc722216525;p=thirdparty%2Fkernel%2Flinux.git drm/fb-helper: Set skip_panic if the drm driver supports drm panic fb_info->skip_panic flag prevents fbcon from writing to the framebuffer during a kernel panic. So set it when the drm driver implements drm panic, to avoid overwriting the panic screen. Signed-off-by: Jocelyn Falempe Reviewed-by: Javier Martinez Canillas Reviewed-by: Daniel Vetter Link: https://patchwork.freedesktop.org/patch/msgid/20240717090102.968152-3-jfalempe@redhat.com --- diff --git a/drivers/gpu/drm/drm_fb_helper.c b/drivers/gpu/drm/drm_fb_helper.c index e2e19f49342e1..6d1dc99f80aa0 100644 --- a/drivers/gpu/drm/drm_fb_helper.c +++ b/drivers/gpu/drm/drm_fb_helper.c @@ -44,6 +44,7 @@ #include #include "drm_internal.h" +#include "drm_crtc_internal.h" static bool drm_fbdev_emulation = true; module_param_named(fbdev_emulation, drm_fbdev_emulation, bool, 0600); @@ -524,6 +525,7 @@ struct fb_info *drm_fb_helper_alloc_info(struct drm_fb_helper *fb_helper) fb_helper->info = info; info->skip_vt_switch = true; + info->skip_panic = drm_panic_is_enabled(fb_helper->dev); return info; err_release: