mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-18 19:43:43 -04:00
drm/format-helper: Comment on RGB888 byte order
RGB888 is different than the other formats as most of its pixels are unaligned and therefore helper functions do not use endianness conversion helpers. Comment on this in the source code. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Maíra Canal <mcanal@igalia.com> Reviewed-by: José Expósito <jose.exposito89@gmail.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230102112927.26565-3-tzimmermann@suse.de
This commit is contained in:
@@ -407,6 +407,10 @@ static void drm_test_fb_xrgb8888_to_rgb888(struct kunit *test)
|
||||
KUNIT_ASSERT_NOT_ERR_OR_NULL(test, xrgb8888);
|
||||
iosys_map_set_vaddr(&src, xrgb8888);
|
||||
|
||||
/*
|
||||
* RGB888 expected results are already in little-endian
|
||||
* order, so there's no need to convert the test output.
|
||||
*/
|
||||
drm_fb_xrgb8888_to_rgb888(&dst, &result->dst_pitch, &src, &fb, ¶ms->clip);
|
||||
KUNIT_EXPECT_EQ(test, memcmp(buf, result->expected, dst_size), 0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user