This was a workaround for a rare situation. Now that it will be more
common and we have a proper fix, drop the flag. We can run both types of
tests in the same sandbox executable, even if the flat device tree is
modified.

Signed-off-by: Simon Glass <s...@chromium.org>
---

 include/test/test.h | 2 --
 test/dm/ofnode.c    | 8 +++-----
 test/test-main.c    | 3 +--
 3 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/include/test/test.h b/include/test/test.h
index ada0bb0a25d..c028bbb8c89 100644
--- a/include/test/test.h
+++ b/include/test/test.h
@@ -52,8 +52,6 @@ enum {
        UT_TESTF_CONSOLE_REC    = BIT(5),       /* needs console recording */
        /* do extra driver model init and uninit */
        UT_TESTF_DM             = BIT(6),
-       /* live or flat device tree, but not both in the same executable */
-       UT_TESTF_LIVE_OR_FLAT   = BIT(4),
 };
 
 /**
diff --git a/test/dm/ofnode.c b/test/dm/ofnode.c
index 76346e37d1f..a36fd104048 100644
--- a/test/dm/ofnode.c
+++ b/test/dm/ofnode.c
@@ -584,7 +584,7 @@ static int dm_test_ofnode_livetree_writing(struct 
unit_test_state *uts)
        return 0;
 }
 DM_TEST(dm_test_ofnode_livetree_writing,
-       UT_TESTF_SCAN_PDATA | UT_TESTF_SCAN_FDT | UT_TESTF_LIVE_OR_FLAT);
+       UT_TESTF_SCAN_PDATA | UT_TESTF_SCAN_FDT);
 
 static int dm_test_ofnode_u32(struct unit_test_state *uts)
 {
@@ -599,8 +599,7 @@ static int dm_test_ofnode_u32(struct unit_test_state *uts)
 
        return 0;
 }
-DM_TEST(dm_test_ofnode_u32,
-       UT_TESTF_SCAN_PDATA | UT_TESTF_SCAN_FDT | UT_TESTF_LIVE_OR_FLAT);
+DM_TEST(dm_test_ofnode_u32, UT_TESTF_SCAN_PDATA | UT_TESTF_SCAN_FDT);
 
 static int dm_test_ofnode_add_subnode(struct unit_test_state *uts)
 {
@@ -619,5 +618,4 @@ static int dm_test_ofnode_add_subnode(struct 
unit_test_state *uts)
 
        return 0;
 }
-DM_TEST(dm_test_ofnode_add_subnode,
-       UT_TESTF_SCAN_PDATA | UT_TESTF_SCAN_FDT | UT_TESTF_LIVE_OR_FLAT);
+DM_TEST(dm_test_ofnode_add_subnode, UT_TESTF_SCAN_PDATA | UT_TESTF_SCAN_FDT);
diff --git a/test/test-main.c b/test/test-main.c
index d285872d111..97ba25d927c 100644
--- a/test/test-main.c
+++ b/test/test-main.c
@@ -410,8 +410,7 @@ static int ut_run_test_live_flat(struct unit_test_state 
*uts,
        /* Run with the live tree if possible */
        runs = 0;
        if (CONFIG_IS_ENABLED(OF_LIVE)) {
-               if (!(test->flags &
-                   (UT_TESTF_FLAT_TREE | UT_TESTF_LIVE_OR_FLAT))) {
+               if (!(test->flags & UT_TESTF_FLAT_TREE)) {
                        uts->of_live = true;
                        ut_assertok(ut_run_test(uts, test, test->name));
                        runs++;
-- 
2.37.2.672.g94769d06f0-goog

Reply via email to