aboutsummaryrefslogtreecommitdiff
path: root/drivers/spi
diff options
context:
space:
mode:
authorSimon Glass2020-12-19 10:40:14 -0700
committerSimon Glass2021-01-05 12:24:41 -0700
commitf10643cf8a4ca006d1ad194e930cd292fd869d17 (patch)
tree66cd9383fc5dbd8e02f999d1db5562995f441b21 /drivers/spi
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 'drivers/spi')
-rw-r--r--drivers/spi/fsl_dspi.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/spi/fsl_dspi.c b/drivers/spi/fsl_dspi.c
index b8c0216b39d..c17a5522bcc 100644
--- a/drivers/spi/fsl_dspi.c
+++ b/drivers/spi/fsl_dspi.c
@@ -460,8 +460,10 @@ static int fsl_dspi_child_pre_probe(struct udevice *dev)
return -EINVAL;
}
- ofnode_read_u32(dev->node, "fsl,spi-cs-sck-delay", &cs_sck_delay);
- ofnode_read_u32(dev->node, "fsl,spi-sck-cs-delay", &sck_cs_delay);
+ ofnode_read_u32(dev_ofnode(dev), "fsl,spi-cs-sck-delay",
+ &cs_sck_delay);
+ ofnode_read_u32(dev_ofnode(dev), "fsl,spi-sck-cs-delay",
+ &sck_cs_delay);
/* Set PCS to SCK delay scale values */
ns_delay_scale(&pcssck, &cssck, cs_sck_delay, priv->bus_clk);