All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm: renesas: shmobile: Add drm_panic support
@ 2024-05-27 13:34 Geert Uytterhoeven
  2024-05-28  7:21 ` Jocelyn Falempe
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: Geert Uytterhoeven @ 2024-05-27 13:34 UTC (permalink / raw)
  To: Laurent Pinchart, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, David Airlie, Daniel Vetter, Jocelyn Falempe
  Cc: dri-devel, linux-renesas-soc, Geert Uytterhoeven

Add support for the drm_panic module, which displays a message on
the screen when a kernel panic occurs.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
Tested on Armadillo-800-EVA.
---
 drivers/gpu/drm/renesas/shmobile/shmob_drm_plane.c | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/renesas/shmobile/shmob_drm_plane.c b/drivers/gpu/drm/renesas/shmobile/shmob_drm_plane.c
index 07ad17d24294d5e6..9d166ab2af8bd231 100644
--- a/drivers/gpu/drm/renesas/shmobile/shmob_drm_plane.c
+++ b/drivers/gpu/drm/renesas/shmobile/shmob_drm_plane.c
@@ -273,6 +273,13 @@ static const struct drm_plane_helper_funcs shmob_drm_plane_helper_funcs = {
 	.atomic_disable = shmob_drm_plane_atomic_disable,
 };
 
+static const struct drm_plane_helper_funcs shmob_drm_primary_plane_helper_funcs = {
+	.atomic_check = shmob_drm_plane_atomic_check,
+	.atomic_update = shmob_drm_plane_atomic_update,
+	.atomic_disable = shmob_drm_plane_atomic_disable,
+	.get_scanout_buffer = drm_fb_dma_get_scanout_buffer,
+};
+
 static const struct drm_plane_funcs shmob_drm_plane_funcs = {
 	.update_plane = drm_atomic_helper_update_plane,
 	.disable_plane = drm_atomic_helper_disable_plane,
@@ -310,7 +317,12 @@ struct drm_plane *shmob_drm_plane_create(struct shmob_drm_device *sdev,
 
 	splane->index = index;
 
-	drm_plane_helper_add(&splane->base, &shmob_drm_plane_helper_funcs);
+	if (type == DRM_PLANE_TYPE_PRIMARY)
+		drm_plane_helper_add(&splane->base,
+				     &shmob_drm_primary_plane_helper_funcs);
+	else
+		drm_plane_helper_add(&splane->base,
+				     &shmob_drm_plane_helper_funcs);
 
 	return &splane->base;
 }
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2024-09-24 14:17 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-27 13:34 [PATCH] drm: renesas: shmobile: Add drm_panic support Geert Uytterhoeven
2024-05-28  7:21 ` Jocelyn Falempe
2024-05-29  1:03 ` Laurent Pinchart
2024-05-29  8:27   ` Dmitry Baryshkov
2024-05-29  9:10     ` Laurent Pinchart
2024-05-29  9:25       ` Dmitry Baryshkov
2024-05-29  9:55         ` Laurent Pinchart
2024-05-29 13:28           ` Dmitry Baryshkov
2024-05-29 13:33             ` Laurent Pinchart
2024-05-30  8:16               ` Jocelyn Falempe
2024-05-30  8:33                 ` Dmitry Baryshkov
2024-08-29 13:53                   ` Geert Uytterhoeven
2024-09-03 13:23                     ` Jocelyn Falempe
2024-05-29 11:31 ` Sui Jingfeng
2024-08-29 13:51   ` Geert Uytterhoeven
2024-09-24 14:17 ` [PATCH] " Maxime Ripard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.