| /linux/drivers/gpu/drm/tests/ |
| H A D | drm_cmdline_parser_test.c | 15 static void drm_test_cmdline_force_e_only(struct kunit *test) in drm_test_cmdline_force_e_only() argument 20 KUNIT_ASSERT_TRUE(test, drm_mode_parse_command_line_for_connector(cmdline, in drm_test_cmdline_force_e_only() 22 KUNIT_EXPECT_FALSE(test, mode.specified); in drm_test_cmdline_force_e_only() 23 KUNIT_EXPECT_FALSE(test, mode.refresh_specified); in drm_test_cmdline_force_e_only() 24 KUNIT_EXPECT_FALSE(test, mode.bpp_specified); in drm_test_cmdline_force_e_only() 26 KUNIT_EXPECT_FALSE(test, mode.rb); in drm_test_cmdline_force_e_only() 27 KUNIT_EXPECT_FALSE(test, mode.cvt); in drm_test_cmdline_force_e_only() 28 KUNIT_EXPECT_FALSE(test, mode.interlace); in drm_test_cmdline_force_e_only() 29 KUNIT_EXPECT_FALSE(test, mode.margins); in drm_test_cmdline_force_e_only() 30 KUNIT_EXPECT_EQ(test, mode.force, DRM_FORCE_ON); in drm_test_cmdline_force_e_only() [all …]
|
| H A D | drm_format_test.c | 12 static void drm_test_format_block_width_invalid(struct kunit *test) in drm_test_format_block_width_invalid() argument 16 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 0), 0); in drm_test_format_block_width_invalid() 17 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, -1), 0); in drm_test_format_block_width_invalid() 18 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 1), 0); in drm_test_format_block_width_invalid() 21 static void drm_test_format_block_width_one_plane(struct kunit *test) in drm_test_format_block_width_one_plane() argument 25 KUNIT_ASSERT_NOT_NULL(test, info); in drm_test_format_block_width_one_plane() 27 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 0), 1); in drm_test_format_block_width_one_plane() 28 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 1), 0); in drm_test_format_block_width_one_plane() 29 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, -1), 0); in drm_test_format_block_width_one_plane() 32 static void drm_test_format_block_width_two_plane(struct kunit *test) in drm_test_format_block_width_two_plane() argument [all …]
|
| H A D | drm_gem_shmem_test.c | 48 static void drm_gem_shmem_test_obj_create(struct kunit *test) in drm_gem_shmem_test_obj_create() argument 50 struct drm_device *drm_dev = test->priv; in drm_gem_shmem_test_obj_create() 54 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, shmem); in drm_gem_shmem_test_obj_create() 55 KUNIT_EXPECT_EQ(test, shmem->base.size, TEST_SIZE); in drm_gem_shmem_test_obj_create() 56 KUNIT_EXPECT_NOT_NULL(test, shmem->base.filp); in drm_gem_shmem_test_obj_create() 57 KUNIT_EXPECT_NOT_NULL(test, shmem->base.funcs); in drm_gem_shmem_test_obj_create() 68 static void drm_gem_shmem_test_obj_create_private(struct kunit *test) in drm_gem_shmem_test_obj_create_private() argument 70 struct drm_device *drm_dev = test->priv; in drm_gem_shmem_test_obj_create_private() 80 buf = kunit_kzalloc(test, TEST_SIZE, GFP_KERNEL); in drm_gem_shmem_test_obj_create_private() 81 KUNIT_ASSERT_NOT_NULL(test, buf); in drm_gem_shmem_test_obj_create_private() [all …]
|
| H A D | drm_modes_test.c | 19 static int drm_test_modes_init(struct kunit *test) in drm_test_modes_init() argument 23 priv = kunit_kzalloc(test, sizeof(*priv), GFP_KERNEL); in drm_test_modes_init() 24 KUNIT_ASSERT_NOT_NULL(test, priv); in drm_test_modes_init() 26 priv->dev = drm_kunit_helper_alloc_device(test); in drm_test_modes_init() 27 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, priv->dev); in drm_test_modes_init() 29 priv->drm = __drm_kunit_helper_alloc_drm_device(test, priv->dev, in drm_test_modes_init() 32 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, priv->drm); in drm_test_modes_init() 34 test->priv = priv; in drm_test_modes_init() 39 static void drm_test_modes_analog_tv_ntsc_480i(struct kunit *test) in drm_test_modes_analog_tv_ntsc_480i() argument 41 struct drm_test_modes_priv *priv = test->priv; in drm_test_modes_analog_tv_ntsc_480i() [all …]
|
| /linux/lib/kunit/ |
| H A D | kunit-test.c | 26 struct kunit *test = data; in kunit_test_successful_try() local 27 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_successful_try() 34 struct kunit *test = data; in kunit_test_no_catch() local 36 KUNIT_FAIL(test, "Catch should not be called\n"); in kunit_test_no_catch() 39 static void kunit_test_try_catch_successful_try_no_catch(struct kunit *test) in kunit_test_try_catch_successful_try_no_catch() argument 41 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_try_catch_successful_try_no_catch() 45 test, in kunit_test_try_catch_successful_try_no_catch() 49 kunit_try_catch_run(try_catch, test); in kunit_test_try_catch_successful_try_no_catch() 51 KUNIT_EXPECT_TRUE(test, ctx->function_called); in kunit_test_try_catch_successful_try_no_catch() 56 struct kunit *test = data; in kunit_test_unsuccessful_try() local [all …]
|
| H A D | assert_test.c | 11 #define ASSERT_TEST_EXPECT_CONTAIN(test, str, substr) KUNIT_EXPECT_TRUE(test, strstr(str, substr)) argument 12 #define ASSERT_TEST_EXPECT_NCONTAIN(test, str, substr) KUNIT_EXPECT_FALSE(test, strstr(str, substr)) argument 14 static void kunit_test_is_literal(struct kunit *test) in kunit_test_is_literal() argument 16 KUNIT_EXPECT_TRUE(test, is_literal("5", 5)); in kunit_test_is_literal() 17 KUNIT_EXPECT_TRUE(test, is_literal("0", 0)); in kunit_test_is_literal() 18 KUNIT_EXPECT_TRUE(test, is_literal("1234567890", 1234567890)); in kunit_test_is_literal() 19 KUNIT_EXPECT_TRUE(test, is_literal("-1234567890", -1234567890)); in kunit_test_is_literal() 20 KUNIT_EXPECT_FALSE(test, is_literal("05", 5)); in kunit_test_is_literal() 21 KUNIT_EXPECT_FALSE(test, is_literal("", 0)); in kunit_test_is_literal() 22 KUNIT_EXPECT_FALSE(test, is_literal("-0", 0)); in kunit_test_is_literal() [all …]
|
| /linux/drivers/platform/chrome/ |
| H A D | cros_ec_proto_test.c | 26 static void cros_ec_proto_test_prepare_tx_legacy_normal(struct kunit *test) in cros_ec_proto_test_prepare_tx_legacy_normal() argument 28 struct cros_ec_proto_test_priv *priv = test->priv; in cros_ec_proto_test_prepare_tx_legacy_normal() 45 KUNIT_EXPECT_EQ(test, ret, EC_MSG_TX_PROTO_BYTES + EC_PROTO2_MAX_PARAM_SIZE); in cros_ec_proto_test_prepare_tx_legacy_normal() 46 KUNIT_EXPECT_EQ(test, ec_dev->dout[0], EC_CMD_VERSION0); in cros_ec_proto_test_prepare_tx_legacy_normal() 47 KUNIT_EXPECT_EQ(test, ec_dev->dout[1], EC_CMD_HELLO); in cros_ec_proto_test_prepare_tx_legacy_normal() 48 KUNIT_EXPECT_EQ(test, ec_dev->dout[2], EC_PROTO2_MAX_PARAM_SIZE); in cros_ec_proto_test_prepare_tx_legacy_normal() 49 KUNIT_EXPECT_EQ(test, EC_MSG_TX_HEADER_BYTES, 3); in cros_ec_proto_test_prepare_tx_legacy_normal() 50 KUNIT_EXPECT_EQ(test, ec_dev->dout[EC_MSG_TX_HEADER_BYTES + 0], 0xde); in cros_ec_proto_test_prepare_tx_legacy_normal() 51 KUNIT_EXPECT_EQ(test, ec_dev->dout[EC_MSG_TX_HEADER_BYTES + 1], 0xad); in cros_ec_proto_test_prepare_tx_legacy_normal() 52 KUNIT_EXPECT_EQ(test, ec_dev->dout[EC_MSG_TX_HEADER_BYTES + 2], 0xbe); in cros_ec_proto_test_prepare_tx_legacy_normal() [all …]
|
| /linux/drivers/gpu/drm/amd/display/amdgpu_dm/tests/ |
| H A D | amdgpu_dm_connector_test.c | 8 #include <kunit/test.h> 37 * @test: The KUnit test context 39 static void dm_test_subconnector_type_none(struct kunit *test) in dm_test_subconnector_type_none() argument 41 struct dc_link *link = kunit_kzalloc(test, sizeof(*link), GFP_KERNEL); in dm_test_subconnector_type_none() 43 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, link); in dm_test_subconnector_type_none() 46 KUNIT_EXPECT_EQ(test, (int)get_subconnector_type(link), (int)DRM_MODE_SUBCONNECTOR_Native); in dm_test_subconnector_type_none() 51 * @test: The KUnit test context 53 static void dm_test_subconnector_type_vga(struct kunit *test) in dm_test_subconnector_type_vga() argument 67 dm_test_subconnector_type_dvi_converter(struct kunit * test) dm_test_subconnector_type_dvi_converter() argument 81 dm_test_subconnector_type_dvi_dongle(struct kunit * test) dm_test_subconnector_type_dvi_dongle() argument 95 dm_test_subconnector_type_hdmi_converter(struct kunit * test) dm_test_subconnector_type_hdmi_converter() argument 109 dm_test_subconnector_type_hdmi_dongle(struct kunit * test) dm_test_subconnector_type_hdmi_dongle() argument 123 dm_test_subconnector_type_mismatched(struct kunit * test) dm_test_subconnector_type_mismatched() argument 137 dm_test_subconnector_type_default_unknown(struct kunit * test) dm_test_subconnector_type_default_unknown() argument 153 dm_test_content_type_no_data(struct kunit * test) dm_test_content_type_no_data() argument 165 dm_test_content_type_graphics(struct kunit * test) dm_test_content_type_graphics() argument 177 dm_test_content_type_photo(struct kunit * test) dm_test_content_type_photo() argument 189 dm_test_content_type_cinema(struct kunit * test) dm_test_content_type_cinema() argument 201 dm_test_content_type_game(struct kunit * test) dm_test_content_type_game() argument 213 dm_test_content_type_unknown_defaults_no_data(struct kunit * test) dm_test_content_type_unknown_defaults_no_data() argument 228 dm_test_adjust_colour_depth_fits_at_888(struct kunit * test) dm_test_adjust_colour_depth_fits_at_888() argument 247 dm_test_adjust_colour_depth_reduces_to_888(struct kunit * test) dm_test_adjust_colour_depth_reduces_to_888() argument 267 dm_test_adjust_colour_depth_10bpc_passes(struct kunit * test) dm_test_adjust_colour_depth_10bpc_passes() argument 286 dm_test_adjust_colour_depth_420_halves_clk(struct kunit * test) dm_test_adjust_colour_depth_420_halves_clk() argument 306 dm_test_adjust_colour_depth_420_reduces(struct kunit * test) dm_test_adjust_colour_depth_420_reduces() argument 331 dm_test_adjust_colour_depth_reduces_12bpc_to_10bpc(struct kunit * test) dm_test_adjust_colour_depth_reduces_12bpc_to_10bpc() argument 350 dm_test_adjust_colour_depth_16bpc_no_fallback(struct kunit * test) dm_test_adjust_colour_depth_16bpc_no_fallback() argument 370 dm_test_adjust_colour_depth_none_fits(struct kunit * test) dm_test_adjust_colour_depth_none_fits() argument 388 dm_test_adjust_colour_depth_invalid_depth(struct kunit * test) dm_test_adjust_colour_depth_invalid_depth() argument 408 dm_test_output_color_space_default_rgb_full(struct kunit * test) dm_test_output_color_space_default_rgb_full() argument 425 dm_test_output_color_space_default_rgb_limited(struct kunit * test) dm_test_output_color_space_default_rgb_limited() argument 442 dm_test_output_color_space_default_ycbcr709(struct kunit * test) dm_test_output_color_space_default_ycbcr709() argument 461 dm_test_output_color_space_default_ycbcr601_limited(struct kunit * test) dm_test_output_color_space_default_ycbcr601_limited() argument 479 dm_test_output_color_space_bt601_y_only(struct kunit * test) dm_test_output_color_space_bt601_y_only() argument 495 dm_test_output_color_space_bt601(struct kunit * test) dm_test_output_color_space_bt601() argument 511 dm_test_output_color_space_bt709(struct kunit * test) dm_test_output_color_space_bt709() argument 527 dm_test_output_color_space_bt709_y_only(struct kunit * test) dm_test_output_color_space_bt709_y_only() argument 543 dm_test_output_color_space_oprgb(struct kunit * test) dm_test_output_color_space_oprgb() argument 558 dm_test_output_color_space_bt2020_rgb(struct kunit * test) dm_test_output_color_space_bt2020_rgb() argument 574 dm_test_output_color_space_bt2020_rgb_limited(struct kunit * test) dm_test_output_color_space_bt2020_rgb_limited() argument 591 dm_test_output_color_space_bt2020_ycc(struct kunit * test) dm_test_output_color_space_bt2020_ycc() argument 608 dm_test_output_color_space_default_ycbcr709_y_only(struct kunit * test) dm_test_output_color_space_default_ycbcr709_y_only() argument 627 dm_test_output_color_space_default_ycbcr601(struct kunit * test) dm_test_output_color_space_default_ycbcr601() argument 646 dm_test_output_color_space_bt2020_ycc_rgb_encoding(struct kunit * test) dm_test_output_color_space_bt2020_ycc_rgb_encoding() argument 663 dm_test_output_color_space_bt2020_ycc_rgb_encoding_limited(struct kunit * test) dm_test_output_color_space_bt2020_ycc_rgb_encoding_limited() argument 681 dm_test_output_color_space_bt2020_rgb_ycc_encoding(struct kunit * test) dm_test_output_color_space_bt2020_rgb_ycc_encoding() argument 699 dm_test_convert_color_depth_bpc_mappings(struct kunit * test) dm_test_convert_color_depth_bpc_mappings() argument 713 dm_test_convert_color_depth_bpc_unknown(struct kunit * test) dm_test_convert_color_depth_bpc_unknown() argument 724 dm_test_color_depth_from_info_bpc8(struct kunit * test) dm_test_color_depth_from_info_bpc8() argument 740 dm_test_color_depth_from_info_bpc10(struct kunit * test) dm_test_color_depth_from_info_bpc10() argument 757 dm_test_color_depth_from_info_zero_bpc_defaults_888(struct kunit * test) dm_test_color_depth_from_info_zero_bpc_defaults_888() argument 773 dm_test_color_depth_from_info_requested_bpc_caps(struct kunit * test) dm_test_color_depth_from_info_requested_bpc_caps() argument 790 dm_test_color_depth_from_info_y420_default(struct kunit * test) dm_test_color_depth_from_info_y420_default() argument 806 dm_test_color_depth_from_info_y420_10bpc(struct kunit * test) dm_test_color_depth_from_info_y420_10bpc() argument 822 dm_test_color_depth_from_info_y420_12bpc(struct kunit * test) dm_test_color_depth_from_info_y420_12bpc() argument 838 dm_test_color_depth_from_info_y420_16bpc(struct kunit * test) dm_test_color_depth_from_info_y420_16bpc() argument 854 dm_test_color_depth_from_info_requested_odd_bpc(struct kunit * test) dm_test_color_depth_from_info_requested_odd_bpc() argument 870 dm_test_color_depth_from_info_unsupported_bpc(struct kunit * test) dm_test_color_depth_from_info_unsupported_bpc() argument 888 dm_test_to_connector_type_hdmi(struct kunit * test) dm_test_to_connector_type_hdmi() argument 898 dm_test_to_connector_type_edp(struct kunit * test) dm_test_to_connector_type_edp() argument 908 dm_test_to_connector_type_lvds(struct kunit * test) dm_test_to_connector_type_lvds() argument 918 dm_test_to_connector_type_rgb(struct kunit * test) dm_test_to_connector_type_rgb() argument 928 dm_test_to_connector_type_dp(struct kunit * test) dm_test_to_connector_type_dp() argument 938 dm_test_to_connector_type_dp_mst(struct kunit * test) dm_test_to_connector_type_dp_mst() argument 948 dm_test_to_connector_type_dvi_dvii(struct kunit * test) dm_test_to_connector_type_dvi_dvii() argument 959 dm_test_to_connector_type_dual_link_dvii(struct kunit * test) dm_test_to_connector_type_dual_link_dvii() argument 970 dm_test_to_connector_type_dvi_dvid(struct kunit * test) dm_test_to_connector_type_dvi_dvid() argument 981 dm_test_to_connector_type_dual_link_dvid(struct kunit * test) dm_test_to_connector_type_dual_link_dvid() argument 992 dm_test_to_connector_type_virtual(struct kunit * test) dm_test_to_connector_type_virtual() argument 1002 dm_test_to_connector_type_unknown(struct kunit * test) dm_test_to_connector_type_unknown() argument 1014 dm_test_is_duplicate_mode_empty_list(struct kunit * test) dm_test_is_duplicate_mode_empty_list() argument 1033 dm_test_is_duplicate_mode_match(struct kunit * test) dm_test_is_duplicate_mode_match() argument 1059 dm_test_is_duplicate_mode_no_match(struct kunit * test) dm_test_is_duplicate_mode_no_match() argument 1086 dm_test_is_duplicate_mode_same_size_different_clock(struct kunit * test) dm_test_is_duplicate_mode_same_size_different_clock() argument 1114 dm_test_encoder_crtc_mask_1(struct kunit * test) dm_test_encoder_crtc_mask_1() argument 1129 dm_test_encoder_crtc_mask_2(struct kunit * test) dm_test_encoder_crtc_mask_2() argument 1144 dm_test_encoder_crtc_mask_3(struct kunit * test) dm_test_encoder_crtc_mask_3() argument 1159 dm_test_encoder_crtc_mask_4(struct kunit * test) dm_test_encoder_crtc_mask_4() argument 1174 dm_test_encoder_crtc_mask_5(struct kunit * test) dm_test_encoder_crtc_mask_5() argument 1189 dm_test_encoder_crtc_mask_6(struct kunit * test) dm_test_encoder_crtc_mask_6() argument 1204 dm_test_encoder_crtc_mask_default(struct kunit * test) dm_test_encoder_crtc_mask_default() argument 1222 dm_test_aspect_ratio_no_data(struct kunit * test) dm_test_aspect_ratio_no_data() argument 1234 dm_test_aspect_ratio_4_3(struct kunit * test) dm_test_aspect_ratio_4_3() argument 1246 dm_test_aspect_ratio_16_9(struct kunit * test) dm_test_aspect_ratio_16_9() argument 1258 dm_test_aspect_ratio_64_27(struct kunit * test) dm_test_aspect_ratio_64_27() argument 1270 dm_test_aspect_ratio_256_135(struct kunit * test) dm_test_aspect_ratio_256_135() argument 1284 dm_test_copy_crtc_timing_copies_all_fields(struct kunit * test) dm_test_copy_crtc_timing_copies_all_fields() argument 1326 dm_test_copy_crtc_timing_leaves_non_crtc_fields(struct kunit * test) dm_test_copy_crtc_timing_leaves_non_crtc_fields() argument 1354 dm_test_decide_crtc_timing_scale_enabled(struct kunit * test) dm_test_decide_crtc_timing_scale_enabled() argument 1387 dm_test_decide_crtc_timing_matching_mode(struct kunit * test) dm_test_decide_crtc_timing_matching_mode() argument 1417 dm_test_decide_crtc_timing_no_copy(struct kunit * test) dm_test_decide_crtc_timing_no_copy() argument 1443 dm_test_decide_crtc_timing_no_crtc_clock(struct kunit * test) dm_test_decide_crtc_timing_no_crtc_clock() argument 1477 dm_test_funcs_reset_sets_defaults(struct kunit * test) dm_test_funcs_reset_sets_defaults() argument 1515 dm_test_funcs_reset_edp_abm_level(struct kunit * test) dm_test_funcs_reset_edp_abm_level() argument 1553 dm_test_funcs_reset_edp_abm_disabled(struct kunit * test) dm_test_funcs_reset_edp_abm_disabled() argument 1594 dm_test_atomic_dup_state_copies_fields(struct kunit * test) dm_test_atomic_dup_state_copies_fields() argument 1656 dm_test_fill_hdr_null_metadata(struct kunit * test) dm_test_fill_hdr_null_metadata() argument 1672 dm_test_fill_hdr_zeroes_output(struct kunit * test) dm_test_fill_hdr_zeroes_output() argument 1708 dm_test_prop_ctx_alloc(struct kunit * test) dm_test_prop_ctx_alloc() argument 1750 dm_test_set_property_scaling_center(struct kunit * test) dm_test_set_property_scaling_center() argument 1764 dm_test_set_property_scaling_aspect(struct kunit * test) dm_test_set_property_scaling_aspect() argument 1778 dm_test_set_property_scaling_fullscreen(struct kunit * test) dm_test_set_property_scaling_fullscreen() argument 1792 dm_test_set_property_scaling_none(struct kunit * test) dm_test_set_property_scaling_none() argument 1808 dm_test_set_property_scaling_unchanged(struct kunit * test) dm_test_set_property_scaling_unchanged() argument 1826 dm_test_set_property_underscan_hborder(struct kunit * test) dm_test_set_property_underscan_hborder() argument 1840 dm_test_set_property_underscan_vborder(struct kunit * test) dm_test_set_property_underscan_vborder() argument 1854 dm_test_set_property_underscan_enable(struct kunit * test) dm_test_set_property_underscan_enable() argument 1868 dm_test_set_property_abm_sysfs_control(struct kunit * test) dm_test_set_property_abm_sysfs_control() argument 1883 dm_test_set_property_abm_level_off(struct kunit * test) dm_test_set_property_abm_level_off() argument 1899 dm_test_set_property_abm_level_value(struct kunit * test) dm_test_set_property_abm_level_value() argument 1914 dm_test_set_property_unknown(struct kunit * test) dm_test_set_property_unknown() argument 1933 dm_test_get_property_scaling_center(struct kunit * test) dm_test_get_property_scaling_center() argument 1949 dm_test_get_property_scaling_aspect(struct kunit * test) dm_test_get_property_scaling_aspect() argument 1965 dm_test_get_property_scaling_full(struct kunit * test) dm_test_get_property_scaling_full() argument 1981 dm_test_get_property_scaling_off(struct kunit * test) dm_test_get_property_scaling_off() argument 1997 dm_test_get_property_underscan_borders(struct kunit * test) dm_test_get_property_underscan_borders() argument 2026 dm_test_get_property_abm_sysfs_allowed(struct kunit * test) dm_test_get_property_abm_sysfs_allowed() argument 2042 dm_test_get_property_abm_level(struct kunit * test) dm_test_get_property_abm_level() argument 2059 dm_test_get_property_abm_disabled_zero(struct kunit * test) dm_test_get_property_abm_disabled_zero() argument 2076 dm_test_get_property_unknown(struct kunit * test) dm_test_get_property_unknown() argument 2096 dm_test_highest_refresh_writeback_null(struct kunit * test) dm_test_highest_refresh_writeback_null() argument 2111 dm_test_highest_refresh_cached_base(struct kunit * test) dm_test_highest_refresh_cached_base() argument 2129 dm_test_highest_refresh_preferred_mode(struct kunit * test) dm_test_highest_refresh_preferred_mode() argument 2160 dm_test_is_freesync_video_mode_null_mode(struct kunit * test) dm_test_is_freesync_video_mode_null_mode() argument 2177 dm_test_is_freesync_video_mode_match(struct kunit * test) dm_test_is_freesync_video_mode_match() argument 2214 dm_test_is_freesync_video_mode_no_match(struct kunit * test) dm_test_is_freesync_video_mode_no_match() argument 2247 setup_cacp_fixture(struct kunit * test,struct dm_cacp_fixture * fixture,enum signal_type signal,enum dc_panel_type panel_type) setup_cacp_fixture() argument 2273 dm_test_cacp_caps_unsupported_ip(struct kunit * test) dm_test_cacp_caps_unsupported_ip() argument 2291 dm_test_cacp_caps_excluded_ip_316(struct kunit * test) dm_test_cacp_caps_excluded_ip_316() argument 2309 dm_test_cacp_caps_edp_oled_supported(struct kunit * test) dm_test_cacp_caps_edp_oled_supported() argument 2327 dm_test_cacp_caps_lvds_oled_supported(struct kunit * test) dm_test_cacp_caps_lvds_oled_supported() argument 2345 dm_test_cacp_caps_non_edp_signal(struct kunit * test) dm_test_cacp_caps_non_edp_signal() argument 2365 dm_test_cacp_caps_lcd_panel(struct kunit * test) dm_test_cacp_caps_lcd_panel() argument 2387 setup_panel_type_fixture(struct kunit * test,struct dm_panel_type_fixture * fixture) setup_panel_type_fixture() argument 2420 dm_test_set_panel_type_vsdb_oled(struct kunit * test) dm_test_set_panel_type_vsdb_oled() argument 2438 dm_test_set_panel_type_vsdb_miniled(struct kunit * test) dm_test_set_panel_type_vsdb_miniled() argument 2456 dm_test_set_panel_type_dpcd_oled(struct kunit * test) dm_test_set_panel_type_dpcd_oled() argument 2473 dm_test_set_panel_type_dpcd_miniled(struct kunit * test) dm_test_set_panel_type_dpcd_miniled() argument 2493 dm_test_set_panel_type_did_oled(struct kunit * test) dm_test_set_panel_type_did_oled() argument 2514 dm_test_set_panel_type_did_lcd(struct kunit * test) dm_test_set_panel_type_did_lcd() argument 2535 dm_test_set_panel_type_vendor_lum_heuristic(struct kunit * test) dm_test_set_panel_type_vendor_lum_heuristic() argument 2562 dm_test_set_panel_type_defaults_to_lcd(struct kunit * test) dm_test_set_panel_type_defaults_to_lcd() argument 2581 dm_test_update_subconnector_dp_with_sink(struct kunit * test) dm_test_update_subconnector_dp_with_sink() argument 2625 dm_test_update_subconnector_dp_no_sink(struct kunit * test) dm_test_update_subconnector_dp_no_sink() argument 2668 dm_test_update_subconnector_non_dp_noop(struct kunit * test) dm_test_update_subconnector_non_dp_noop() argument 2726 dm_test_fbc_ctx_alloc(struct kunit * test) dm_test_fbc_ctx_alloc() argument 2760 dm_test_fbc_init_no_compressor(struct kunit * test) dm_test_fbc_init_no_compressor() argument 2775 dm_test_fbc_init_non_edp(struct kunit * test) dm_test_fbc_init_non_edp() argument 2790 dm_test_fbc_init_already_allocated(struct kunit * test) dm_test_fbc_init_already_allocated() argument 2809 dm_test_fbc_init_no_modes(struct kunit * test) dm_test_fbc_init_no_modes() argument 2822 dm_test_alloc_drm(struct kunit * test) dm_test_alloc_drm() argument 2842 dm_test_add_connector(struct kunit * test,struct drm_device * drm,int connector_type) dm_test_add_connector() argument 2862 dm_test_detect_mst_no_connectors(struct kunit * test) dm_test_detect_mst_no_connectors() argument 2878 dm_test_detect_mst_skips_writeback(struct kunit * test) dm_test_detect_mst_skips_writeback() argument 2896 dm_test_detect_mst_non_mst_link(struct kunit * test) dm_test_detect_mst_non_mst_link() argument 2923 dm_test_detect_mst_branch_without_aux(struct kunit * test) dm_test_detect_mst_branch_without_aux() argument 2951 dm_test_alloc_atomic_state(struct kunit * test,int count) dm_test_alloc_atomic_state() argument 2973 dm_test_find_first_crtc_match(struct kunit * test) dm_test_find_first_crtc_match() argument 3000 dm_test_find_first_crtc_no_match(struct kunit * test) dm_test_find_first_crtc_no_match() argument 3029 dm_test_find_first_crtc_empty_state(struct kunit * test) dm_test_find_first_crtc_empty_state() argument 3045 dm_test_find_first_crtc_skips_null_ptr(struct kunit * test) dm_test_find_first_crtc_skips_null_ptr() argument 3073 dm_test_find_first_crtc_returns_first(struct kunit * test) dm_test_find_first_crtc_returns_first() argument 3121 dm_test_panel_ctx_alloc(struct kunit * test) dm_test_panel_ctx_alloc() argument 3164 dm_test_panel_prop_value(struct kunit * test,struct dm_test_panel_ctx * ctx) dm_test_panel_prop_value() argument 3182 dm_test_set_panel_type_samsung_miniled(struct kunit * test) dm_test_set_panel_type_samsung_miniled() argument 3206 dm_test_set_panel_type_samsung_below_threshold(struct kunit * test) dm_test_set_panel_type_samsung_below_threshold() argument 3231 dm_test_set_panel_type_default_lcd(struct kunit * test) dm_test_set_panel_type_default_lcd() argument 3256 dm_test_cacp_ctx_alloc(struct kunit * test) dm_test_cacp_ctx_alloc() argument 3295 dm_test_cacp_caps_edp_supported(struct kunit * test) dm_test_cacp_caps_edp_supported() argument 3308 dm_test_cacp_caps_lvds_supported(struct kunit * test) dm_test_cacp_caps_lvds_supported() argument 3325 dm_test_cacp_caps_old_ip_unsupported(struct kunit * test) dm_test_cacp_caps_old_ip_unsupported() argument 3342 dm_test_cacp_caps_ip_3_1_6_unsupported(struct kunit * test) dm_test_cacp_caps_ip_3_1_6_unsupported() argument 3358 dm_test_cacp_caps_non_edp_lvds_unsupported(struct kunit * test) dm_test_cacp_caps_non_edp_lvds_unsupported() argument 3373 dm_test_cacp_caps_lcd_unsupported(struct kunit * test) dm_test_cacp_caps_lcd_unsupported() argument 3403 dm_test_fill_ctx_alloc(struct kunit * test) dm_test_fill_ctx_alloc() argument 3442 dm_test_fill_stream_borders_zeroed(struct kunit * test) dm_test_fill_stream_borders_zeroed() argument 3470 dm_test_fill_stream_rgb_defaults(struct kunit * test) dm_test_fill_stream_rgb_defaults() argument 3495 dm_test_fill_stream_sync_polarity_positive(struct kunit * test) dm_test_fill_stream_sync_polarity_positive() argument 3514 dm_test_fill_stream_sync_polarity_negative(struct kunit * test) dm_test_fill_stream_sync_polarity_negative() argument 3537 dm_test_fill_stream_inherits_old_stream(struct kunit * test) dm_test_fill_stream_inherits_old_stream() argument 3568 dm_test_fill_stream_timing_from_crtc(struct kunit * test) dm_test_fill_stream_timing_from_crtc() argument 3604 dm_test_fill_stream_color_depth_requested_bpc(struct kunit * test) dm_test_fill_stream_color_depth_requested_bpc() argument 3623 dm_test_fill_stream_content_type(struct kunit * test) dm_test_fill_stream_content_type() argument 3641 dm_test_fill_stream_aspect_ratio(struct kunit * test) dm_test_fill_stream_aspect_ratio() argument 3664 dm_test_fill_stream_encoding_from_caller_ycbcr420(struct kunit * test) dm_test_fill_stream_encoding_from_caller_ycbcr420() argument 3683 dm_test_fill_stream_encoding_from_caller_ycbcr422(struct kunit * test) dm_test_fill_stream_encoding_from_caller_ycbcr422() argument 3702 dm_test_fill_stream_encoding_from_caller_ycbcr444(struct kunit * test) dm_test_fill_stream_encoding_from_caller_ycbcr444() argument 3722 dm_test_fill_stream_hdmi_ep_clamps_depth(struct kunit * test) dm_test_fill_stream_hdmi_ep_clamps_depth() argument 3747 dm_test_fill_stream_non_hdmi_ep_keeps_depth(struct kunit * test) dm_test_fill_stream_non_hdmi_ep_keeps_depth() argument 3785 dm_test_stream_ctx_alloc(struct kunit * test) dm_test_stream_ctx_alloc() argument 3836 dm_test_create_stream_fake_sink_success(struct kunit * test) dm_test_create_stream_fake_sink_success() argument 3853 dm_test_create_stream_sets_dm_context(struct kunit * test) dm_test_create_stream_sets_dm_context() argument 3871 dm_test_create_stream_virtual_signal(struct kunit * test) dm_test_create_stream_virtual_signal() argument 3891 dm_test_create_stream_scaling_src(struct kunit * test) dm_test_create_stream_scaling_src() argument 3913 dm_test_create_stream_existing_sink(struct kunit * test) dm_test_create_stream_existing_sink() argument 3947 dm_test_detect_connector(struct kunit * test) dm_test_detect_connector() argument 3958 dm_test_detect_force_on(struct kunit * test) dm_test_detect_force_on() argument 3973 dm_test_detect_force_on_digital(struct kunit * test) dm_test_detect_force_on_digital() argument 3988 dm_test_detect_force_off(struct kunit * test) dm_test_detect_force_off() argument 4003 dm_test_detect_sink_present(struct kunit * test) dm_test_detect_sink_present() argument 4023 dm_test_detect_no_sink(struct kunit * test) dm_test_detect_no_sink() argument 4046 dm_test_poll_dac_load_returns_cached(struct kunit * test) dm_test_poll_dac_load_returns_cached() argument 4096 dm_test_reg_connector(struct kunit * test) dm_test_reg_connector() argument 4130 dm_test_late_register_non_dp_succeeds(struct kunit * test) dm_test_late_register_non_dp_succeeds() argument 4145 dm_test_unregister_non_dp_noop(struct kunit * test) dm_test_unregister_non_dp_noop() argument 4170 dm_test_destroy_ctx_alloc(struct kunit * test) dm_test_destroy_ctx_alloc() argument 4214 dm_test_destroy_connector(struct kunit * test,struct drm_device * drm) dm_test_destroy_connector() argument 4237 dm_test_destroy_minimal(struct kunit * test) dm_test_destroy_minimal() argument 4250 dm_test_destroy_releases_dc_sink(struct kunit * test) dm_test_destroy_releases_dc_sink() argument 4277 dm_test_destroy_releases_dc_em_sink(struct kunit * test) dm_test_destroy_releases_dc_em_sink() argument 4308 dm_test_encoder_disable_noop(struct kunit * test) dm_test_encoder_disable_noop() argument 4335 dm_test_atomic_check_ctx_alloc(struct kunit * test,int connector_type) dm_test_atomic_check_ctx_alloc() argument 4369 dm_test_atomic_check_edp_native_keeps_scaling(struct kunit * test) dm_test_atomic_check_edp_native_keeps_scaling() argument 4394 dm_test_atomic_check_lvds_non_native_enables_scaling(struct kunit * test) dm_test_atomic_check_lvds_non_native_enables_scaling() argument 4419 dm_test_atomic_check_non_mst_returns_zero(struct kunit * test) dm_test_atomic_check_non_mst_returns_zero() argument 4440 dm_test_hdmi_cec_unset_edid_no_notifier(struct kunit * test) dm_test_hdmi_cec_unset_edid_no_notifier() argument 4465 dm_test_edid_ctx_alloc(struct kunit * test,int connector_type) dm_test_edid_ctx_alloc() argument 4492 dm_test_create_eml_sink_no_edid(struct kunit * test) dm_test_create_eml_sink_no_edid() argument 4509 dm_test_handle_edid_mgmt_dp_sets_link_caps(struct kunit * test) dm_test_handle_edid_mgmt_dp_sets_link_caps() argument 4531 dm_test_handle_edid_mgmt_non_dp_leaves_caps(struct kunit * test) dm_test_handle_edid_mgmt_non_dp_leaves_caps() argument 4556 dm_test_modes_ctx_alloc(struct kunit * test,int connector_type) dm_test_modes_ctx_alloc() argument 4585 dm_test_funcs_force_no_edid(struct kunit * test) dm_test_funcs_force_no_edid() argument 4602 dm_test_validate_stream_null_stream(struct kunit * test) dm_test_validate_stream_null_stream() argument 4613 dm_test_to_encoder_no_encoder(struct kunit * test) dm_test_to_encoder_no_encoder() argument 4627 dm_test_to_encoder_returns_attached(struct kunit * test) dm_test_to_encoder_returns_attached() argument 4644 dm_test_native_mode_no_encoder(struct kunit * test) dm_test_native_mode_no_encoder() argument 4660 dm_test_native_mode_empty_probed_zeroes_clock(struct kunit * test) dm_test_native_mode_empty_probed_zeroes_clock() argument 4678 dm_test_native_mode_copies_preferred(struct kunit * test) dm_test_native_mode_copies_preferred() argument 4706 dm_test_create_common_mode_overrides(struct kunit * test) dm_test_create_common_mode_overrides() argument 4737 dm_test_add_common_modes_non_edp_noop(struct kunit * test) dm_test_add_common_modes_non_edp_noop() argument 4758 dm_test_add_common_modes_edp_adds(struct kunit * test) dm_test_add_common_modes_edp_adds() argument 4776 dm_test_ddc_get_modes_null_edid(struct kunit * test) dm_test_ddc_get_modes_null_edid() argument 4796 dm_test_add_fs_modes_no_preferred_mode(struct kunit * test) dm_test_add_fs_modes_no_preferred_mode() argument 4815 dm_test_add_freesync_modes_null_edid_noop(struct kunit * test) dm_test_add_freesync_modes_null_edid_noop() argument 4840 dm_test_i2c_func_returns_flags(struct kunit * test) dm_test_i2c_func_returns_flags() argument 4853 dm_test_i2c_xfer_no_ddc_pin(struct kunit * test) dm_test_i2c_xfer_no_ddc_pin() argument 4874 dm_test_get_amd_vsdb_unsupported(struct kunit * test) dm_test_get_amd_vsdb_unsupported() argument 4896 dm_test_get_amd_vsdb_supported(struct kunit * test) dm_test_get_amd_vsdb_supported() argument 4916 dm_test_parse_hdmi_amd_vsdb_null_edid(struct kunit * test) dm_test_parse_hdmi_amd_vsdb_null_edid() argument 4935 dm_test_parse_hdmi_amd_vsdb_no_extensions(struct kunit * test) dm_test_parse_hdmi_amd_vsdb_no_extensions() argument 4959 dm_test_parse_hdmi_amd_vsdb_no_cea_ext(struct kunit * test) dm_test_parse_hdmi_amd_vsdb_no_cea_ext() argument 4985 dm_test_parse_displayid_vrr_null_edid(struct kunit * test) dm_test_parse_displayid_vrr_null_edid() argument 5004 dm_test_parse_displayid_vrr_no_displayid(struct kunit * test) dm_test_parse_displayid_vrr_no_displayid() argument 5030 dm_test_parse_displayid_vrr_sets_range(struct kunit * test) dm_test_parse_displayid_vrr_sets_range() argument 5069 dm_test_mode_valid_interlace_rejected(struct kunit * test) dm_test_mode_valid_interlace_rejected() argument 5092 dm_test_mode_valid_dblscan_rejected(struct kunit * test) dm_test_mode_valid_dblscan_rejected() argument 5115 dm_test_hdmi_cec_set_edid_no_notifier(struct kunit * test) dm_test_hdmi_cec_set_edid_no_notifier() argument 5132 dm_test_s3_handle_hdmi_cec_suspend(struct kunit * test) dm_test_s3_handle_hdmi_cec_suspend() argument 5149 dm_test_s3_handle_hdmi_cec_resume(struct kunit * test) dm_test_s3_handle_hdmi_cec_resume() argument 5166 dm_test_create_validate_stream_null_dm_state(struct kunit * test) dm_test_create_validate_stream_null_dm_state() argument 5185 dm_test_update_after_detect_mst_noop(struct kunit * test) dm_test_update_after_detect_mst_noop() argument 5204 dm_test_update_after_detect_sink_unchanged(struct kunit * test) dm_test_update_after_detect_sink_unchanged() argument 5228 dm_test_update_scaling_null_mode(struct kunit * test) dm_test_update_scaling_null_mode() argument 5247 dm_test_update_scaling_fullscreen_default(struct kunit * test) dm_test_update_scaling_fullscreen_default() argument 5273 dm_test_update_scaling_rmx_full(struct kunit * test) dm_test_update_scaling_rmx_full() argument 5302 dm_test_update_scaling_rmx_aspect_pillarbox(struct kunit * test) dm_test_update_scaling_rmx_aspect_pillarbox() argument 5336 dm_test_update_scaling_rmx_aspect_letterbox(struct kunit * test) dm_test_update_scaling_rmx_aspect_letterbox() argument 5365 dm_test_update_scaling_rmx_center(struct kunit * test) dm_test_update_scaling_rmx_center() argument 5394 dm_test_update_scaling_underscan(struct kunit * test) dm_test_update_scaling_underscan() argument [all...] |
| H A D | amdgpu_dm_irq_test.c | 277 static struct dc *dm_test_alloc_dc_with_irq_service(struct kunit *test, in dm_test_alloc_dc_with_irq_service() argument 286 dc = dm_kunit_alloc_dc_with_ctx(test); in dm_test_alloc_dc_with_irq_service() 287 res_pool = kunit_kzalloc(test, sizeof(*res_pool), GFP_KERNEL); in dm_test_alloc_dc_with_irq_service() 288 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, res_pool); in dm_test_alloc_dc_with_irq_service() 289 irqs = kunit_kzalloc(test, sizeof(*irqs), GFP_KERNEL); in dm_test_alloc_dc_with_irq_service() 290 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, irqs); in dm_test_alloc_dc_with_irq_service() 296 info = kunit_kzalloc(test, sizeof(*info) * DAL_IRQ_SOURCES_NUMBER, in dm_test_alloc_dc_with_irq_service() 298 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, info); in dm_test_alloc_dc_with_irq_service() 378 static void dm_test_hpd_to_dal_irq_source_hpd1(struct kunit *test) in dm_test_hpd_to_dal_irq_source_hpd1() argument 380 KUNIT_EXPECT_EQ(test, (int)amdgpu_dm_hpd_to_dal_irq_source(AMDGPU_HPD_1), in dm_test_hpd_to_dal_irq_source_hpd1() [all …]
|
| H A D | amdgpu_dm_helpers_test.c | 32 static void dm_test_edid_extract_panel_id_basic(struct kunit *test) in dm_test_edid_extract_panel_id_basic() argument 37 edid = kunit_kzalloc(test, sizeof(*edid), GFP_KERNEL); in dm_test_edid_extract_panel_id_basic() 38 KUNIT_ASSERT_NOT_NULL(test, edid); in dm_test_edid_extract_panel_id_basic() 52 KUNIT_EXPECT_EQ(test, panel_id, (u32)0x1234CDAB); in dm_test_edid_extract_panel_id_basic() 59 static void dm_test_edid_extract_panel_id_zeros(struct kunit *test) in dm_test_edid_extract_panel_id_zeros() argument 63 edid = kunit_kzalloc(test, sizeof(*edid), GFP_KERNEL); in dm_test_edid_extract_panel_id_zeros() 64 KUNIT_ASSERT_NOT_NULL(test, edid); in dm_test_edid_extract_panel_id_zeros() 66 KUNIT_EXPECT_EQ(test, edid_extract_panel_id(edid), 0U); in dm_test_edid_extract_panel_id_zeros() 76 static struct edid *dm_test_edid_with_panel_id(struct kunit *test, u32 panel_id) in dm_test_edid_with_panel_id() argument 80 edid = kunit_kzalloc(test, sizeof(*edid), GFP_KERNEL); in dm_test_edid_with_panel_id() [all …]
|
| H A D | amdgpu_dm_crtc_test.c | 30 static void dm_test_crtc_modeset_required_active_mode_changed(struct kunit *test) in dm_test_crtc_modeset_required_active_mode_changed() argument 37 KUNIT_EXPECT_TRUE(test, in dm_test_crtc_modeset_required_active_mode_changed() 45 static void dm_test_crtc_modeset_required_active_active_changed(struct kunit *test) in dm_test_crtc_modeset_required_active_active_changed() argument 52 KUNIT_EXPECT_TRUE(test, in dm_test_crtc_modeset_required_active_active_changed() 60 static void dm_test_crtc_modeset_required_active_connectors_changed(struct kunit *test) in dm_test_crtc_modeset_required_active_connectors_changed() argument 67 KUNIT_EXPECT_TRUE(test, in dm_test_crtc_modeset_required_active_connectors_changed() 75 static void dm_test_crtc_modeset_required_inactive(struct kunit *test) in dm_test_crtc_modeset_required_inactive() argument 82 KUNIT_EXPECT_FALSE(test, in dm_test_crtc_modeset_required_inactive() 90 static void dm_test_crtc_modeset_required_no_changes(struct kunit *test) in dm_test_crtc_modeset_required_no_changes() argument 99 KUNIT_EXPECT_FALSE(test, in dm_test_crtc_modeset_required_no_changes() [all …]
|
| H A D | amdgpu_dm_test.c | 30 static void dm_test_is_idle(struct kunit *test) in dm_test_is_idle() argument 32 KUNIT_EXPECT_TRUE(test, dm_is_idle(NULL)); in dm_test_is_idle() 39 static void dm_test_wait_for_idle(struct kunit *test) in dm_test_wait_for_idle() argument 41 KUNIT_EXPECT_EQ(test, dm_wait_for_idle(NULL), 0); in dm_test_wait_for_idle() 48 static void dm_test_soft_reset(struct kunit *test) in dm_test_soft_reset() argument 50 KUNIT_EXPECT_EQ(test, dm_soft_reset(NULL), 0); in dm_test_soft_reset() 57 static void dm_test_set_clockgating_state(struct kunit *test) in dm_test_set_clockgating_state() argument 59 KUNIT_EXPECT_EQ(test, dm_set_clockgating_state(NULL, AMD_CG_STATE_GATE), 0); in dm_test_set_clockgating_state() 66 static void dm_test_set_powergating_state(struct kunit *test) in dm_test_set_powergating_state() argument 68 KUNIT_EXPECT_EQ(test, dm_set_powergating_state(NULL, AMD_PG_STATE_GATE), 0); in dm_test_set_powergating_state() [all …]
|
| H A D | amdgpu_dm_plane_test.c | 83 struct kunit *test) in dm_test_init_validate_dcc_inputs() argument 85 *adev = kunit_kzalloc(test, sizeof(**adev), GFP_KERNEL); in dm_test_init_validate_dcc_inputs() 86 *dc = kunit_kzalloc(test, sizeof(**dc), GFP_KERNEL); in dm_test_init_validate_dcc_inputs() 87 KUNIT_ASSERT_NOT_NULL(test, *adev); in dm_test_init_validate_dcc_inputs() 88 KUNIT_ASSERT_NOT_NULL(test, *dc); in dm_test_init_validate_dcc_inputs() 109 static void dm_test_plane_is_video_format_known_video(struct kunit *test) in dm_test_plane_is_video_format_known_video() argument 111 KUNIT_EXPECT_TRUE(test, amdgpu_dm_plane_is_video_format(DRM_FORMAT_NV12)); in dm_test_plane_is_video_format_known_video() 112 KUNIT_EXPECT_TRUE(test, amdgpu_dm_plane_is_video_format(DRM_FORMAT_NV21)); in dm_test_plane_is_video_format_known_video() 113 KUNIT_EXPECT_TRUE(test, amdgpu_dm_plane_is_video_format(DRM_FORMAT_P010)); in dm_test_plane_is_video_format_known_video() 123 static void dm_test_fill_blending_defaults(struct kunit *test) in dm_test_fill_blending_defaults() argument [all …]
|
| /linux/drivers/base/power/ |
| H A D | runtime-test.c | 13 static void pm_runtime_depth_test(struct kunit *test) in pm_runtime_depth_test() argument 15 struct device *dev = kunit_device_register(test, DEVICE_NAME); in pm_runtime_depth_test() 17 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, dev); in pm_runtime_depth_test() 21 KUNIT_EXPECT_TRUE(test, pm_runtime_suspended(dev)); in pm_runtime_depth_test() 22 KUNIT_EXPECT_EQ(test, 0, pm_runtime_get_sync(dev)); in pm_runtime_depth_test() 23 KUNIT_EXPECT_TRUE(test, pm_runtime_active(dev)); in pm_runtime_depth_test() 24 KUNIT_EXPECT_EQ(test, 1, pm_runtime_get_sync(dev)); /* "already active" */ in pm_runtime_depth_test() 25 KUNIT_EXPECT_EQ(test, 0, pm_runtime_put_sync(dev)); in pm_runtime_depth_test() 26 KUNIT_EXPECT_EQ(test, 0, pm_runtime_put_sync(dev)); in pm_runtime_depth_test() 27 KUNIT_EXPECT_TRUE(test, pm_runtime_suspended(dev)); in pm_runtime_depth_test() [all …]
|
| /linux/sound/soc/codecs/ |
| H A D | cs-amp-lib-test.c | 3 // KUnit test for the Cirrus common amplifier library. 9 #include <kunit/test.h> 10 #include <kunit/test-bug.h> 63 static struct cirrus_amp_efi_data *cs_amp_lib_test_cal_blob_dup(struct kunit *test) in cs_amp_lib_test_cal_blob_dup() 65 struct cs_amp_lib_test_priv *priv = test->priv; in cs_amp_lib_test_cal_blob_dup() 68 KUNIT_ASSERT_EQ(test, struct_size(priv->cal_blob, data, priv->cal_blob->count), in cs_amp_lib_test_cal_blob_dup() 70 temp = kunit_kmalloc(test, priv->cal_blob->size, GFP_KERNEL); in cs_amp_lib_test_cal_blob_dup() 71 KUNIT_ASSERT_NOT_NULL(test, temp); in cs_amp_lib_test_cal_blob_dup() 77 static void cs_amp_lib_test_init_dummy_cal_blob(struct kunit *test, int num_amps) in cs_amp_lib_test_init_dummy_cal_blob() 79 struct cs_amp_lib_test_priv *priv = test in cs_amp_lib_test_init_dummy_cal_blob() 61 cs_amp_lib_test_cal_blob_dup(struct kunit * test) cs_amp_lib_test_cal_blob_dup() argument 75 cs_amp_lib_test_init_dummy_cal_blob(struct kunit * test,int num_amps) cs_amp_lib_test_init_dummy_cal_blob() argument 106 cs_amp_lib_test_get_target_uid(struct kunit * test) cs_amp_lib_test_get_target_uid() argument 135 cs_amp_lib_test_cal_data_too_short_test(struct kunit * test) cs_amp_lib_test_cal_data_too_short_test() argument 157 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_bad_count() local 175 cs_amp_lib_test_cal_count_too_big_test(struct kunit * test) cs_amp_lib_test_cal_count_too_big_test() argument 203 cs_amp_lib_test_no_cal_data_test(struct kunit * test) cs_amp_lib_test_no_cal_data_test() argument 227 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable() local 271 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_all_zeros() local 312 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_hp_cal_efi_variable() local 342 cs_amp_lib_test_get_hp_efi_cal(struct kunit * test) cs_amp_lib_test_get_hp_efi_cal() argument 361 cs_amp_lib_test_get_efi_cal_by_uid_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_by_uid_test() argument 395 cs_amp_lib_test_get_efi_cal_by_index_unchecked_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_by_index_unchecked_test() argument 426 cs_amp_lib_test_get_efi_cal_by_index_checked_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_by_index_checked_test() argument 462 cs_amp_lib_test_get_efi_cal_by_index_uid_mismatch_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_by_index_uid_mismatch_test() argument 488 cs_amp_lib_test_get_efi_cal_by_index_fallback_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_by_index_fallback_test() argument 529 cs_amp_lib_test_get_efi_cal_uid_not_found_noindex_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_uid_not_found_noindex_test() argument 558 cs_amp_lib_test_get_efi_cal_uid_not_found_index_not_found_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_uid_not_found_index_not_found_test() argument 587 cs_amp_lib_test_get_efi_cal_no_uid_index_not_found_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_no_uid_index_not_found_test() argument 605 cs_amp_lib_test_get_efi_cal_no_uid_no_index_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_no_uid_no_index_test() argument 626 cs_amp_lib_test_get_efi_cal_zero_not_matched_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_zero_not_matched_test() argument 653 cs_amp_lib_test_get_efi_cal_empty_entry_test(struct kunit * test) cs_amp_lib_test_get_efi_cal_empty_entry_test() argument 703 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_write_cal_coeff() local 722 cs_amp_lib_test_write_cal_data_test(struct kunit * test) cs_amp_lib_test_write_cal_data_test() argument 770 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_read_cal_coeff() local 787 cs_amp_lib_test_read_cal_data_test(struct kunit * test) cs_amp_lib_test_read_cal_data_test() argument 811 cs_amp_lib_test_write_ambient_test(struct kunit * test) cs_amp_lib_test_write_ambient_test() argument 845 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_set_efi_variable() local 881 cs_amp_lib_test_create_new_cal_efi(struct kunit * test) cs_amp_lib_test_create_new_cal_efi() argument 942 cs_amp_lib_test_create_new_cal_efi_indexed(struct kunit * test) cs_amp_lib_test_create_new_cal_efi_indexed() argument 995 cs_amp_lib_test_create_new_cal_efi_indexed_no_max(struct kunit * test) cs_amp_lib_test_create_new_cal_efi_indexed_no_max() argument 1050 cs_amp_lib_test_grow_append_cal_efi(struct kunit * test) cs_amp_lib_test_grow_append_cal_efi() argument 1142 cs_amp_lib_test_grow_append_cal_efi_indexed(struct kunit * test) cs_amp_lib_test_grow_append_cal_efi_indexed() argument 1223 cs_amp_lib_test_cal_efi_all_zeros_add_first(struct kunit * test) cs_amp_lib_test_cal_efi_all_zeros_add_first() argument 1253 cs_amp_lib_test_cal_efi_all_zeros_add_first_no_shrink(struct kunit * test) cs_amp_lib_test_cal_efi_all_zeros_add_first_no_shrink() argument 1284 cs_amp_lib_test_cal_efi_all_zeros_add_first_indexed(struct kunit * test) cs_amp_lib_test_cal_efi_all_zeros_add_first_indexed() argument 1318 cs_amp_lib_test_cal_efi_all_zeros_add_first_indexed_no_shrink(struct kunit * test) cs_amp_lib_test_cal_efi_all_zeros_add_first_indexed_no_shrink() argument 1353 cs_amp_lib_test_grow_append_cal_efi_indexed_no_max(struct kunit * test) cs_amp_lib_test_grow_append_cal_efi_indexed_no_max() argument 1459 cs_amp_lib_test_grow_cal_efi_replace_indexed(struct kunit * test) cs_amp_lib_test_grow_cal_efi_replace_indexed() argument 1554 cs_amp_lib_test_grow_cal_efi_replace_by_uid(struct kunit * test) cs_amp_lib_test_grow_cal_efi_replace_by_uid() argument 1649 cs_amp_lib_test_cal_efi_replace_by_uid(struct kunit * test) cs_amp_lib_test_cal_efi_replace_by_uid() argument 1723 cs_amp_lib_test_cal_efi_replace_by_index(struct kunit * test) cs_amp_lib_test_cal_efi_replace_by_index() argument 1801 cs_amp_lib_test_cal_efi_deduplicate(struct kunit * test) cs_amp_lib_test_cal_efi_deduplicate() argument 1892 cs_amp_lib_test_cal_efi_find_free(struct kunit * test) cs_amp_lib_test_cal_efi_find_free() argument 1973 cs_amp_lib_test_cal_efi_bad_cal_target(struct kunit * test) cs_amp_lib_test_cal_efi_bad_cal_target() argument 1996 cs_amp_lib_test_cal_efi_write_denied(struct kunit * test) cs_amp_lib_test_cal_efi_write_denied() argument 2032 cs_amp_lib_test_cal_efi_attr_preserved(struct kunit * test) cs_amp_lib_test_cal_efi_attr_preserved() argument 2066 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_set_hp_efi_cal_variable() local 2091 cs_amp_lib_test_cal_efi_update_hp(struct kunit * test) cs_amp_lib_test_cal_efi_update_hp() argument 2123 cs_amp_lib_test_spkid_lenovo_not_present(struct kunit * test) cs_amp_lib_test_spkid_lenovo_not_present() argument 2141 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_lenovo_d0() local 2160 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_lenovo_d1() local 2179 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_lenovo_00() local 2189 cs_amp_lib_test_spkid_lenovo_d0(struct kunit * test) cs_amp_lib_test_spkid_lenovo_d0() argument 2201 cs_amp_lib_test_spkid_lenovo_d1(struct kunit * test) cs_amp_lib_test_spkid_lenovo_d1() argument 2213 cs_amp_lib_test_spkid_lenovo_illegal(struct kunit * test) cs_amp_lib_test_spkid_lenovo_illegal() argument 2234 cs_amp_lib_test_spkid_lenovo_oversize(struct kunit * test) cs_amp_lib_test_spkid_lenovo_oversize() argument 2252 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_hp_30() local 2271 struct kunit *test = kunit_get_current_test(); cs_amp_lib_test_get_efi_variable_hp_31() local 2284 cs_amp_lib_test_spkid_hp_30(struct kunit * test) cs_amp_lib_test_spkid_hp_30() argument 2296 cs_amp_lib_test_spkid_hp_31(struct kunit * test) cs_amp_lib_test_spkid_hp_31() argument 2308 cs_amp_lib_test_case_init(struct kunit * test) cs_amp_lib_test_case_init() argument [all...] |
| /linux/drivers/base/test/ |
| H A D | property-entry-test.c | 12 static void pe_test_uints(struct kunit *test) in pe_test_uints() argument 30 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, node); in pe_test_uints() 33 KUNIT_EXPECT_EQ(test, error, 1); in pe_test_uints() 36 KUNIT_EXPECT_EQ(test, error, 0); in pe_test_uints() 37 KUNIT_EXPECT_EQ(test, val_u8, 8); in pe_test_uints() 40 KUNIT_EXPECT_EQ(test, error, 0); in pe_test_uints() 41 KUNIT_EXPECT_EQ(test, array_u8[0], 8); in pe_test_uints() 44 KUNIT_EXPECT_NE(test, error, 0); in pe_test_uints() 47 KUNIT_EXPECT_NE(test, error, 0); in pe_test_uints() 50 KUNIT_EXPECT_NE(test, error, 0); in pe_test_uints() [all …]
|
| /linux/lib/tests/ |
| H A D | string_kunit.c | 24 #define STRCMP_TEST_EXPECT_EQUAL(test, fn, ...) KUNIT_EXPECT_EQ(test, fn(__VA_ARGS__), 0) argument 25 #define STRCMP_TEST_EXPECT_LOWER(test, fn, ...) KUNIT_EXPECT_LT(test, fn(__VA_ARGS__), 0) argument 26 #define STRCMP_TEST_EXPECT_GREATER(test, fn, ...) KUNIT_EXPECT_GT(test, fn(__VA_ARGS__), 0) argument 34 static void string_test_memset16(struct kunit *test) in string_test_memset16() argument 39 p = kunit_kzalloc(test, 256 * 2 * 2, GFP_KERNEL); in string_test_memset16() 40 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, p); in string_test_memset16() 49 KUNIT_ASSERT_EQ_MSG(test, v, 0xa1a1, in string_test_memset16() 52 KUNIT_ASSERT_EQ_MSG(test, v, 0xb1b2, in string_test_memset16() 55 KUNIT_ASSERT_EQ_MSG(test, v, 0xa1a1, in string_test_memset16() 63 static void string_test_memset32(struct kunit *test) in string_test_memset32() argument [all …]
|
| H A D | base64_kunit.c | 38 static void run_perf_and_check(struct kunit *test, const char *label, int size, in run_perf_and_check() argument 47 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, in); in run_perf_and_check() 48 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, enc); in run_perf_and_check() 49 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, decoded); in run_perf_and_check() 56 KUNIT_EXPECT_EQ(test, dec_len, size); in run_perf_and_check() 57 KUNIT_EXPECT_MEMEQ(test, decoded, in, size); in run_perf_and_check() 63 kunit_info(test, "[%s] encode run : %lluns", label, t1); in run_perf_and_check() 67 kunit_info(test, "[%s] decode run : %lluns", label, t2); in run_perf_and_check() 74 static void base64_performance_tests(struct kunit *test) in base64_performance_tests() argument 77 run_perf_and_check(test, "64B", 64, BASE64_STD); in base64_performance_tests() [all …]
|
| H A D | list-test.c | 18 static void list_test_list_init(struct kunit *test) in list_test_list_init() argument 37 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list1)); in list_test_list_init() 38 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list2)); in list_test_list_init() 39 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list3)); in list_test_list_init() 40 KUNIT_EXPECT_TRUE(test, list_empty_careful(list4)); in list_test_list_init() 41 KUNIT_EXPECT_TRUE(test, list_empty_careful(list5)); in list_test_list_init() 47 static void list_test_list_add(struct kunit *test) in list_test_list_add() argument 56 KUNIT_EXPECT_PTR_EQ(test, list.next, &b); in list_test_list_add() 57 KUNIT_EXPECT_PTR_EQ(test, b.prev, &list); in list_test_list_add() 58 KUNIT_EXPECT_PTR_EQ(test, b.next, &a); in list_test_list_add() [all …]
|
| /linux/drivers/gpu/drm/vkms/tests/ |
| H A D | vkms_config_test.c | 89 static void vkms_config_test_empty_config(struct kunit *test) in vkms_config_test_empty_config() argument 95 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, config); in vkms_config_test_empty_config() 99 KUNIT_EXPECT_STREQ(test, vkms_config_get_device_name(config), "test"); in vkms_config_test_empty_config() 101 KUNIT_EXPECT_EQ(test, vkms_config_get_num_planes(config), 0); in vkms_config_test_empty_config() 102 KUNIT_EXPECT_EQ(test, vkms_config_get_num_crtcs(config), 0); in vkms_config_test_empty_config() 103 KUNIT_EXPECT_EQ(test, vkms_config_get_num_encoders(config), 0); in vkms_config_test_empty_config() 104 KUNIT_EXPECT_EQ(test, vkms_config_get_num_connectors(config), 0); in vkms_config_test_empty_config() 106 KUNIT_EXPECT_FALSE(test, vkms_config_is_valid(config)); in vkms_config_test_empty_config() 132 static void vkms_config_test_default_config(struct kunit *test) in vkms_config_test_default_config() argument 134 const struct default_config_case *params = test->param_value; in vkms_config_test_default_config() [all …]
|
| /linux/drivers/gpu/drm/ttm/tests/ |
| H A D | ttm_tt_test.c | 39 static void ttm_tt_init_basic(struct kunit *test) in ttm_tt_init_basic() argument 41 const struct ttm_tt_test_case *params = test->param_value; in ttm_tt_init_basic() 50 tt = kunit_kzalloc(test, sizeof(*tt), GFP_KERNEL); in ttm_tt_init_basic() 51 KUNIT_ASSERT_NOT_NULL(test, tt); in ttm_tt_init_basic() 53 bo = ttm_bo_kunit_init(test, test->priv, params->size, NULL); in ttm_tt_init_basic() 56 KUNIT_ASSERT_EQ(test, err, 0); in ttm_tt_init_basic() 58 KUNIT_ASSERT_EQ(test, tt->num_pages, num_pages + extra_pages); in ttm_tt_init_basic() 60 KUNIT_ASSERT_EQ(test, tt->page_flags, page_flags); in ttm_tt_init_basic() 61 KUNIT_ASSERT_EQ(test, tt->caching, caching); in ttm_tt_init_basic() 63 KUNIT_ASSERT_NULL(test, tt->dma_address); in ttm_tt_init_basic() [all …]
|
| /linux/drivers/net/ethernet/microchip/vcap/ |
| H A D | vcap_api_kunit.c | 247 static void test_vcap_xn_rule_creator(struct kunit *test, int cid, in test_vcap_xn_rule_creator() argument 286 KUNIT_ASSERT_NE(test, VCAP_KFS_NO_VALUE, keyset); in test_vcap_xn_rule_creator() 291 KUNIT_EXPECT_PTR_NE(test, NULL, rule); in test_vcap_xn_rule_creator() 305 KUNIT_EXPECT_EQ(test, 0, ret); in test_vcap_xn_rule_creator() 306 KUNIT_EXPECT_EQ(test, keyset, rule->keyset); in test_vcap_xn_rule_creator() 307 KUNIT_EXPECT_EQ(test, actionset, rule->actionset); in test_vcap_xn_rule_creator() 308 KUNIT_EXPECT_EQ(test, size, ri->size); in test_vcap_xn_rule_creator() 312 KUNIT_EXPECT_EQ(test, 0, ret); in test_vcap_xn_rule_creator() 313 KUNIT_EXPECT_EQ(test, expected_addr, ri->addr); in test_vcap_xn_rule_creator() 329 static void vcap_api_set_bit_1_test(struct kunit *test) in vcap_api_set_bit_1_test() argument [all …]
|
| /linux/drivers/clk/ |
| H A D | clk_test.c | 194 static int clk_test_init_with_ops(struct kunit *test, const struct clk_ops *ops) in clk_test_init_with_ops() argument 200 ctx = kunit_kzalloc(test, sizeof(*ctx), GFP_KERNEL); in clk_test_init_with_ops() 204 test->priv = ctx; in clk_test_init_with_ops() 217 static int clk_test_init(struct kunit *test) in clk_test_init() argument 219 return clk_test_init_with_ops(test, &clk_dummy_rate_ops); in clk_test_init() 222 static int clk_maximize_test_init(struct kunit *test) in clk_maximize_test_init() argument 224 return clk_test_init_with_ops(test, &clk_dummy_maximize_rate_ops); in clk_maximize_test_init() 227 static int clk_minimize_test_init(struct kunit *test) in clk_minimize_test_init() argument 229 return clk_test_init_with_ops(test, &clk_dummy_minimize_rate_ops); in clk_minimize_test_init() 232 static void clk_test_exit(struct kunit *test) in clk_test_exit() argument [all …]
|
| H A D | clk-gate_test.c | 11 static void clk_gate_register_test_dev(struct kunit *test) in clk_gate_register_test_dev() argument 17 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, pdev); in clk_gate_register_test_dev() 21 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, ret); in clk_gate_register_test_dev() 22 KUNIT_EXPECT_STREQ(test, "test_gate", clk_hw_get_name(ret)); in clk_gate_register_test_dev() 23 KUNIT_EXPECT_EQ(test, 0UL, clk_hw_get_flags(ret)); in clk_gate_register_test_dev() 29 static void clk_gate_register_test_parent_names(struct kunit *test) in clk_gate_register_test_parent_names() argument 36 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, parent); in clk_gate_register_test_parent_names() 40 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, ret); in clk_gate_register_test_parent_names() 41 KUNIT_EXPECT_PTR_EQ(test, parent, clk_hw_get_parent(ret)); in clk_gate_register_test_parent_names() 47 static void clk_gate_register_test_parent_data(struct kunit *test) in clk_gate_register_test_parent_data() argument [all …]
|
| /linux/tools/perf/tests/ |
| H A D | Build | 3 perf-test-y += builtin-test.o 4 perf-test-y += tests-scripts.o 5 perf-test-y += parse-events.o 6 perf-test-y += uncore-event-sorting.o 7 perf-test-y += dso-data.o 8 perf-test-y += vmlinux-kallsyms.o 9 perf-test-y += openat-syscall.o 10 perf-test-y += openat-syscall-all-cpus.o 11 perf-test [all...] |