diff mbox series

i2c: qup: use generic device property accessors

Message ID 20241008160947.81045-1-brgl@bgdev.pl
State New
Headers show
Series i2c: qup: use generic device property accessors | expand

Commit Message

Bartosz Golaszewski Oct. 8, 2024, 4:09 p.m. UTC
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

There's no reason for this driver to use OF-specific property helpers.
Drop the last one in favor of the generic variant and no longer include
of.h.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 drivers/i2c/busses/i2c-qup.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Bartosz Golaszewski Oct. 22, 2024, 11:43 a.m. UTC | #1
On Tue, Oct 8, 2024 at 6:09 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> There's no reason for this driver to use OF-specific property helpers.
> Drop the last one in favor of the generic variant and no longer include
> of.h.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> ---

It's been two weeks. Ping?

Bart
Neil Armstrong Oct. 22, 2024, 12:05 p.m. UTC | #2
On 08/10/2024 18:09, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> 
> There's no reason for this driver to use OF-specific property helpers.
> Drop the last one in favor of the generic variant and no longer include
> of.h.
> 
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> ---
>   drivers/i2c/busses/i2c-qup.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/i2c/busses/i2c-qup.c b/drivers/i2c/busses/i2c-qup.c
> index 86ec391616b0..da20b4487c9a 100644
> --- a/drivers/i2c/busses/i2c-qup.c
> +++ b/drivers/i2c/busses/i2c-qup.c
> @@ -17,9 +17,9 @@
>   #include <linux/interrupt.h>
>   #include <linux/io.h>
>   #include <linux/module.h>
> -#include <linux/of.h>
>   #include <linux/platform_device.h>
>   #include <linux/pm_runtime.h>
> +#include <linux/property.h>
>   #include <linux/scatterlist.h>
>   
>   /* QUP Registers */
> @@ -1683,7 +1683,7 @@ static int qup_i2c_probe(struct platform_device *pdev)
>   		}
>   	}
>   
> -	if (of_device_is_compatible(pdev->dev.of_node, "qcom,i2c-qup-v1.1.1")) {
> +	if (device_is_compatible(&pdev->dev, "qcom,i2c-qup-v1.1.1")) {
>   		qup->adap.algo = &qup_i2c_algo;
>   		qup->adap.quirks = &qup_i2c_quirks;
>   		is_qup_v1 = true;

LGTM

Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Bartosz Golaszewski Oct. 25, 2024, 8:04 a.m. UTC | #3
On Tue, Oct 22, 2024 at 2:05 PM <neil.armstrong@linaro.org> wrote:
>
> On 08/10/2024 18:09, Bartosz Golaszewski wrote:
> > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >
> > There's no reason for this driver to use OF-specific property helpers.
> > Drop the last one in favor of the generic variant and no longer include
> > of.h.
> >
> > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> LGTM
>
> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

Andi, can you pick this up, please?

Bart
Bartosz Golaszewski Nov. 1, 2024, 2:20 p.m. UTC | #4
On Fri, Oct 25, 2024 at 10:04 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>
> On Tue, Oct 22, 2024 at 2:05 PM <neil.armstrong@linaro.org> wrote:
> >
> > On 08/10/2024 18:09, Bartosz Golaszewski wrote:
> > > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> > >
> > > There's no reason for this driver to use OF-specific property helpers.
> > > Drop the last one in favor of the generic variant and no longer include
> > > of.h.
> > >
> > > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >
> > LGTM
> >
> > Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
>
> Andi, can you pick this up, please?
>
> Bart

Any reason why this simple change cannot be picked up?

Bartosz
diff mbox series

Patch

diff --git a/drivers/i2c/busses/i2c-qup.c b/drivers/i2c/busses/i2c-qup.c
index 86ec391616b0..da20b4487c9a 100644
--- a/drivers/i2c/busses/i2c-qup.c
+++ b/drivers/i2c/busses/i2c-qup.c
@@ -17,9 +17,9 @@ 
 #include <linux/interrupt.h>
 #include <linux/io.h>
 #include <linux/module.h>
-#include <linux/of.h>
 #include <linux/platform_device.h>
 #include <linux/pm_runtime.h>
+#include <linux/property.h>
 #include <linux/scatterlist.h>
 
 /* QUP Registers */
@@ -1683,7 +1683,7 @@  static int qup_i2c_probe(struct platform_device *pdev)
 		}
 	}
 
-	if (of_device_is_compatible(pdev->dev.of_node, "qcom,i2c-qup-v1.1.1")) {
+	if (device_is_compatible(&pdev->dev, "qcom,i2c-qup-v1.1.1")) {
 		qup->adap.algo = &qup_i2c_algo;
 		qup->adap.quirks = &qup_i2c_quirks;
 		is_qup_v1 = true;