[PATCH v1 12/22] iio: frequency: adf4350: Get platform data via dev_get_platdata()
From: Andy Shevchenko
Date: Mon Sep 02 2024 - 18:32:30 EST
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/frequency/adf4350.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/iio/frequency/adf4350.c b/drivers/iio/frequency/adf4350.c
index e13e64a5164c..61828e61e275 100644
--- a/drivers/iio/frequency/adf4350.c
+++ b/drivers/iio/frequency/adf4350.c
@@ -603,7 +603,7 @@ static int adf4350_probe(struct spi_device *spi)
if (pdata == NULL)
return -EINVAL;
} else {
- pdata = spi->dev.platform_data;
+ pdata = dev_get_platdata(&spi->dev);
}
if (!pdata) {
--
2.46.0