test: fdt: Add a special case for real boards
The error that this test checks for is only shown on sandbox. For real boards, there is normally no error. Add a special case to handle this. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -160,6 +160,12 @@ static int fdt_test_addr(struct unit_test_state *uts)
|
|||||||
set_working_fdt_addr(0);
|
set_working_fdt_addr(0);
|
||||||
ut_assert_nextline("Working FDT set to 0");
|
ut_assert_nextline("Working FDT set to 0");
|
||||||
ut_asserteq(CMD_RET_FAILURE, run_command("fdt addr", 0));
|
ut_asserteq(CMD_RET_FAILURE, run_command("fdt addr", 0));
|
||||||
|
|
||||||
|
/*
|
||||||
|
* sandbox fails the check for !blob since the 0 pointer is mapped to
|
||||||
|
* memory somewhere other than at 0x0
|
||||||
|
*/
|
||||||
|
if (IS_ENABLED(CONFIG_SANDBOX))
|
||||||
ut_assert_nextline("libfdt fdt_check_header(): FDT_ERR_BADMAGIC");
|
ut_assert_nextline("libfdt fdt_check_header(): FDT_ERR_BADMAGIC");
|
||||||
ut_assertok(ut_check_console_end(uts));
|
ut_assertok(ut_check_console_end(uts));
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user