diff mbox series

[net-next] net: dsa: microchip: fix Clang -Wunused-const-variable warning on 'ksz_dt_ids'

Message ID 20220715053334.5986-1-arun.ramadoss@microchip.com (mailing list archive)
State Accepted
Commit da53af8cb9329797dfd12f9034adafc4a1e01620
Delegated to: Netdev Maintainers
Headers show
Series [net-next] net: dsa: microchip: fix Clang -Wunused-const-variable warning on 'ksz_dt_ids' | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
netdev/cover_letter success Single patches do not need cover letters
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers success CCed 15 of 15 maintainers
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 8 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Arun Ramadoss July 15, 2022, 5:33 a.m. UTC
This patch removes the of_match_ptr() pointer when dereferencing the
ksz_dt_ids which produce the unused variable warning.

Reported-by: kernel test robot <lkp@intel.com>
Suggested-by: Arnd Bergmann <arnd@kernel.org>
Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>
---
 drivers/net/dsa/microchip/ksz_spi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


base-commit: 6e6fbb72e48ba3da229ff2158cf0d26aa50a218a

Comments

Arnd Bergmann July 15, 2022, 7:40 a.m. UTC | #1
On Fri, Jul 15, 2022 at 7:33 AM Arun Ramadoss
<arun.ramadoss@microchip.com> wrote:
>
> This patch removes the of_match_ptr() pointer when dereferencing the
> ksz_dt_ids which produce the unused variable warning.
>
> Reported-by: kernel test robot <lkp@intel.com>
> Suggested-by: Arnd Bergmann <arnd@kernel.org>
> Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>

Looks good to me, thanks!

Reviewed-by: Arnd Bergmann <arnd@arndb.de>
patchwork-bot+netdevbpf@kernel.org July 18, 2022, 10:40 a.m. UTC | #2
Hello:

This patch was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:

On Fri, 15 Jul 2022 11:03:34 +0530 you wrote:
> This patch removes the of_match_ptr() pointer when dereferencing the
> ksz_dt_ids which produce the unused variable warning.
> 
> Reported-by: kernel test robot <lkp@intel.com>
> Suggested-by: Arnd Bergmann <arnd@kernel.org>
> Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>
> 
> [...]

Here is the summary with links:
  - [net-next] net: dsa: microchip: fix Clang -Wunused-const-variable warning on 'ksz_dt_ids'
    https://git.kernel.org/netdev/net-next/c/da53af8cb932

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/dsa/microchip/ksz_spi.c b/drivers/net/dsa/microchip/ksz_spi.c
index 4844830dca72..05bd089795f8 100644
--- a/drivers/net/dsa/microchip/ksz_spi.c
+++ b/drivers/net/dsa/microchip/ksz_spi.c
@@ -215,7 +215,7 @@  static struct spi_driver ksz_spi_driver = {
 	.driver = {
 		.name	= "ksz-switch",
 		.owner	= THIS_MODULE,
-		.of_match_table = of_match_ptr(ksz_dt_ids),
+		.of_match_table = ksz_dt_ids,
 	},
 	.id_table = ksz_spi_ids,
 	.probe	= ksz_spi_probe,