phys_addr_t can be used unsigned long long type with CONFIG_PHYS_64BIT.
But hextoul() is always returning to unsigned long. It can be assigned
to unexpected value. To avoid wrong behavior, change from hextoul() to
simple_strtoull().
Fixes: a4df06e41fa2 ("boot: fdt: Change type of env_get_bootm_low() to phys_addr_t")
Change-Id: Ia7c25f8fbc8e31bdd7abd1f9cf599c4c873dd769
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
/* a value of "no" or a similar string will act like 0,
* turning the "load high" feature off. This is intentional.
*/
- initrd_high = hextoul(s, NULL);
+ initrd_high = simple_strtoull(s, NULL, 16);
if (initrd_high == ~0)
initrd_copy_to_ram = 0;
} else {