mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-18 21:21:37 +00:00
fdt: fix dev_get_addr_name node offset
Use the device's own DT offset, not the device's parent's.
Fixes: 43c4d44e33
("fdt: implement dev_get_addr_name()")
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
54693cbdca
commit
35732098db
1 changed files with 2 additions and 2 deletions
|
@ -657,8 +657,8 @@ fdt_addr_t dev_get_addr_name(struct udevice *dev, const char *name)
|
|||
#if CONFIG_IS_ENABLED(OF_CONTROL)
|
||||
int index;
|
||||
|
||||
index = fdt_find_string(gd->fdt_blob, dev->parent->of_offset,
|
||||
"reg-names", name);
|
||||
index = fdt_find_string(gd->fdt_blob, dev->of_offset, "reg-names",
|
||||
name);
|
||||
if (index < 0)
|
||||
return index;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue