* [PATCH v1 1/1] iio: proximity: ping: Replace OF specific code by device_get_match_data()
@ 2022-04-13 18:34 Andy Shevchenko
2022-04-16 10:58 ` Jonathan Cameron
0 siblings, 1 reply; 2+ messages in thread
From: Andy Shevchenko @ 2022-04-13 18:34 UTC (permalink / raw)
To: linux-iio, linux-kernel
Cc: Andreas Klinger, Jonathan Cameron, Lars-Peter Clausen, Andy Shevchenko
Instead of calling the OF specific API, use device_get_match_data().
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/iio/proximity/ping.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/iio/proximity/ping.c b/drivers/iio/proximity/ping.c
index 24a97d41e115..d56e037378de 100644
--- a/drivers/iio/proximity/ping.c
+++ b/drivers/iio/proximity/ping.c
@@ -29,9 +29,8 @@
#include <linux/err.h>
#include <linux/gpio/consumer.h>
#include <linux/kernel.h>
+#include <linux/mod_devicetable.h>
#include <linux/module.h>
-#include <linux/of.h>
-#include <linux/of_device.h>
#include <linux/platform_device.h>
#include <linux/property.h>
#include <linux/sched.h>
@@ -288,7 +287,7 @@ static int ping_probe(struct platform_device *pdev)
data = iio_priv(indio_dev);
data->dev = dev;
- data->cfg = of_device_get_match_data(dev);
+ data->cfg = device_get_match_data(dev);
mutex_init(&data->lock);
init_completion(&data->rising);
--
2.35.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v1 1/1] iio: proximity: ping: Replace OF specific code by device_get_match_data()
2022-04-13 18:34 [PATCH v1 1/1] iio: proximity: ping: Replace OF specific code by device_get_match_data() Andy Shevchenko
@ 2022-04-16 10:58 ` Jonathan Cameron
0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Cameron @ 2022-04-16 10:58 UTC (permalink / raw)
To: Andy Shevchenko
Cc: linux-iio, linux-kernel, Andreas Klinger, Lars-Peter Clausen
On Wed, 13 Apr 2022 21:34:21 +0300
Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:
> Instead of calling the OF specific API, use device_get_match_data().
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Applied.
Thanks,
Jonathan
> ---
> drivers/iio/proximity/ping.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/iio/proximity/ping.c b/drivers/iio/proximity/ping.c
> index 24a97d41e115..d56e037378de 100644
> --- a/drivers/iio/proximity/ping.c
> +++ b/drivers/iio/proximity/ping.c
> @@ -29,9 +29,8 @@
> #include <linux/err.h>
> #include <linux/gpio/consumer.h>
> #include <linux/kernel.h>
> +#include <linux/mod_devicetable.h>
> #include <linux/module.h>
> -#include <linux/of.h>
> -#include <linux/of_device.h>
> #include <linux/platform_device.h>
> #include <linux/property.h>
> #include <linux/sched.h>
> @@ -288,7 +287,7 @@ static int ping_probe(struct platform_device *pdev)
>
> data = iio_priv(indio_dev);
> data->dev = dev;
> - data->cfg = of_device_get_match_data(dev);
> + data->cfg = device_get_match_data(dev);
>
> mutex_init(&data->lock);
> init_completion(&data->rising);
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-04-16 10:50 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-13 18:34 [PATCH v1 1/1] iio: proximity: ping: Replace OF specific code by device_get_match_data() Andy Shevchenko
2022-04-16 10:58 ` Jonathan Cameron
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.