aboutsummaryrefslogtreecommitdiffstats
path: root/test/test-main.c
diff options
context:
space:
mode:
authorSean Anderson <sean.anderson@seco.com>2023-09-29 12:06:54 -0400
committerTom Rini <trini@konsulko.com>2023-10-09 15:24:31 -0400
commit3f876cb7c57511174d1b6a3e089443ccbaf236ec (patch)
tree422a1ac1688b75a6c4edcbaa2024346acbaddfb8 /test/test-main.c
parente483a7c8fff23d5aab27937f6054c883f99c8680 (diff)
downloadu-boot-3f876cb7c57511174d1b6a3e089443ccbaf236ec.tar.gz
test: Fix SPL tests not being runWIP/2023-10-09-assorted-fixes
SPL doesn't have OF_LIVE enabled, so we can only run tests with a flat tree. Don't skip them even if they don't use the devicetree. Fixes: 6ec5178c0ef ("test: Skip flat-tree tests if devicetree is not used") Signed-off-by: Sean Anderson <sean.anderson@seco.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'test/test-main.c')
-rw-r--r--test/test-main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/test-main.c b/test/test-main.c
index 778bf0a18a0..edb20bc4b9c 100644
--- a/test/test-main.c
+++ b/test/test-main.c
@@ -476,7 +476,8 @@ static int ut_run_test_live_flat(struct unit_test_state *uts,
* (for sandbox we handle this by copying the tree, but not for other
* boards)
*/
- if ((test->flags & UT_TESTF_SCAN_FDT) &&
+ if ((!CONFIG_IS_ENABLED(OF_LIVE) ||
+ (test->flags & UT_TESTF_SCAN_FDT)) &&
!(test->flags & UT_TESTF_LIVE_TREE) &&
(CONFIG_IS_ENABLED(OFNODE_MULTI_TREE) ||
!(test->flags & UT_TESTF_OTHER_FDT)) &&