From eaac4fb296b1899369e49d941f2c0d346c7f5c7a Mon Sep 17 00:00:00 2001 From: Alexander Graf Date: Wed, 26 Sep 2018 14:07:41 +0200 Subject: sandbox: Fix set_working_fdt_addr users When running sandbox with the new pointer sanitization we just recently introduced, we're running into a case with FIT images where we end up interpreting pointers as addresses. What happened is that most callers of set_working_fdt_addr() simply convert pointers into addresses without taking into account that they might be 2 separate address spaces. Fix the callers up to map their pointers into addresses. This makes sandbox tests pass for me again. Signed-off-by: Alexander Graf --- common/bootm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'common/bootm.c') diff --git a/common/bootm.c b/common/bootm.c index e517d9f118..8bf84ebcb7 100644 --- a/common/bootm.c +++ b/common/bootm.c @@ -262,7 +262,7 @@ int bootm_find_images(int flag, int argc, char * const argv[]) puts("Could not find a valid device tree\n"); return 1; } - set_working_fdt_addr((ulong)images.ft_addr); + set_working_fdt_addr(map_to_sysmem(images.ft_addr)); #endif #if IMAGE_ENABLE_FIT -- cgit v1.2.3