[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220428193304.016c46a3@jic23-huawei>
Date: Thu, 28 Apr 2022 19:33:04 +0100
From: Jonathan Cameron <jic23@...nel.org>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: linux-iio@...r.kernel.org,
linux-stm32@...md-mailman.stormreply.com,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
Lars-Peter Clausen <lars@...afoo.de>,
Maxime Coquelin <mcoquelin.stm32@...il.com>,
Alexandre Torgue <alexandre.torgue@...s.st.com>,
Fabrice Gasnier <fabrice.gasnier@...s.st.com>
Subject: Re: [PATCH v1 1/1] iio: trigger: stm32-lptimer-trigger: Make use of
device properties
On Wed, 13 Apr 2022 21:56:56 +0300
Andy Shevchenko <andriy.shevchenko@...ux.intel.com> wrote:
> Convert the module to be property provider agnostic and allow
> it to be used on non-OF platforms.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
MAINTAINERS entry for this one uses extensive wild cards so may
escape scripts...
+CC Fabrice.
> ---
> drivers/iio/trigger/stm32-lptimer-trigger.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/iio/trigger/stm32-lptimer-trigger.c b/drivers/iio/trigger/stm32-lptimer-trigger.c
> index 98cdc7e47f3d..af46c10cea92 100644
> --- a/drivers/iio/trigger/stm32-lptimer-trigger.c
> +++ b/drivers/iio/trigger/stm32-lptimer-trigger.c
> @@ -13,6 +13,7 @@
> #include <linux/mfd/stm32-lptimer.h>
> #include <linux/module.h>
> #include <linux/platform_device.h>
> +#include <linux/property.h>
>
> /* List Low-Power Timer triggers */
> static const char * const stm32_lptim_triggers[] = {
> @@ -77,7 +78,7 @@ static int stm32_lptim_trigger_probe(struct platform_device *pdev)
> if (!priv)
> return -ENOMEM;
>
> - if (of_property_read_u32(pdev->dev.of_node, "reg", &index))
> + if (device_property_read_u32(&pdev->dev, "reg", &index))
> return -EINVAL;
>
> if (index >= ARRAY_SIZE(stm32_lptim_triggers))
Powered by blists - more mailing lists