All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/7] drm: Fix the color-depth/bpp confusion
@ 2022-11-16 16:09 ` Thomas Zimmermann
  0 siblings, 0 replies; 34+ messages in thread
From: Thomas Zimmermann @ 2022-11-16 16:09 UTC (permalink / raw)
  To: daniel, airlied, mripard, maarten.lankhorst, xinliang.liu,
	tiantao6, jstultz, kong.kongxinwei, puck.chen, paul.kocialkowski,
	javierm, airlied, kraxel
  Cc: Thomas Zimmermann, dri-devel, virtualization

A number of drivers mix up the meaning of bits-per-pixel and color
depth. For each of them, set the correct values. As a rule of thumb,
the color depth is the number of color and alpha bits that affect
image composition. The bpp value is the color depth in the pixel
plus the filler bits.

The color depth is exported to userspace, while the bpp value only
affects fbdev emulation. Currently, fbdev fails if it selects a color
format that is unsupported by the driver. The fix would be to fall
back to a driver default value for the bpp. Getting the default fixed
in drivers will then allow us to fix the fbdev format selection.

Thomas Zimmermann (7):
  drm/hisilicon/hibmc: Fix preferred depth and bpp
  drm/logicvc: Fix preferred fbdev cpp
  drm/cirrus: Decouple fbdev bpp value from color depth
  drm/ofdrm: Set preferred depth from format of scanout buffer
  drm/simpledrm: Set preferred depth from format of scanout buffer
  drm/solomon: Set preferred color depth and bpp to the correct values
  drm/fb-helper: Don't use the preferred depth for the BPP default

 drivers/gpu/drm/drm_fbdev_generic.c             | 15 +++++++++------
 drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c |  4 ++--
 drivers/gpu/drm/logicvc/logicvc_drm.c           | 14 +++++++++++++-
 drivers/gpu/drm/solomon/ssd130x.c               |  4 ++--
 drivers/gpu/drm/tiny/cirrus.c                   |  2 +-
 drivers/gpu/drm/tiny/ofdrm.c                    | 13 +------------
 drivers/gpu/drm/tiny/simpledrm.c                |  4 ++--
 7 files changed, 30 insertions(+), 26 deletions(-)

-- 
2.38.1

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

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

end of thread, other threads:[~2022-11-22 14:43 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-16 16:09 [PATCH 0/7] drm: Fix the color-depth/bpp confusion Thomas Zimmermann
2022-11-16 16:09 ` Thomas Zimmermann
2022-11-16 16:09 ` [PATCH 1/7] drm/hisilicon/hibmc: Fix preferred depth and bpp Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 12:52   ` Javier Martinez Canillas
2022-11-18 13:18     ` Thomas Zimmermann
2022-11-18 13:18       ` Thomas Zimmermann
2022-11-18 13:31       ` Javier Martinez Canillas
2022-11-16 16:09 ` [PATCH 2/7] drm/logicvc: Fix preferred fbdev cpp Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 13:08   ` Javier Martinez Canillas
2022-11-18 13:22     ` Thomas Zimmermann
2022-11-18 13:22       ` Thomas Zimmermann
2022-11-18 13:41       ` Javier Martinez Canillas
2022-11-18 13:48         ` Thomas Zimmermann
2022-11-18 13:48           ` Thomas Zimmermann
2022-11-18 14:01           ` Javier Martinez Canillas
2022-11-16 16:09 ` [PATCH 3/7] drm/cirrus: Decouple fbdev bpp value from color depth Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 13:44   ` Javier Martinez Canillas
2022-11-16 16:09 ` [PATCH 4/7] drm/ofdrm: Set preferred depth from format of scanout buffer Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 14:06   ` Javier Martinez Canillas
2022-11-16 16:09 ` [PATCH 5/7] drm/simpledrm: " Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 14:07   ` Javier Martinez Canillas
2022-11-16 16:09 ` [PATCH 6/7] drm/solomon: Set preferred color depth and bpp to the correct values Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 14:08   ` Javier Martinez Canillas
2022-11-16 16:09 ` [PATCH 7/7] drm/fb-helper: Don't use the preferred depth for the BPP default Thomas Zimmermann
2022-11-16 16:09   ` Thomas Zimmermann
2022-11-18 14:12   ` Javier Martinez Canillas
2022-11-22 14:43   ` Daniel Vetter
2022-11-22 14:43     ` Daniel Vetter

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.