summaryrefslogtreecommitdiffstats
path: root/include/drm/drm_fourcc.h
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2018-09-21 15:46:59 +0200
committerGerd Hoffmann <kraxel@redhat.com>2018-09-25 14:49:49 +0200
commit059b5eb5d9554dea689430ad3872dcb37a35053d (patch)
tree72a9d8be21a6b1a1163f4ebd30d44f3d9ab2c2e7 /include/drm/drm_fourcc.h
parentaf334c5d41a9d3b9df3204d50a9a8f566ef64c66 (diff)
downloadlinux-059b5eb5d9554dea689430ad3872dcb37a35053d.tar.gz
linux-059b5eb5d9554dea689430ad3872dcb37a35053d.tar.bz2
linux-059b5eb5d9554dea689430ad3872dcb37a35053d.zip
drm: move native byte order quirk to new drm_driver_legacy_fb_format function
Turns out we need the pixel format fixup not only for the addfb ioctl, but also for fbdev emulation code. Ideally we would place it in drm_mode_legacy_fb_format(). That would create alot of churn though, and most drivers don't care because they never ever run on a big endian platform. So add a new drm_driver_legacy_fb_format() function instead which looks at the mode_config->quirk_addfb_prefer_host_byte_order flag. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/20180921134704.12826-2-kraxel@redhat.com
Diffstat (limited to 'include/drm/drm_fourcc.h')
-rw-r--r--include/drm/drm_fourcc.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/drm/drm_fourcc.h b/include/drm/drm_fourcc.h
index fac831c40106..865ef60c17af 100644
--- a/include/drm/drm_fourcc.h
+++ b/include/drm/drm_fourcc.h
@@ -88,6 +88,8 @@ const struct drm_format_info *
drm_get_format_info(struct drm_device *dev,
const struct drm_mode_fb_cmd2 *mode_cmd);
uint32_t drm_mode_legacy_fb_format(uint32_t bpp, uint32_t depth);
+uint32_t drm_driver_legacy_fb_format(struct drm_device *dev,
+ uint32_t bpp, uint32_t depth);
int drm_format_num_planes(uint32_t format);
int drm_format_plane_cpp(uint32_t format, int plane);
int drm_format_horz_chroma_subsampling(uint32_t format);