From: Nizam Haider Date: Mon, 23 Nov 2015 18:07:16 +0000 (+0530) Subject: Staging: iio: frequency: use dev_get_platdata() X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=7221819ac48195ea9f1e179c3f812939319d9e7b;p=linux-beck.git Staging: iio: frequency: use dev_get_platdata() Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly. Signed-off-by: Nizam Haider Signed-off-by: Jonathan Cameron --- diff --git a/drivers/staging/iio/frequency/ad9832.c b/drivers/staging/iio/frequency/ad9832.c index 2b65faa6296a..18b27a1984b2 100644 --- a/drivers/staging/iio/frequency/ad9832.c +++ b/drivers/staging/iio/frequency/ad9832.c @@ -201,7 +201,7 @@ static const struct iio_info ad9832_info = { static int ad9832_probe(struct spi_device *spi) { - struct ad9832_platform_data *pdata = spi->dev.platform_data; + struct ad9832_platform_data *pdata = dev_get_platdata(&spi->dev); struct iio_dev *indio_dev; struct ad9832_state *st; struct regulator *reg; diff --git a/drivers/staging/iio/frequency/ad9834.c b/drivers/staging/iio/frequency/ad9834.c index 6464f2cbe94b..6366216e4f37 100644 --- a/drivers/staging/iio/frequency/ad9834.c +++ b/drivers/staging/iio/frequency/ad9834.c @@ -318,7 +318,7 @@ static const struct iio_info ad9833_info = { static int ad9834_probe(struct spi_device *spi) { - struct ad9834_platform_data *pdata = spi->dev.platform_data; + struct ad9834_platform_data *pdata = dev_get_platdata(&spi->dev); struct ad9834_state *st; struct iio_dev *indio_dev; struct regulator *reg;