* [PATCH] i2c: mux: remove incorrect of_match_ptr annotations
@ 2025-02-25 16:36 Arnd Bergmann
2025-02-25 16:39 ` Hennerich, Michael
2025-02-26 22:05 ` Andi Shyti
0 siblings, 2 replies; 3+ messages in thread
From: Arnd Bergmann @ 2025-02-25 16:36 UTC (permalink / raw)
To: Michael Hennerich, Peter Rosin
Cc: Arnd Bergmann, Rob Herring (Arm), Heiner Kallweit,
Thomas Zimmermann, Laurent Pinchart, Uwe Kleine-König,
Andi Shyti, linux-i2c, linux-kernel
From: Arnd Bergmann <arnd@arndb.de>
Building with W=1 shows a warning about ltc4306_of_match and
i2c_mux_reg_of_match being unused when CONFIG_OF is disabled:
drivers/i2c/muxes/i2c-mux-ltc4306.c:200:34: error: unused variable 'ltc4306_of_match' [-Werror,-Wunused-const-variable]
drivers/i2c/muxes/i2c-mux-reg.c:242:34: error: unused variable 'i2c_mux_reg_of_match' [-Werror,-Wunused-const-variable]
Acked-by: Peter Rosin <peda@axentia.se>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/i2c/muxes/i2c-mux-ltc4306.c | 2 +-
drivers/i2c/muxes/i2c-mux-reg.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/i2c/muxes/i2c-mux-ltc4306.c b/drivers/i2c/muxes/i2c-mux-ltc4306.c
index 19a7c370946d..8a87f19bf5d5 100644
--- a/drivers/i2c/muxes/i2c-mux-ltc4306.c
+++ b/drivers/i2c/muxes/i2c-mux-ltc4306.c
@@ -303,7 +303,7 @@ static void ltc4306_remove(struct i2c_client *client)
static struct i2c_driver ltc4306_driver = {
.driver = {
.name = "ltc4306",
- .of_match_table = of_match_ptr(ltc4306_of_match),
+ .of_match_table = ltc4306_of_match,
},
.probe = ltc4306_probe,
.remove = ltc4306_remove,
diff --git a/drivers/i2c/muxes/i2c-mux-reg.c b/drivers/i2c/muxes/i2c-mux-reg.c
index dfa472d514cc..1e566ea92bc9 100644
--- a/drivers/i2c/muxes/i2c-mux-reg.c
+++ b/drivers/i2c/muxes/i2c-mux-reg.c
@@ -250,7 +250,7 @@ static struct platform_driver i2c_mux_reg_driver = {
.remove = i2c_mux_reg_remove,
.driver = {
.name = "i2c-mux-reg",
- .of_match_table = of_match_ptr(i2c_mux_reg_of_match),
+ .of_match_table = i2c_mux_reg_of_match,
},
};
--
2.39.5
^ permalink raw reply related [flat|nested] 3+ messages in thread* RE: [PATCH] i2c: mux: remove incorrect of_match_ptr annotations
2025-02-25 16:36 [PATCH] i2c: mux: remove incorrect of_match_ptr annotations Arnd Bergmann
@ 2025-02-25 16:39 ` Hennerich, Michael
2025-02-26 22:05 ` Andi Shyti
1 sibling, 0 replies; 3+ messages in thread
From: Hennerich, Michael @ 2025-02-25 16:39 UTC (permalink / raw)
To: Arnd Bergmann, Peter Rosin
Cc: Arnd Bergmann, Rob Herring (Arm), Heiner Kallweit,
Thomas Zimmermann, Laurent Pinchart, Uwe Kleine König,
Andi Shyti, linux-i2c@vger.kernel.org,
linux-kernel@vger.kernel.org
> -----Original Message-----
> From: Arnd Bergmann <arnd@kernel.org>
> Sent: Tuesday, February 25, 2025 5:37 PM
> To: Hennerich, Michael <Michael.Hennerich@analog.com>; Peter Rosin
> <peda@axentia.se>
> Cc: Arnd Bergmann <arnd@arndb.de>; Rob Herring (Arm) <robh@kernel.org>;
> Heiner Kallweit <hkallweit1@gmail.com>; Thomas Zimmermann
> <tzimmermann@suse.de>; Laurent Pinchart
> <laurent.pinchart+renesas@ideasonboard.com>; Uwe Kleine König <u.kleine-
> koenig@baylibre.com>; Andi Shyti <andi.shyti@kernel.org>; linux-
> i2c@vger.kernel.org; linux-kernel@vger.kernel.org
> Subject: [PATCH] i2c: mux: remove incorrect of_match_ptr annotations
>
> From: Arnd Bergmann <arnd@arndb.de>
>
> Building with W=1 shows a warning about ltc4306_of_match and
> i2c_mux_reg_of_match being unused when CONFIG_OF is disabled:
>
> drivers/i2c/muxes/i2c-mux-ltc4306.c:200:34: error: unused variable
> 'ltc4306_of_match' [-Werror,-Wunused-const-variable]
> drivers/i2c/muxes/i2c-mux-reg.c:242:34: error: unused variable
> 'i2c_mux_reg_of_match' [-Werror,-Wunused-const-variable]
>
> Acked-by: Peter Rosin <peda@axentia.se>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
> ---
> drivers/i2c/muxes/i2c-mux-ltc4306.c | 2 +-
> drivers/i2c/muxes/i2c-mux-reg.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/i2c/muxes/i2c-mux-ltc4306.c b/drivers/i2c/muxes/i2c-mux-
> ltc4306.c
> index 19a7c370946d..8a87f19bf5d5 100644
> --- a/drivers/i2c/muxes/i2c-mux-ltc4306.c
> +++ b/drivers/i2c/muxes/i2c-mux-ltc4306.c
> @@ -303,7 +303,7 @@ static void ltc4306_remove(struct i2c_client *client)
> static struct i2c_driver ltc4306_driver = {
> .driver = {
> .name = "ltc4306",
> - .of_match_table = of_match_ptr(ltc4306_of_match),
> + .of_match_table = ltc4306_of_match,
> },
> .probe = ltc4306_probe,
> .remove = ltc4306_remove,
> diff --git a/drivers/i2c/muxes/i2c-mux-reg.c b/drivers/i2c/muxes/i2c-mux-reg.c
> index dfa472d514cc..1e566ea92bc9 100644
> --- a/drivers/i2c/muxes/i2c-mux-reg.c
> +++ b/drivers/i2c/muxes/i2c-mux-reg.c
> @@ -250,7 +250,7 @@ static struct platform_driver i2c_mux_reg_driver = {
> .remove = i2c_mux_reg_remove,
> .driver = {
> .name = "i2c-mux-reg",
> - .of_match_table = of_match_ptr(i2c_mux_reg_of_match),
> + .of_match_table = i2c_mux_reg_of_match,
> },
> };
>
> --
> 2.39.5
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] i2c: mux: remove incorrect of_match_ptr annotations
2025-02-25 16:36 [PATCH] i2c: mux: remove incorrect of_match_ptr annotations Arnd Bergmann
2025-02-25 16:39 ` Hennerich, Michael
@ 2025-02-26 22:05 ` Andi Shyti
1 sibling, 0 replies; 3+ messages in thread
From: Andi Shyti @ 2025-02-26 22:05 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Michael Hennerich, Peter Rosin, Arnd Bergmann, Rob Herring (Arm),
Heiner Kallweit, Thomas Zimmermann, Laurent Pinchart,
Uwe Kleine-König, linux-i2c, linux-kernel
Hi Arnd,
On Tue, Feb 25, 2025 at 05:36:56PM +0100, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> Building with W=1 shows a warning about ltc4306_of_match and
> i2c_mux_reg_of_match being unused when CONFIG_OF is disabled:
>
> drivers/i2c/muxes/i2c-mux-ltc4306.c:200:34: error: unused variable 'ltc4306_of_match' [-Werror,-Wunused-const-variable]
> drivers/i2c/muxes/i2c-mux-reg.c:242:34: error: unused variable 'i2c_mux_reg_of_match' [-Werror,-Wunused-const-variable]
>
> Acked-by: Peter Rosin <peda@axentia.se>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
merged to i2c/i2c-host.
Thanks,
Andi
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-02-26 22:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-25 16:36 [PATCH] i2c: mux: remove incorrect of_match_ptr annotations Arnd Bergmann
2025-02-25 16:39 ` Hennerich, Michael
2025-02-26 22:05 ` Andi Shyti
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox