]> Git Repo - J-u-boot.git/blobdiff - test/dm/fwu_mdata.c
Merge tag 'v2023.10-rc4' into next
[J-u-boot.git] / test / dm / fwu_mdata.c
index 8b5c83ef4e2d8ff366e4476bc8d2f66dd60e9eae..52018f610fe4764f2655f314069578ebd32489b5 100644 (file)
@@ -93,6 +93,12 @@ static int dm_test_fwu_mdata_read(struct unit_test_state *uts)
        struct udevice *dev;
        struct fwu_mdata mdata = { 0 };
 
+       /*
+        * Trigger lib/fwu_updates/fwu.c fwu_boottime_checks()
+        * to populate g_dev global pointer in that library.
+        */
+       event_notify_null(EVT_MAIN_LOOP);
+
        ut_assertok(uclass_first_device_err(UCLASS_FWU_MDATA, &dev));
        ut_assertok(setup_blk_device(uts));
        ut_assertok(populate_mmc_disk_image(uts));
@@ -112,6 +118,12 @@ static int dm_test_fwu_mdata_write(struct unit_test_state *uts)
        struct udevice *dev;
        struct fwu_mdata mdata = { 0 };
 
+       /*
+        * Trigger lib/fwu_updates/fwu.c fwu_boottime_checks()
+        * to populate g_dev global pointer in that library.
+        */
+       event_notify_null(EVT_MAIN_LOOP);
+
        ut_assertok(setup_blk_device(uts));
        ut_assertok(populate_mmc_disk_image(uts));
        ut_assertok(write_mmc_blk_device(uts));
This page took 0.025024 seconds and 4 git commands to generate.