summaryrefslogtreecommitdiff
path: root/include/dm/read.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-12-19 10:40:14 -0700
committerSimon Glass <sjg@chromium.org>2021-01-05 12:24:41 -0700
commitf10643cf8a4ca006d1ad194e930cd292fd869d17 (patch)
tree66cd9383fc5dbd8e02f999d1db5562995f441b21 /include/dm/read.h
parent7d14ee443ca674314e0fe5c3e25f48e52a8fd5ee (diff)
dm: core: Access device ofnode through functions
At present ofnode is present in the device even if it is never used. With of-platdata this field is not used, so can be removed. In preparation for this, change the access to go through inline functions. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/dm/read.h')
-rw-r--r--include/dm/read.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/dm/read.h b/include/dm/read.h
index d5cdd87911d..fc987f77598 100644
--- a/include/dm/read.h
+++ b/include/dm/read.h
@@ -21,7 +21,7 @@ struct resource;
#if CONFIG_IS_ENABLED(OF_LIVE)
static inline const struct device_node *dev_np(const struct udevice *dev)
{
- return ofnode_to_np(dev->node);
+ return ofnode_to_np(dev_ofnode(dev));
}
#else
static inline const struct device_node *dev_np(const struct udevice *dev)