diff options
| author | Rick Chen <[email protected]> | 2020-07-17 16:24:44 +0800 |
|---|---|---|
| committer | Andes <[email protected]> | 2020-07-24 14:56:24 +0800 |
| commit | e8fa43182a487e7542c49408eb2499cc4c0ed53c (patch) | |
| tree | 1b6f2b817d73b94611a3295524cb71733f541cf7 | |
| parent | e491e15a3f4bdf7e22d5e448c3f0cfb733a8dd8b (diff) | |
riscv: ae350: Use fdtdec_get_addr_size_auto_noparent to parse smc reg
Use fdtdec_get_addr_size_auto_noparent to read the "reg" property
instead of fdtdec_get_addr. This will increase the compatibility
of dtb parsing.
Signed-off-by: Rick Chen <[email protected]>
Acked-by: Leo Liang <[email protected]>
Reviewed-by: Bin Meng <[email protected]>
Tested-by: Leo Liang <[email protected]>
| -rw-r--r-- | board/AndesTech/ax25-ae350/ax25-ae350.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/board/AndesTech/ax25-ae350/ax25-ae350.c b/board/AndesTech/ax25-ae350/ax25-ae350.c index add0d56ef2d..59a43e4dcc4 100644 --- a/board/AndesTech/ax25-ae350/ax25-ae350.c +++ b/board/AndesTech/ax25-ae350/ax25-ae350.c @@ -71,7 +71,8 @@ int smc_init(void) if (node < 0) return -FDT_ERR_NOTFOUND; - addr = fdtdec_get_addr(blob, node, "reg"); + addr = fdtdec_get_addr_size_auto_noparent(blob, node, + "reg", 0, NULL, false); if (addr == FDT_ADDR_T_NONE) return -EINVAL; |
