drm/format-helper: Add KUnit tests for drm_fb_xrgb8888_to_rgb565()
authorJosé Expósito <jose.exposito89@gmail.com>
Tue, 26 Jul 2022 23:09:16 +0000 (01:09 +0200)
committerJosé Expósito <jose.exposito89@gmail.com>
Thu, 28 Jul 2022 16:36:45 +0000 (18:36 +0200)
commit5d2f2e8b3a36328a3981996bb20c32d8a0e53b46
tree2b658e64ecb393631b6accf2264ff4367410bd98
parent4d09017aec4f2aa5f6109b32f9a037f35c17a9e0
drm/format-helper: Add KUnit tests for drm_fb_xrgb8888_to_rgb565()

Extend the existing test cases to test the conversion from XRGB8888 to
RGB565.

The documentation and the color picker available on [1] are useful
resources to understand this patch and validate the values returned by
the conversion function.

Tested-by: Tales L. Aparecida <tales.aparecida@gmail.com>
Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: David Gow <davidgow@google.com>
Signed-off-by: José Expósito <jose.exposito89@gmail.com>
Link: http://www.barth-dev.de/online/rgb565-color-picker/
Link: https://patchwork.freedesktop.org/patch/msgid/20220726230916.390575-5-jose.exposito89@gmail.com
drivers/gpu/drm/tests/drm_format_helper_test.c