Message ID | 20230927172849.193996-2-jfalempe@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/panic: Add a drm panic handler | expand |
Hi Am 27.09.23 um 19:22 schrieb Jocelyn Falempe: > drm_panic will need the low-level drm_fb_xxxx_line functions. > > Signed-off-by: Jocelyn Falempe <jfalempe@redhat.com> > --- > drivers/gpu/drm/drm_format_helper.c | 3 ++- > include/drm/drm_format_helper.h | 2 ++ > 2 files changed, 4 insertions(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/drm_format_helper.c b/drivers/gpu/drm/drm_format_helper.c > index f93a4efcee90..e2d3bc2707ea 100644 > --- a/drivers/gpu/drm/drm_format_helper.c > +++ b/drivers/gpu/drm/drm_format_helper.c > @@ -320,7 +320,7 @@ void drm_fb_xrgb8888_to_rgb332(struct iosys_map *dst, const unsigned int *dst_pi > } > EXPORT_SYMBOL(drm_fb_xrgb8888_to_rgb332); > > -static void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigned int pixels) > +void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigned int pixels) This function now requires documentation. You can copy-paste the docs of one of the other helpers and adapt it. Best regards Thomas > { > __le16 *dbuf16 = dbuf; > const __le32 *sbuf32 = sbuf; > @@ -336,6 +336,7 @@ static void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigne > dbuf16[x] = cpu_to_le16(val16); > } > } > +EXPORT_SYMBOL(drm_fb_xrgb8888_to_rgb565_line); > > /* TODO: implement this helper as conversion to RGB565|BIG_ENDIAN */ > static void drm_fb_xrgb8888_to_rgb565_swab_line(void *dbuf, const void *sbuf, > diff --git a/include/drm/drm_format_helper.h b/include/drm/drm_format_helper.h > index 291deb09475b..ca4ac4ff0801 100644 > --- a/include/drm/drm_format_helper.h > +++ b/include/drm/drm_format_helper.h > @@ -67,4 +67,6 @@ size_t drm_fb_build_fourcc_list(struct drm_device *dev, > const u32 *native_fourccs, size_t native_nfourccs, > u32 *fourccs_out, size_t nfourccs_out); > > + > +void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigned int pixels); > #endif /* __LINUX_DRM_FORMAT_HELPER_H */
diff --git a/drivers/gpu/drm/drm_format_helper.c b/drivers/gpu/drm/drm_format_helper.c index f93a4efcee90..e2d3bc2707ea 100644 --- a/drivers/gpu/drm/drm_format_helper.c +++ b/drivers/gpu/drm/drm_format_helper.c @@ -320,7 +320,7 @@ void drm_fb_xrgb8888_to_rgb332(struct iosys_map *dst, const unsigned int *dst_pi } EXPORT_SYMBOL(drm_fb_xrgb8888_to_rgb332); -static void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigned int pixels) +void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigned int pixels) { __le16 *dbuf16 = dbuf; const __le32 *sbuf32 = sbuf; @@ -336,6 +336,7 @@ static void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigne dbuf16[x] = cpu_to_le16(val16); } } +EXPORT_SYMBOL(drm_fb_xrgb8888_to_rgb565_line); /* TODO: implement this helper as conversion to RGB565|BIG_ENDIAN */ static void drm_fb_xrgb8888_to_rgb565_swab_line(void *dbuf, const void *sbuf, diff --git a/include/drm/drm_format_helper.h b/include/drm/drm_format_helper.h index 291deb09475b..ca4ac4ff0801 100644 --- a/include/drm/drm_format_helper.h +++ b/include/drm/drm_format_helper.h @@ -67,4 +67,6 @@ size_t drm_fb_build_fourcc_list(struct drm_device *dev, const u32 *native_fourccs, size_t native_nfourccs, u32 *fourccs_out, size_t nfourccs_out); + +void drm_fb_xrgb8888_to_rgb565_line(void *dbuf, const void *sbuf, unsigned int pixels); #endif /* __LINUX_DRM_FORMAT_HELPER_H */
drm_panic will need the low-level drm_fb_xxxx_line functions. Signed-off-by: Jocelyn Falempe <jfalempe@redhat.com> --- drivers/gpu/drm/drm_format_helper.c | 3 ++- include/drm/drm_format_helper.h | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-)