From: Thomas Zimmermann <tzimmermann@suse.de>
To: daniel@ffwll.ch, airlied@gmail.com, javierm@redhat.com,
jose.exposito89@gmail.com, mairacanal@riseup.net,
mripard@kernel.org, maarten.lankhorst@linux.intel.com
Cc: Thomas Zimmermann <tzimmermann@suse.de>, dri-devel@lists.freedesktop.org
Subject: [PATCH v2 00/13] drm: Fix color-format selection in fbdev emulation
Date: Tue, 20 Dec 2022 17:11:32 +0100 [thread overview]
Message-ID: <20221220161145.27568-1-tzimmermann@suse.de> (raw)
Fix the selection of the fbdev emulation's color format and make
XRGB8888 the only emulated color format. Resolves the blank screen
in cases where video= specifies an unsupported color format. Also
resolves the issues around current format-conversion helpers.
Version 2 of the patchset fixes the format-helper test cases on
big-endian platforms. This involves some changes to existing tests
as well.
DRM drivers usually pick a default format for their fbdev emulation.
Via the kernel's video= parameter, users can specify a different
format. If the given format is unsupported by the driver, the fbdev
console screen remains dark. As the console is essential to many
systems, not displaying anything is to be avoided.
Patch 1 fixes the detection of the firmware's native color format.
The meaning of several color parameters is inconsistent among Linux
and various standards. Take this into account.
Patches 2 to 5 fix the existing conversion helpers and test cases
for big-endian platforms. These patches are new in version 2 of the
patcheset.
As drivers are supposed to provide XRGB8888 as a default fallback
format, provide XRGB8888 conversion helpers in patches 6 to 9. The
new helpers handle cases where the client uses a XRGB8888 frambuffer
and the display scanout buffer uses a different format. All scanout
formats of the simplefb infrastructure should now be covered. The
patchse also extend the Kunit tests for the new formats.
With format conversion in place, patches 10 and 11 fix the single-probe
function's format selection. The helper now goes over the given video=
parameters until it finds a compatible format. If none is found, the
uses driver's default format.
Patches 12 and 13 clean up DRM code in drivers and helpers.
Tested on x86-64 with EFI output and x86 with various VESA color
modes. Also tested on ppc64 with OF output.
v2:
* fix problems with big-endian platforms
Thomas Zimmermann (13):
firmware/sysfb: Fix EFI/VESA format selection
drm/format-helper: Comment on RGB888 byte order
drm/format-helper: Fix test-input format conversion
drm/format-helper: Store RGB565 in little-endian order
drm/format-helper: Type fixes in format-helper tests
drm/format-helper: Flip src/dst-format branches in blit helper
drm/format-helper: Add conversion from XRGB8888 to ARGB8888
drm/format-helper: Add conversion from XRGB8888 to ARGB2101010
drm/format-helper: Add conversion from XRGB8888 to 15-bit RGB555
formats
drm/fh-helper: Split fbdev single-probe helper
drm/fb-helper: Fix single-probe color-format selection
drm/format-helper: Simplify drm_fb_build_fourcc_list()
drm/format-helper: Remove unnecessary conversion helpers
drivers/firmware/sysfb_simplefb.c | 43 +-
drivers/gpu/drm/drm_fb_helper.c | 252 ++++++----
drivers/gpu/drm/drm_format_helper.c | 464 +++++++++++++-----
.../gpu/drm/tests/drm_format_helper_test.c | 386 ++++++++++++++-
drivers/gpu/drm/tiny/ofdrm.c | 20 -
drivers/gpu/drm/tiny/simpledrm.c | 21 -
include/drm/drm_format_helper.h | 16 +-
7 files changed, 898 insertions(+), 304 deletions(-)
--
2.39.0
next reply other threads:[~2022-12-20 16:12 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-20 16:11 Thomas Zimmermann [this message]
2022-12-20 16:11 ` [PATCH v2 01/13] firmware/sysfb: Fix EFI/VESA format selection Thomas Zimmermann
2022-12-20 16:11 ` [PATCH v2 02/13] drm/format-helper: Comment on RGB888 byte order Thomas Zimmermann
2022-12-21 19:30 ` Maíra Canal
2022-12-23 12:37 ` José Expósito
2022-12-20 16:11 ` [PATCH v2 03/13] drm/format-helper: Fix test-input format conversion Thomas Zimmermann
2022-12-21 19:40 ` Maíra Canal
2022-12-23 12:38 ` José Expósito
2022-12-20 16:11 ` [PATCH v2 04/13] drm/format-helper: Store RGB565 in little-endian order Thomas Zimmermann
2022-12-21 19:55 ` Maíra Canal
2022-12-23 12:39 ` José Expósito
2022-12-20 16:11 ` [PATCH v2 05/13] drm/format-helper: Type fixes in format-helper tests Thomas Zimmermann
2022-12-21 19:58 ` Maíra Canal
2022-12-23 12:40 ` José Expósito
2022-12-20 16:11 ` [PATCH v2 06/13] drm/format-helper: Flip src/dst-format branches in blit helper Thomas Zimmermann
2022-12-20 16:11 ` [PATCH v2 07/13] drm/format-helper: Add conversion from XRGB8888 to ARGB8888 Thomas Zimmermann
2022-12-21 12:37 ` kernel test robot
2022-12-21 12:37 ` kernel test robot
2022-12-21 20:07 ` Maíra Canal
2023-01-02 10:00 ` Thomas Zimmermann
2022-12-23 12:44 ` José Expósito
2023-01-02 10:01 ` Thomas Zimmermann
2022-12-20 16:11 ` [PATCH v2 08/13] drm/format-helper: Add conversion from XRGB8888 to ARGB2101010 Thomas Zimmermann
2022-12-23 12:45 ` José Expósito
2022-12-20 16:11 ` [PATCH v2 09/13] drm/format-helper: Add conversion from XRGB8888 to 15-bit RGB555 formats Thomas Zimmermann
2022-12-21 13:58 ` kernel test robot
2022-12-21 13:58 ` kernel test robot
2022-12-23 12:48 ` José Expósito
2022-12-20 16:11 ` [PATCH v2 10/13] drm/fh-helper: Split fbdev single-probe helper Thomas Zimmermann
2022-12-20 16:11 ` [PATCH v2 11/13] drm/fb-helper: Fix single-probe color-format selection Thomas Zimmermann
2022-12-20 16:11 ` [PATCH v2 12/13] drm/format-helper: Simplify drm_fb_build_fourcc_list() Thomas Zimmermann
2022-12-20 16:11 ` [PATCH v2 13/13] drm/format-helper: Remove unnecessary conversion helpers Thomas Zimmermann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221220161145.27568-1-tzimmermann@suse.de \
--to=tzimmermann@suse.de \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=javierm@redhat.com \
--cc=jose.exposito89@gmail.com \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mairacanal@riseup.net \
--cc=mripard@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.