]> git.dujemihanovic.xyz Git - u-boot.git/commit
dm: core: Fix devfdt_get_addr_ptr return value
authorOvidiu Panait <ovidiu.panait@windriver.com>
Mon, 3 Aug 2020 19:17:35 +0000 (22:17 +0300)
committerSimon Glass <sjg@chromium.org>
Sat, 22 Aug 2020 13:59:14 +0000 (07:59 -0600)
commit3fe69d3764c3ca6f304c51faa6aae7a84f1fa56c
tree4c61149fa9ef7f082f02ef176363e99cb2301ec5
parent02291d83fdaaf30e355eb7cef05581ec086962bd
dm: core: Fix devfdt_get_addr_ptr return value

According to the description of devfdt_get_addr_ptr, this function should
return NULL on failure, but currently it returns (void *)FDT_ADDR_T_NONE.

Fix this by making devfdt_get_addr_ptr return NULL on failure, as
described in the function comments. Also, update the drivers currently
checking (void *)FDT_ADDR_T_NONE to check for NULL.

Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
drivers/clk/aspeed/clk_ast2500.c
drivers/core/fdtaddr.c
drivers/i2c/ast_i2c.c
drivers/pinctrl/mvebu/pinctrl-mvebu.c
drivers/timer/ast_timer.c
drivers/watchdog/ast_wdt.c
include/dm/read.h