From 99434726be49517332272752af6dffefdea7bb8a Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Tue, 19 May 2020 14:05:12 -0700 Subject: test: Pass commandline arguments to run_test run_test is called by the "runtest" console command. Console commands can take arguments, so pass along the arguments to run_test to allow parameters to be passed to run_test. The following command was used for automatic replacement: git grep --name-only 'void run_test(void)' |\ xargs sed -i 's#void run_test(void)#void run_test(int argc, char **argv)##' BRANCH=none BUG=b:155897971 TEST=make buildall -j TEST=Build and flash flash_write_protect test > runtest 1 Signed-off-by: Tom Hughes Change-Id: Ib20b955d5ec6b98f525c94c24aadefd7a6a320a5 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2209418 Reviewed-by: Yicheng Li Commit-Queue: Yicheng Li Tested-by: Yicheng Li --- test/accel_cal.c | 2 +- test/aes.c | 2 +- test/base32.c | 2 +- test/battery_get_params_smart.c | 2 +- test/bklight_lid.c | 2 +- test/bklight_passthru.c | 2 +- test/button.c | 2 +- test/cec.c | 2 +- test/charge_manager.c | 2 +- test/charge_ramp.c | 2 +- test/compile_time_macros.c | 2 +- test/console_edit.c | 2 +- test/crc32.c | 2 +- test/entropy.c | 2 +- test/extpwr_gpio.c | 2 +- test/fan.c | 2 +- test/flash.c | 2 +- test/fp.c | 2 +- test/fpsensor.c | 2 +- test/fpsensor_crypto.c | 2 +- test/fpsensor_state.c | 2 +- test/hooks.c | 2 +- test/host_command.c | 2 +- test/i2c_bitbang.c | 2 +- test/inductive_charging.c | 2 +- test/interrupt.c | 2 +- test/is_enabled.c | 2 +- test/is_enabled_error.c | 2 +- test/kasa.c | 2 +- test/kb_8042.c | 2 +- test/kb_mkbp.c | 2 +- test/kb_scan.c | 2 +- test/lid_sw.c | 2 +- test/lightbar.c | 2 +- test/mag_cal.c | 2 +- test/math_util.c | 2 +- test/motion_angle.c | 2 +- test/motion_angle_tablet.c | 2 +- test/motion_lid.c | 2 +- test/motion_sense_fifo.c | 2 +- test/mpu.c | 2 +- test/mutex.c | 2 +- test/newton_fit.c | 2 +- test/online_calibration.c | 2 +- test/pingpong.c | 2 +- test/power_button.c | 2 +- test/printf.c | 2 +- test/queue.c | 2 +- test/rollback.c | 2 +- test/rollback_entropy.c | 2 +- test/rsa.c | 2 +- test/rtc.c | 2 +- test/sbs_charging_v2.c | 2 +- test/sha256.c | 2 +- test/shmalloc.c | 2 +- test/static_if.c | 2 +- test/static_if_error.c | 2 +- test/stillness_detector.c | 2 +- test/stm32f_rtc.c | 2 +- test/stress.c | 2 +- test/system.c | 2 +- test/thermal.c | 2 +- test/timer_calib.c | 2 +- test/timer_dos.c | 2 +- test/uptime.c | 2 +- test/usb_common_test.c | 2 +- test/usb_pd.c | 2 +- test/usb_pd_console.c | 2 +- test/usb_pd_int.c | 2 +- test/usb_pe_drp.c | 2 +- test/usb_ppc.c | 2 +- test/usb_prl.c | 2 +- test/usb_sm_framework_h3.c | 2 +- test/usb_typec_ctvpd.c | 2 +- test/usb_typec_drp_acc_trysrc.c | 2 +- test/utils.c | 2 +- test/utils_str.c | 2 +- test/vboot.c | 2 +- 78 files changed, 78 insertions(+), 78 deletions(-) (limited to 'test') diff --git a/test/accel_cal.c b/test/accel_cal.c index e7dd876995..1fa657b36c 100644 --- a/test/accel_cal.c +++ b/test/accel_cal.c @@ -125,7 +125,7 @@ void before_test(void) accel_cal_reset(&cal); } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/aes.c b/test/aes.c index 53b7c770e4..1c71e2874e 100644 --- a/test/aes.c +++ b/test/aes.c @@ -644,7 +644,7 @@ static void test_aes_speed(void) ccprintf("AES duration %lld us\n", (long long)(t1.val - t0.val)); } -void run_test(void) +void run_test(int argc, char **argv) { watchdog_reload(); diff --git a/test/base32.c b/test/base32.c index 6fd574bb73..433c874cba 100644 --- a/test/base32.c +++ b/test/base32.c @@ -198,7 +198,7 @@ static int test_decode(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/battery_get_params_smart.c b/test/battery_get_params_smart.c index 465d667f48..3163fb587e 100644 --- a/test/battery_get_params_smart.c +++ b/test/battery_get_params_smart.c @@ -90,7 +90,7 @@ static int test_param_failures(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_param_failures); diff --git a/test/bklight_lid.c b/test/bklight_lid.c index f3a14b2570..99167a71a6 100644 --- a/test/bklight_lid.c +++ b/test/bklight_lid.c @@ -95,7 +95,7 @@ static int test_hostcommand(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/bklight_passthru.c b/test/bklight_passthru.c index 3727447cd7..170cc734cd 100644 --- a/test/bklight_passthru.c +++ b/test/bklight_passthru.c @@ -129,7 +129,7 @@ static int test_hostcommand(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/button.c b/test/button.c index 04d05e8bc3..e457eaa786 100644 --- a/test/button.c +++ b/test/button.c @@ -272,7 +272,7 @@ static void button_test_init(void) button_state[i] = UNCHANGED; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/cec.c b/test/cec.c index 64b230e509..9377e4fcd3 100644 --- a/test/cec.c +++ b/test/cec.c @@ -119,7 +119,7 @@ static int test_queue_overflow(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { queue = &overflow_queue.queue; diff --git a/test/charge_manager.c b/test/charge_manager.c index 08d640cbb0..51a587b68a 100644 --- a/test/charge_manager.c +++ b/test/charge_manager.c @@ -782,7 +782,7 @@ static int test_unknown_dualrole_capability(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/charge_ramp.c b/test/charge_ramp.c index faec9c8888..01571c8f3a 100644 --- a/test/charge_ramp.c +++ b/test/charge_ramp.c @@ -492,7 +492,7 @@ static int test_ramp_limit(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/compile_time_macros.c b/test/compile_time_macros.c index 9ef52bc7e3..40e962e101 100644 --- a/test/compile_time_macros.c +++ b/test/compile_time_macros.c @@ -55,7 +55,7 @@ static int test_GENMASK_ULL(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/console_edit.c b/test/console_edit.c index 607e67757e..8d0721c14e 100644 --- a/test/console_edit.c +++ b/test/console_edit.c @@ -273,7 +273,7 @@ static int test_output_channel(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/crc32.c b/test/crc32.c index 986a1c60c3..3521bce4a9 100644 --- a/test/crc32.c +++ b/test/crc32.c @@ -63,7 +63,7 @@ static int test_kat0(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/entropy.c b/test/entropy.c index a19a8eb33f..fb066a6c5b 100644 --- a/test/entropy.c +++ b/test/entropy.c @@ -29,7 +29,7 @@ uint32_t log2(int32_t val) return log2_mult * (val1 + val2)/2; } -void run_test(void) +void run_test(int argc, char **argv) { const int loopcount = 512; diff --git a/test/extpwr_gpio.c b/test/extpwr_gpio.c index d118c54a54..d1f77c9167 100644 --- a/test/extpwr_gpio.c +++ b/test/extpwr_gpio.c @@ -51,7 +51,7 @@ static int test_hook(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/fan.c b/test/fan.c index f3a9a150c9..d03aa0213c 100644 --- a/test/fan.c +++ b/test/fan.c @@ -105,7 +105,7 @@ static int test_fan(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_fan); diff --git a/test/flash.c b/test/flash.c index fef33ffd17..ff9bf6f9d4 100644 --- a/test/flash.c +++ b/test/flash.c @@ -498,7 +498,7 @@ int task_test(void *data) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { msleep(30); /* Wait for TASK_ID_TEST to initialize */ task_wake(TASK_ID_TEST); diff --git a/test/fp.c b/test/fp.c index 296a78e4df..1945c09189 100644 --- a/test/fp.c +++ b/test/fp.c @@ -300,7 +300,7 @@ static int test_mat44_fp_solve(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/fpsensor.c b/test/fpsensor.c index a1c586f939..d7a7cc6988 100644 --- a/test/fpsensor.c +++ b/test/fpsensor.c @@ -5,7 +5,7 @@ #include "test_util.h" -void run_test(void) +void run_test(int argc, char **argv) { /* No tests yet */ test_print_result(); diff --git a/test/fpsensor_crypto.c b/test/fpsensor_crypto.c index 1f54e1ecf9..d0fd92cf7c 100644 --- a/test/fpsensor_crypto.c +++ b/test/fpsensor_crypto.c @@ -614,7 +614,7 @@ test_static int test_command_read_match_secret_unreadable(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_hkdf_expand); RUN_TEST(test_derive_encryption_key_failure_seed_not_set); diff --git a/test/fpsensor_state.c b/test/fpsensor_state.c index 5faef570f1..9681bcad39 100644 --- a/test/fpsensor_state.c +++ b/test/fpsensor_state.c @@ -169,7 +169,7 @@ test_static int test_fp_set_sensor_mode(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_fp_enc_status_valid_flags); RUN_TEST(test_fp_tpm_seed_not_set); diff --git a/test/hooks.c b/test/hooks.c index e7226ea353..8d12494688 100644 --- a/test/hooks.c +++ b/test/hooks.c @@ -159,7 +159,7 @@ static int test_repeating_deferred(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/host_command.c b/test/host_command.c index 4b51a6f8fc..ba1d4dcd96 100644 --- a/test/host_command.c +++ b/test/host_command.c @@ -300,7 +300,7 @@ static int test_hostcmd_clears_unused_data(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { wait_for_task_started(); test_reset(); diff --git a/test/i2c_bitbang.c b/test/i2c_bitbang.c index 6440e9b363..ab1136a922 100644 --- a/test/i2c_bitbang.c +++ b/test/i2c_bitbang.c @@ -180,7 +180,7 @@ static int test_i2c_write(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/inductive_charging.c b/test/inductive_charging.c index f3cc6cf908..d487e171fd 100644 --- a/test/inductive_charging.c +++ b/test/inductive_charging.c @@ -157,7 +157,7 @@ static int test_debounce_charge_done(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/interrupt.c b/test/interrupt.c index 5b69ee3c20..f43c8b2ccd 100644 --- a/test/interrupt.c +++ b/test/interrupt.c @@ -71,7 +71,7 @@ static int interrupt_disable_test(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/is_enabled.c b/test/is_enabled.c index c994d84b45..fe93bafc31 100644 --- a/test/is_enabled.c +++ b/test/is_enabled.c @@ -24,7 +24,7 @@ static int test_blank(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/is_enabled_error.c b/test/is_enabled_error.c index 2f17925337..3fcd80afe0 100644 --- a/test/is_enabled_error.c +++ b/test/is_enabled_error.c @@ -17,7 +17,7 @@ static int test_invalid_value(void) return EC_ERROR_UNKNOWN; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/kasa.c b/test/kasa.c index 8221db2ae5..3ecd32a556 100644 --- a/test/kasa.c +++ b/test/kasa.c @@ -62,7 +62,7 @@ static int test_kasa_calculate(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/kb_8042.c b/test/kb_8042.c index 64f5bd952b..9705b506fe 100644 --- a/test/kb_8042.c +++ b/test/kb_8042.c @@ -323,7 +323,7 @@ static int test_vivaldi_top_keys(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); wait_for_task_started(); diff --git a/test/kb_mkbp.c b/test/kb_mkbp.c index 4624896268..6ab010807d 100644 --- a/test/kb_mkbp.c +++ b/test/kb_mkbp.c @@ -286,7 +286,7 @@ int fifo_underrun(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { ec_int_level = 1; test_reset(); diff --git a/test/kb_scan.c b/test/kb_scan.c index 24015758b1..e0ba11137d 100644 --- a/test/kb_scan.c +++ b/test/kb_scan.c @@ -483,7 +483,7 @@ int test_task(void *data) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { msleep(30); /* Wait for TASK_ID_TEST to initialize */ task_wake(TASK_ID_TEST); diff --git a/test/lid_sw.c b/test/lid_sw.c index e671f9b9d0..8163f74716 100644 --- a/test/lid_sw.c +++ b/test/lid_sw.c @@ -83,7 +83,7 @@ static int test_debounce(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/lightbar.c b/test/lightbar.c index d0952c92e8..363d73a36b 100644 --- a/test/lightbar.c +++ b/test/lightbar.c @@ -319,7 +319,7 @@ test_static int test_als_lightbar(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { /* Ensure tasks are started before running tests */ usleep(SECOND); diff --git a/test/mag_cal.c b/test/mag_cal.c index 65ffa13d8f..8ee3b41480 100644 --- a/test/mag_cal.c +++ b/test/mag_cal.c @@ -81,7 +81,7 @@ static int test_mag_cal_computes_bias(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/math_util.c b/test/math_util.c index 27947be377..b45de1a29d 100644 --- a/test/math_util.c +++ b/test/math_util.c @@ -78,7 +78,7 @@ static int test_rotate(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/motion_angle.c b/test/motion_angle.c index 37157dc0c0..06872a7a41 100644 --- a/test/motion_angle.c +++ b/test/motion_angle.c @@ -91,7 +91,7 @@ static int test_lid_angle_less180(void) } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/motion_angle_tablet.c b/test/motion_angle_tablet.c index 5f096b1603..0829d9bb31 100644 --- a/test/motion_angle_tablet.c +++ b/test/motion_angle_tablet.c @@ -99,7 +99,7 @@ static int test_lid_angle_less180(void) } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/motion_lid.c b/test/motion_lid.c index d25de9e3fe..a9ede3a651 100644 --- a/test/motion_lid.c +++ b/test/motion_lid.c @@ -332,7 +332,7 @@ static int test_lid_angle(void) } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/motion_sense_fifo.c b/test/motion_sense_fifo.c index bc678b00cb..09d3404032 100644 --- a/test/motion_sense_fifo.c +++ b/test/motion_sense_fifo.c @@ -353,7 +353,7 @@ void before_test(void) motion_sense_fifo_reset(); } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); motion_sense_fifo_init(); diff --git a/test/mpu.c b/test/mpu.c index 5675633087..25b2c58903 100644 --- a/test/mpu.c +++ b/test/mpu.c @@ -176,7 +176,7 @@ test_static int test_mpu_get_rw_regions(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { enum ec_image cur_image = system_get_image_copy(); diff --git a/test/mutex.c b/test/mutex.c index 266b94ac31..d5e7e09c51 100644 --- a/test/mutex.c +++ b/test/mutex.c @@ -109,7 +109,7 @@ int mutex_main_task(void *unused) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { wait_for_task_started(); task_wake(TASK_ID_MTX1); diff --git a/test/newton_fit.c b/test/newton_fit.c index 929681b35a..9648fbfd9a 100644 --- a/test/newton_fit.c +++ b/test/newton_fit.c @@ -126,7 +126,7 @@ static int test_newton_fit_calculate(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/online_calibration.c b/test/online_calibration.c index f51781f2ac..622ea6232d 100644 --- a/test/online_calibration.c +++ b/test/online_calibration.c @@ -222,7 +222,7 @@ void before_test(void) online_calibration_init(); } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/pingpong.c b/test/pingpong.c index 3a5d6afd6e..f3ff89341f 100644 --- a/test/pingpong.c +++ b/test/pingpong.c @@ -59,7 +59,7 @@ int task_tick(void *data) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { wait_for_task_started(); task_wake(TASK_ID_TICK); diff --git a/test/power_button.c b/test/power_button.c index 26e3dcc1b0..5fe9136105 100644 --- a/test/power_button.c +++ b/test/power_button.c @@ -89,7 +89,7 @@ static int test_debounce(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/printf.c b/test/printf.c index 43f4125e0c..ae85837cd5 100644 --- a/test/printf.c +++ b/test/printf.c @@ -297,7 +297,7 @@ test_static int test_vsnprintf_combined(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/queue.c b/test/queue.c index d0671e3a74..e9f791eb3d 100644 --- a/test/queue.c +++ b/test/queue.c @@ -416,7 +416,7 @@ void before_test(void) queue_init(&test_queue8); } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/rollback.c b/test/rollback.c index e5a566c22f..77a3bff1d6 100644 --- a/test/rollback.c +++ b/test/rollback.c @@ -116,7 +116,7 @@ test_static int test_lock_rollback(void) return EC_ERROR_UNKNOWN; } -void run_test(void) +void run_test(int argc, char **argv) { ccprintf("Running rollback test\n"); RUN_TEST(test_lock_rollback); diff --git a/test/rollback_entropy.c b/test/rollback_entropy.c index 6c1435ec95..8b9ace2f31 100644 --- a/test/rollback_entropy.c +++ b/test/rollback_entropy.c @@ -185,7 +185,7 @@ test_static int test_add_entropy(void) return rv; } -void run_test(void) +void run_test(int argc, char **argv) { ccprintf("Running rollback_entropy test\n"); RUN_TEST(test_add_entropy); diff --git a/test/rsa.c b/test/rsa.c index aaa4a656e2..cd9530c4ad 100644 --- a/test/rsa.c +++ b/test/rsa.c @@ -19,7 +19,7 @@ static uint32_t rsa_workbuf[3 * RSANUMBYTES/4]; -void run_test(void) +void run_test(int argc, char **argv) { int good; diff --git a/test/rtc.c b/test/rtc.c index 5d16d3008c..3e53f85611 100644 --- a/test/rtc.c +++ b/test/rtc.c @@ -96,7 +96,7 @@ static int test_time_conversion(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_time_conversion); diff --git a/test/sbs_charging_v2.c b/test/sbs_charging_v2.c index 1460af3502..7477c9d290 100644 --- a/test/sbs_charging_v2.c +++ b/test/sbs_charging_v2.c @@ -713,7 +713,7 @@ static int test_low_battery_hostevents(void) -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_charge_state); RUN_TEST(test_low_battery); diff --git a/test/sha256.c b/test/sha256.c index 6af3fb1343..105ae8fec5 100644 --- a/test/sha256.c +++ b/test/sha256.c @@ -172,7 +172,7 @@ static int test_hmac(const uint8_t *key, int key_len, return 1; } -void run_test(void) +void run_test(int argc, char **argv) { ccprintf("Testing short message (8 bytes)\n"); if (!test_sha256(sha256_8_input, sizeof(sha256_8_input), diff --git a/test/shmalloc.c b/test/shmalloc.c index b841d7ae1e..70e0fb5aab 100644 --- a/test/shmalloc.c +++ b/test/shmalloc.c @@ -207,7 +207,7 @@ static int shmem_is_ok(int line) */ static uint32_t test_map; -void run_test(void) +void run_test(int argc, char **argv) { int index; const int shmem_size = shared_mem_size(); diff --git a/test/static_if.c b/test/static_if.c index 46e8057d7f..f70f7d30c3 100644 --- a/test/static_if.c +++ b/test/static_if.c @@ -39,7 +39,7 @@ static int test_static_if_unused_no_fail(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/static_if_error.c b/test/static_if_error.c index bbe4839981..65882b3bbd 100644 --- a/test/static_if_error.c +++ b/test/static_if_error.c @@ -24,7 +24,7 @@ /* This is intended to cause a compilation error. */ TEST_MACRO(CONFIG_FOO) __maybe_unused int foo; -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/stillness_detector.c b/test/stillness_detector.c index 04e2e55d7e..e881525491 100644 --- a/test/stillness_detector.c +++ b/test/stillness_detector.c @@ -123,7 +123,7 @@ static int test_resets(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/stm32f_rtc.c b/test/stm32f_rtc.c index 9224b9f757..fc1d0aaedb 100644 --- a/test/stm32f_rtc.c +++ b/test/stm32f_rtc.c @@ -44,7 +44,7 @@ test_static int test_rtc_alarm(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_rtc_alarm); diff --git a/test/stress.c b/test/stress.c index 3808cc2bd1..96689d840c 100644 --- a/test/stress.c +++ b/test/stress.c @@ -128,7 +128,7 @@ static int test_adc(void) } #endif -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/system.c b/test/system.c index 37d5e5751a..6874708cc7 100644 --- a/test/system.c +++ b/test/system.c @@ -92,7 +92,7 @@ static void fail_and_clean_up(void) test_fail(); } -void run_test(void) +void run_test(int argc, char **argv) { uint32_t state = system_get_scratchpad(); diff --git a/test/thermal.c b/test/thermal.c index 6f6a7cd358..2ffd4fe6ad 100644 --- a/test/thermal.c +++ b/test/thermal.c @@ -642,7 +642,7 @@ static int test_thermistor_linear_interpolate(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_init_val); RUN_TEST(test_sensors_can_be_read); diff --git a/test/timer_calib.c b/test/timer_calib.c index 361689f8bd..68603762fe 100644 --- a/test/timer_calib.c +++ b/test/timer_calib.c @@ -56,7 +56,7 @@ int timer_calib_task(void *data) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { task_wake(TASK_ID_TESTTMR); } diff --git a/test/timer_dos.c b/test/timer_dos.c index d70f7e8231..c681300102 100644 --- a/test/timer_dos.c +++ b/test/timer_dos.c @@ -68,7 +68,7 @@ int task_timer(void *seed) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { wait_for_task_started(); task_wake(TASK_ID_TMRD); diff --git a/test/uptime.c b/test/uptime.c index 7ff39f98db..651628ab7b 100644 --- a/test/uptime.c +++ b/test/uptime.c @@ -62,7 +62,7 @@ test_static int test_host_uptime_info_command_failure(void) return EC_RES_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/usb_common_test.c b/test/usb_common_test.c index d054f4ead2..c7cec27640 100644 --- a/test/usb_common_test.c +++ b/test/usb_common_test.c @@ -66,7 +66,7 @@ int test_pd_get_cc_state(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { RUN_TEST(test_pd_get_cc_state); diff --git a/test/usb_pd.c b/test/usb_pd.c index c009bdf7bb..f572b5bb21 100644 --- a/test/usb_pd.c +++ b/test/usb_pd.c @@ -900,7 +900,7 @@ static int test_sink(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); init_ports(); diff --git a/test/usb_pd_console.c b/test/usb_pd_console.c index 82b34d8109..e7649e3d32 100644 --- a/test/usb_pd_console.c +++ b/test/usb_pd_console.c @@ -422,7 +422,7 @@ static int test_command_pd_dualrole5(void) } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/usb_pd_int.c b/test/usb_pd_int.c index 280c7c192f..b93001a27f 100644 --- a/test/usb_pd_int.c +++ b/test/usb_pd_int.c @@ -92,7 +92,7 @@ void before_test(void) pd_set_suspend(PORT0, 0); } -void run_test(void) +void run_test(int argc, char **argv) { /* Let tasks settle down */ task_wait_event(MINUTE); diff --git a/test/usb_pe_drp.c b/test/usb_pe_drp.c index 8fe474ce8f..a58009436c 100644 --- a/test/usb_pe_drp.c +++ b/test/usb_pe_drp.c @@ -161,7 +161,7 @@ static int test_vbus_gpio_discharge(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/usb_ppc.c b/test/usb_ppc.c index cf2a971a87..af4555ca8d 100644 --- a/test/usb_ppc.c +++ b/test/usb_ppc.c @@ -173,7 +173,7 @@ static int test_ppc_is_vbus_present(void) -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/usb_prl.c b/test/usb_prl.c index e169fc2f05..3ada5adfdb 100644 --- a/test/usb_prl.c +++ b/test/usb_prl.c @@ -1359,7 +1359,7 @@ void before_test(void) cycle_through_state_machine(PORT0, 10, MSEC); } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/usb_sm_framework_h3.c b/test/usb_sm_framework_h3.c index a87002bedf..ba544a749a 100644 --- a/test/usb_sm_framework_h3.c +++ b/test/usb_sm_framework_h3.c @@ -985,7 +985,7 @@ int test_task(void *u) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); #if defined(TEST_USB_SM_FRAMEWORK_H3) diff --git a/test/usb_typec_ctvpd.c b/test/usb_typec_ctvpd.c index d5cd88cbc8..79d3a90294 100644 --- a/test/usb_typec_ctvpd.c +++ b/test/usb_typec_ctvpd.c @@ -1498,7 +1498,7 @@ static int test_ctvpd_behavior_case6(void) } #endif -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/usb_typec_drp_acc_trysrc.c b/test/usb_typec_drp_acc_trysrc.c index 70cbd11cdb..fc5694307d 100644 --- a/test/usb_typec_drp_acc_trysrc.c +++ b/test/usb_typec_drp_acc_trysrc.c @@ -615,7 +615,7 @@ void before_test(void) mock_tcpc.should_print_call = true; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/utils.c b/test/utils.c index 292b2c84c7..061e10b87b 100644 --- a/test/utils.c +++ b/test/utils.c @@ -441,7 +441,7 @@ test_static int test_is_aligned(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/utils_str.c b/test/utils_str.c index 4cb6875b5c..2a68f6c35f 100644 --- a/test/utils_str.c +++ b/test/utils_str.c @@ -260,7 +260,7 @@ static int test_snprintf(void) TEST_CHECK(strncmp(buffer, "1234", sizeof(buffer))); } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); diff --git a/test/vboot.c b/test/vboot.c index 77f9c0af9f..7dab08ac05 100644 --- a/test/vboot.c +++ b/test/vboot.c @@ -131,7 +131,7 @@ static int test_vboot(void) return EC_SUCCESS; } -void run_test(void) +void run_test(int argc, char **argv) { test_reset(); -- cgit v1.2.1