Commit ba8f16cd authored by Maíra Canal's avatar Maíra Canal Committed by Javier Martinez Canillas

drm: selftest: convert drm_damage_helper selftest to KUnit

Considering the current adoption of the KUnit framework, convert the
DRM damage helper selftest to the KUnit API.
Co-developed-by: default avatarArthur Grillo <arthur.grillo@usp.br>
Signed-off-by: default avatarArthur Grillo <arthur.grillo@usp.br>
Tested-by: default avatarDavid Gow <davidgow@google.com>
Acked-by: default avatarDaniel Latypov <dlatypov@google.com>
Reviewed-by: default avatarJavier Martinez Canillas <javierm@redhat.com>
Signed-off-by: default avatarMaíra Canal <maira.canal@usp.br>
Signed-off-by: default avatarJavier Martinez Canillas <javierm@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220708203052.236290-2-maira.canal@usp.br
parent 4d8f6854
......@@ -72,8 +72,14 @@ config DRM_DEBUG_SELFTEST
config DRM_KUNIT_TEST
tristate "KUnit tests for DRM" if !KUNIT_ALL_TESTS
depends on DRM && KUNIT=y
depends on DRM && KUNIT
select PRIME_NUMBERS
select DRM_DISPLAY_DP_HELPER
select DRM_DISPLAY_HELPER
select DRM_LIB_RANDOM
select DRM_KMS_HELPER
select DRM_BUDDY
select DRM_EXPORT_FOR_TESTS if m
default KUNIT_ALL_TESTS
help
This builds unit tests for DRM. This option is not useful for
......
# SPDX-License-Identifier: GPL-2.0-only
test-drm_modeset-y := test-drm_modeset_common.o test-drm_plane_helper.o \
test-drm_format.o test-drm_framebuffer.o \
test-drm_damage_helper.o test-drm_dp_mst_helper.o \
test-drm_rect.o
test-drm_dp_mst_helper.o test-drm_rect.o
obj-$(CONFIG_DRM_DEBUG_SELFTEST) += test-drm_mm.o test-drm_modeset.o test-drm_cmdline_parser.o \
test-drm_buddy.o
......@@ -15,26 +15,5 @@ selftest(check_drm_format_block_width, igt_check_drm_format_block_width)
selftest(check_drm_format_block_height, igt_check_drm_format_block_height)
selftest(check_drm_format_min_pitch, igt_check_drm_format_min_pitch)
selftest(check_drm_framebuffer_create, igt_check_drm_framebuffer_create)
selftest(damage_iter_no_damage, igt_damage_iter_no_damage)
selftest(damage_iter_no_damage_fractional_src, igt_damage_iter_no_damage_fractional_src)
selftest(damage_iter_no_damage_src_moved, igt_damage_iter_no_damage_src_moved)
selftest(damage_iter_no_damage_fractional_src_moved, igt_damage_iter_no_damage_fractional_src_moved)
selftest(damage_iter_no_damage_not_visible, igt_damage_iter_no_damage_not_visible)
selftest(damage_iter_no_damage_no_crtc, igt_damage_iter_no_damage_no_crtc)
selftest(damage_iter_no_damage_no_fb, igt_damage_iter_no_damage_no_fb)
selftest(damage_iter_simple_damage, igt_damage_iter_simple_damage)
selftest(damage_iter_single_damage, igt_damage_iter_single_damage)
selftest(damage_iter_single_damage_intersect_src, igt_damage_iter_single_damage_intersect_src)
selftest(damage_iter_single_damage_outside_src, igt_damage_iter_single_damage_outside_src)
selftest(damage_iter_single_damage_fractional_src, igt_damage_iter_single_damage_fractional_src)
selftest(damage_iter_single_damage_intersect_fractional_src, igt_damage_iter_single_damage_intersect_fractional_src)
selftest(damage_iter_single_damage_outside_fractional_src, igt_damage_iter_single_damage_outside_fractional_src)
selftest(damage_iter_single_damage_src_moved, igt_damage_iter_single_damage_src_moved)
selftest(damage_iter_single_damage_fractional_src_moved, igt_damage_iter_single_damage_fractional_src_moved)
selftest(damage_iter_damage, igt_damage_iter_damage)
selftest(damage_iter_damage_one_intersect, igt_damage_iter_damage_one_intersect)
selftest(damage_iter_damage_one_outside, igt_damage_iter_damage_one_outside)
selftest(damage_iter_damage_src_moved, igt_damage_iter_damage_src_moved)
selftest(damage_iter_damage_not_visible, igt_damage_iter_damage_not_visible)
selftest(dp_mst_calc_pbn_mode, igt_dp_mst_calc_pbn_mode)
selftest(dp_mst_sideband_msg_req_decode, igt_dp_mst_sideband_msg_req_decode)
......@@ -25,27 +25,6 @@ int igt_check_drm_format_block_width(void *ignored);
int igt_check_drm_format_block_height(void *ignored);
int igt_check_drm_format_min_pitch(void *ignored);
int igt_check_drm_framebuffer_create(void *ignored);
int igt_damage_iter_no_damage(void *ignored);
int igt_damage_iter_no_damage_fractional_src(void *ignored);
int igt_damage_iter_no_damage_src_moved(void *ignored);
int igt_damage_iter_no_damage_fractional_src_moved(void *ignored);
int igt_damage_iter_no_damage_not_visible(void *ignored);
int igt_damage_iter_no_damage_no_crtc(void *ignored);
int igt_damage_iter_no_damage_no_fb(void *ignored);
int igt_damage_iter_simple_damage(void *ignored);
int igt_damage_iter_single_damage(void *ignored);
int igt_damage_iter_single_damage_intersect_src(void *ignored);
int igt_damage_iter_single_damage_outside_src(void *ignored);
int igt_damage_iter_single_damage_fractional_src(void *ignored);
int igt_damage_iter_single_damage_intersect_fractional_src(void *ignored);
int igt_damage_iter_single_damage_outside_fractional_src(void *ignored);
int igt_damage_iter_single_damage_src_moved(void *ignored);
int igt_damage_iter_single_damage_fractional_src_moved(void *ignored);
int igt_damage_iter_damage(void *ignored);
int igt_damage_iter_damage_one_intersect(void *ignored);
int igt_damage_iter_damage_one_outside(void *ignored);
int igt_damage_iter_damage_src_moved(void *ignored);
int igt_damage_iter_damage_not_visible(void *ignored);
int igt_dp_mst_calc_pbn_mode(void *ignored);
int igt_dp_mst_sideband_msg_req_decode(void *ignored);
......
# SPDX-License-Identifier: GPL-2.0
obj-$(CONFIG_DRM_KUNIT_TEST) += drm_format_helper_test.o
obj-$(CONFIG_DRM_KUNIT_TEST) += drm_format_helper_test.o drm_damage_helper_test.o
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment