From: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> Access to platform data via dev_get_platdata() getter to make code cleaner. Signed-off-by: Andy Shevchenko <andy.shevchenko@xxxxxxxxx> --- drivers/iio/dac/ad5504.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/dac/ad5504.c b/drivers/iio/dac/ad5504.c index e6c5be728bb2..305cd58cd257 100644 --- a/drivers/iio/dac/ad5504.c +++ b/drivers/iio/dac/ad5504.c @@ -270,7 +270,7 @@ static const struct iio_chan_spec ad5504_channels[] = { static int ad5504_probe(struct spi_device *spi) { - struct ad5504_platform_data *pdata = spi->dev.platform_data; + const struct ad5504_platform_data *pdata = dev_get_platdata(&spi->dev); struct iio_dev *indio_dev; struct ad5504_state *st; struct regulator *reg; -- 2.46.0