dm: Rename dev_get_parentdata() to dev_get_parent_priv()
The current name is inconsistent with other driver model data access
functions. Rename it and fix up all users.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Joe Hershberger <joe.hershberger@ni.com>
diff --git a/drivers/spi/fsl_qspi.c b/drivers/spi/fsl_qspi.c
index 868df5f..02b557f 100644
--- a/drivers/spi/fsl_qspi.c
+++ b/drivers/spi/fsl_qspi.c
@@ -913,7 +913,7 @@
#else
static int fsl_qspi_child_pre_probe(struct udevice *dev)
{
- struct spi_slave *slave = dev_get_parentdata(dev);
+ struct spi_slave *slave = dev_get_parent_priv(dev);
slave->max_write_size = TX_BUFFER_SIZE;
diff --git a/drivers/spi/ich.c b/drivers/spi/ich.c
index be4c0a3..b974e84 100644
--- a/drivers/spi/ich.c
+++ b/drivers/spi/ich.c
@@ -740,7 +740,7 @@
struct udevice *bus = dev_get_parent(dev);
struct ich_spi_platdata *plat = dev_get_platdata(bus);
struct ich_spi_priv *priv = dev_get_priv(bus);
- struct spi_slave *slave = dev_get_parentdata(dev);
+ struct spi_slave *slave = dev_get_parent_priv(dev);
/*
* Yes this controller can only write a small number of bytes at
diff --git a/drivers/spi/soft_spi.c b/drivers/spi/soft_spi.c
index 6ae45f5..aa4abcc 100644
--- a/drivers/spi/soft_spi.c
+++ b/drivers/spi/soft_spi.c
@@ -200,7 +200,7 @@
static int soft_spi_probe(struct udevice *dev)
{
- struct spi_slave *slave = dev_get_parentdata(dev);
+ struct spi_slave *slave = dev_get_parent_priv(dev);
struct soft_spi_platdata *plat = dev->platdata;
int cs_flags, clk_flags;
diff --git a/drivers/spi/spi-uclass.c b/drivers/spi/spi-uclass.c
index d666272..58388ef 100644
--- a/drivers/spi/spi-uclass.c
+++ b/drivers/spi/spi-uclass.c
@@ -124,7 +124,7 @@
static int spi_child_pre_probe(struct udevice *dev)
{
struct dm_spi_slave_platdata *plat = dev_get_parent_platdata(dev);
- struct spi_slave *slave = dev_get_parentdata(dev);
+ struct spi_slave *slave = dev_get_parent_priv(dev);
/*
* This is needed because we pass struct spi_slave around the place
@@ -282,7 +282,7 @@
ret = device_probe(dev);
if (ret)
goto err;
- slave = dev_get_parentdata(dev);
+ slave = dev_get_parent_priv(dev);
slave->dev = dev;
}
@@ -291,7 +291,7 @@
goto err;
*busp = bus;
- *devp = dev_get_parentdata(dev);
+ *devp = dev_get_parent_priv(dev);
debug("%s: bus=%p, slave=%p\n", __func__, bus, *devp);
return 0;
@@ -320,7 +320,7 @@
ret = device_get_child_by_of_offset(bus, node, &dev);
if (ret)
return NULL;
- return dev_get_parentdata(dev);
+ return dev_get_parent_priv(dev);
}
/* Compatibility function - to be removed */