* [PATCH] net: bnx2x: fix sparse warnings
@ 2015-02-05 15:47 Lad Prabhakar
2015-02-05 16:30 ` Eric Dumazet
2015-02-06 0:05 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Lad Prabhakar @ 2015-02-05 15:47 UTC (permalink / raw)
To: Ariel Elior, netdev; +Cc: linux-kernel, Lad, Prabhakar
From: "Lad, Prabhakar" <prabhakar.csengg@gmail.com>
this patch fixes following sparse warnings:
bnx2x_main.c:9172:6: warning: symbol 'bnx2x_stop_ptp' was not declared. Should it be static?
bnx2x_main.c:13321:6: warning: symbol 'bnx2x_register_phc' was not declared. Should it be static?
bnx2x_main.c:14638:5: warning: symbol 'bnx2x_enable_ptp_packets' was not declared. Should it be static?
Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
---
Found this issue on linux-next (gcc version 4.8.2,
sparse version 0.4.5-rc1)and applies on top linux-next.
drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
index 0758c8b..7155e1d 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
@@ -9169,7 +9169,7 @@ static void bnx2x_disable_ptp(struct bnx2x *bp)
}
/* Called during unload, to stop PTP-related stuff */
-void bnx2x_stop_ptp(struct bnx2x *bp)
+static void bnx2x_stop_ptp(struct bnx2x *bp)
{
/* Cancel PTP work queue. Should be done after the Tx queues are
* drained to prevent additional scheduling.
@@ -13318,7 +13318,7 @@ static int bnx2x_ptp_enable(struct ptp_clock_info *ptp,
return -ENOTSUPP;
}
-void bnx2x_register_phc(struct bnx2x *bp)
+static void bnx2x_register_phc(struct bnx2x *bp)
{
/* Fill the ptp_clock_info struct and register PTP clock*/
bp->ptp_clock_info.owner = THIS_MODULE;
@@ -14635,7 +14635,7 @@ static int bnx2x_send_reset_timesync_ramrod(struct bnx2x *bp)
return bnx2x_func_state_change(bp, &func_params);
}
-int bnx2x_enable_ptp_packets(struct bnx2x *bp)
+static int bnx2x_enable_ptp_packets(struct bnx2x *bp)
{
struct bnx2x_queue_state_params q_params;
int rc, i;
--
1.9.1
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH] net: bnx2x: fix sparse warnings
2015-02-05 15:47 [PATCH] net: bnx2x: fix sparse warnings Lad Prabhakar
@ 2015-02-05 16:30 ` Eric Dumazet
2015-02-06 0:05 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Eric Dumazet @ 2015-02-05 16:30 UTC (permalink / raw)
To: Lad Prabhakar; +Cc: Ariel Elior, netdev, linux-kernel
On Thu, 2015-02-05 at 15:47 +0000, Lad Prabhakar wrote:
> From: "Lad, Prabhakar" <prabhakar.csengg@gmail.com>
>
> this patch fixes following sparse warnings:
>
> bnx2x_main.c:9172:6: warning: symbol 'bnx2x_stop_ptp' was not declared. Should it be static?
> bnx2x_main.c:13321:6: warning: symbol 'bnx2x_register_phc' was not declared. Should it be static?
> bnx2x_main.c:14638:5: warning: symbol 'bnx2x_enable_ptp_packets' was not declared. Should it be static?
>
> Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
> ---
Note there is no need to cc lkml for such patches, netdev is more than
enough.
Acked-by: Eric Dumazet <edumazet@google.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] net: bnx2x: fix sparse warnings
2015-02-05 15:47 [PATCH] net: bnx2x: fix sparse warnings Lad Prabhakar
2015-02-05 16:30 ` Eric Dumazet
@ 2015-02-06 0:05 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2015-02-06 0:05 UTC (permalink / raw)
To: prabhakar.csengg; +Cc: ariel.elior, netdev, linux-kernel
From: Lad Prabhakar <prabhakar.csengg@gmail.com>
Date: Thu, 5 Feb 2015 15:47:17 +0000
> From: "Lad, Prabhakar" <prabhakar.csengg@gmail.com>
>
> this patch fixes following sparse warnings:
>
> bnx2x_main.c:9172:6: warning: symbol 'bnx2x_stop_ptp' was not declared. Should it be static?
> bnx2x_main.c:13321:6: warning: symbol 'bnx2x_register_phc' was not declared. Should it be static?
> bnx2x_main.c:14638:5: warning: symbol 'bnx2x_enable_ptp_packets' was not declared. Should it be static?
>
> Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Applied.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-02-06 0:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-05 15:47 [PATCH] net: bnx2x: fix sparse warnings Lad Prabhakar
2015-02-05 16:30 ` Eric Dumazet
2015-02-06 0:05 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox