diff mbox series

[V3,2/8] clk: imx93: drop of_match_ptr

Message ID 20220830033137.4149542-3-peng.fan@oss.nxp.com (mailing list archive)
State Awaiting Upstream, archived
Headers show
Series clk: imx93: new gate API and composite update | expand

Commit Message

Peng Fan (OSS) Aug. 30, 2022, 3:31 a.m. UTC
From: Peng Fan <peng.fan@nxp.com>

There is build warning when CONFIG_OF is not selected.
>> drivers/clk/imx/clk-imx93.c:324:34: warning: 'imx93_clk_of_match'
>> defined but not used [-Wunused-const-variable=]
     324 | static const struct of_device_id imx93_clk_of_match[] = {
         |                                  ^~~~~~~~~~~~~~~~~~

The driver only support DT table, no sense to use of_match_ptr.

Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
---
 drivers/clk/imx/clk-imx93.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Abel Vesa Sept. 2, 2022, 6:31 p.m. UTC | #1
On 22-08-30 11:31:31, Peng Fan (OSS) wrote:
> From: Peng Fan <peng.fan@nxp.com>
> 
> There is build warning when CONFIG_OF is not selected.
> >> drivers/clk/imx/clk-imx93.c:324:34: warning: 'imx93_clk_of_match'
> >> defined but not used [-Wunused-const-variable=]
>      324 | static const struct of_device_id imx93_clk_of_match[] = {
>          |                                  ^~~~~~~~~~~~~~~~~~
> 
> The driver only support DT table, no sense to use of_match_ptr.
> 
> Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>

Reviewed-by: Abel Vesa <abel.vesa@linaro.org>

Stephen will you pick this patch?

I'll take the rest through my tree.

> ---
>  drivers/clk/imx/clk-imx93.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
> index f5c9fa40491c..dcc41d178238 100644
> --- a/drivers/clk/imx/clk-imx93.c
> +++ b/drivers/clk/imx/clk-imx93.c
> @@ -332,7 +332,7 @@ static struct platform_driver imx93_clk_driver = {
>  	.driver = {
>  		.name = "imx93-ccm",
>  		.suppress_bind_attrs = true,
> -		.of_match_table = of_match_ptr(imx93_clk_of_match),
> +		.of_match_table = imx93_clk_of_match,
>  	},
>  };
>  module_platform_driver(imx93_clk_driver);
> -- 
> 2.37.1
>
Stephen Boyd Sept. 29, 2022, 1:37 a.m. UTC | #2
Quoting Abel Vesa (2022-09-02 11:31:06)
> On 22-08-30 11:31:31, Peng Fan (OSS) wrote:
> > From: Peng Fan <peng.fan@nxp.com>
> > 
> > There is build warning when CONFIG_OF is not selected.
> > >> drivers/clk/imx/clk-imx93.c:324:34: warning: 'imx93_clk_of_match'
> > >> defined but not used [-Wunused-const-variable=]
> >      324 | static const struct of_device_id imx93_clk_of_match[] = {
> >          |                                  ^~~~~~~~~~~~~~~~~~
> > 
> > The driver only support DT table, no sense to use of_match_ptr.
> > 
> > Fixes: 24defbe194b6 ("clk: imx: add i.MX93 clk")
> > Reported-by: kernel test robot <lkp@intel.com>
> > Signed-off-by: Peng Fan <peng.fan@nxp.com>
> 
> Reviewed-by: Abel Vesa <abel.vesa@linaro.org>
> 
> Stephen will you pick this patch?

Ok. Got it for fixes.
diff mbox series

Patch

diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c
index f5c9fa40491c..dcc41d178238 100644
--- a/drivers/clk/imx/clk-imx93.c
+++ b/drivers/clk/imx/clk-imx93.c
@@ -332,7 +332,7 @@  static struct platform_driver imx93_clk_driver = {
 	.driver = {
 		.name = "imx93-ccm",
 		.suppress_bind_attrs = true,
-		.of_match_table = of_match_ptr(imx93_clk_of_match),
+		.of_match_table = imx93_clk_of_match,
 	},
 };
 module_platform_driver(imx93_clk_driver);