[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7807302b-a501-46f5-8326-2b6394a3ab7c@redhat.com>
Date: Mon, 17 Jun 2024 13:38:13 +0200
From: Jocelyn Falempe <jfalempe@...hat.com>
To: Javier Martinez Canillas <javierm@...hat.com>,
linux-kernel@...r.kernel.org
Cc: Geert Uytterhoeven <geert@...ux-m68k.org>, Daniel Vetter
<daniel@...ll.ch>, David Airlie <airlied@...il.com>,
Jyri Sarha <jyri.sarha@....fi>,
Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>,
Maxime Ripard <mripard@...nel.org>, Thomas Zimmermann <tzimmermann@...e.de>,
Tomi Valkeinen <tomi.valkeinen@...asonboard.com>,
dri-devel@...ts.freedesktop.org
Subject: Re: [PATCH] drm/tidss: Add drm_panic support
On 15/06/2024 10:53, Javier Martinez Canillas wrote:
> Add support for the drm_panic module, which displays a pretty user
> friendly message on the screen when a Linux kernel panic occurs.
Thanks for enabling drm panic on another hardware.
It looks good to me.
Reviewed-by: Jocelyn Falempe <jfalempe@...hat.com>
>
> Signed-off-by: Javier Martinez Canillas <javierm@...hat.com>
> ---
> Tested on an AM625 BeaglePlay board by triggering a panic using the
> `echo c > /proc/sysrq-trigger` command.
>
> drivers/gpu/drm/tidss/tidss_plane.c | 14 +++++++++++++-
> 1 file changed, 13 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/tidss/tidss_plane.c b/drivers/gpu/drm/tidss/tidss_plane.c
> index 68fed531f6a7..a5d86822c9e3 100644
> --- a/drivers/gpu/drm/tidss/tidss_plane.c
> +++ b/drivers/gpu/drm/tidss/tidss_plane.c
> @@ -8,6 +8,7 @@
> #include <drm/drm_atomic_helper.h>
> #include <drm/drm_blend.h>
> #include <drm/drm_crtc.h>
> +#include <drm/drm_fb_dma_helper.h>
> #include <drm/drm_fourcc.h>
> #include <drm/drm_framebuffer.h>
> #include <drm/drm_gem_atomic_helper.h>
> @@ -166,6 +167,14 @@ static const struct drm_plane_helper_funcs tidss_plane_helper_funcs = {
> .atomic_disable = tidss_plane_atomic_disable,
> };
>
> +static const struct drm_plane_helper_funcs tidss_primary_plane_helper_funcs = {
> + .atomic_check = tidss_plane_atomic_check,
> + .atomic_update = tidss_plane_atomic_update,
> + .atomic_enable = tidss_plane_atomic_enable,
> + .atomic_disable = tidss_plane_atomic_disable,
> + .get_scanout_buffer = drm_fb_dma_get_scanout_buffer,
> +};
> +
> static const struct drm_plane_funcs tidss_plane_funcs = {
> .update_plane = drm_atomic_helper_update_plane,
> .disable_plane = drm_atomic_helper_disable_plane,
> @@ -211,7 +220,10 @@ struct tidss_plane *tidss_plane_create(struct tidss_device *tidss,
> if (ret < 0)
> goto err;
>
> - drm_plane_helper_add(&tplane->plane, &tidss_plane_helper_funcs);
> + if (type == DRM_PLANE_TYPE_PRIMARY)
> + drm_plane_helper_add(&tplane->plane, &tidss_primary_plane_helper_funcs);
> + else
> + drm_plane_helper_add(&tplane->plane, &tidss_plane_helper_funcs);
>
> drm_plane_create_zpos_property(&tplane->plane, tidss->num_planes, 0,
> num_planes - 1);
Powered by blists - more mailing lists