bnx2x: Provide declaration of dmae_reg_go_c in header
authorSimon Horman <horms@kernel.org>
Tue, 6 Aug 2024 10:56:01 +0000 (11:56 +0100)
committerJakub Kicinski <kuba@kernel.org>
Fri, 9 Aug 2024 02:43:06 +0000 (19:43 -0700)
Provide declaration of dmae_reg_go_c in header.
This symbol is defined in bnx2x_main.c.
And used in that file and bnx2x_stats.c.

However, Sparse complains that there is no declaration
of the symbol in dmae_reg_go_c nor is the symbol static.

 .../bnx2x_main.c:291:11: warning: symbol 'dmae_reg_go_c' was not declared. Should it be static?

Address this by moving the declaration from bnx2x_stats.c to bnx2x_reg.h.

No functional change intended.
Compile tested only.

Signed-off-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20240806-bnx2x-dec-v1-1-ae844ec785e4@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/broadcom/bnx2x/bnx2x_reg.h
drivers/net/ethernet/broadcom/bnx2x/bnx2x_stats.c

index 4e9215bce4ad49b67df0265f20d4dafc06d2b915..a018f251d19867c276d50d5fb06a93be462cc651 100644 (file)
 #define DORQ_REG_VF_TYPE_VALUE_0                                0x170258
 #define DORQ_REG_VF_USAGE_CT_LIMIT                              0x170340
 
+extern const u32 dmae_reg_go_c[];
+
 /* [RW 4] Initial activity counter value on the load request; when the
    shortcut is done. */
 #define DORQ_REG_SHRT_ACT_CNT                                   0x170070
index 2bb133ae61c39750b547c07e9242b4889695870a..ba6729f2f9c0f224935e377d7753a7efb6f573a0 100644 (file)
@@ -23,8 +23,6 @@
 #include "bnx2x_cmn.h"
 #include "bnx2x_sriov.h"
 
-extern const u32 dmae_reg_go_c[];
-
 /* Statistics */
 
 /*