* [PATCH-net] drivers/net: fix build warning in ethernet/sfc/tx.c
@ 2014-02-06 16:45 Paul Gortmaker
2014-02-06 16:59 ` Shradha Shah
2014-02-07 6:29 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Paul Gortmaker @ 2014-02-06 16:45 UTC (permalink / raw)
To: netdev; +Cc: linux-net-drivers, Paul Gortmaker, Jon Cooper, Ben Hutchings
Commit ee45fd92c739db5b7950163d91dfe5f016af6d24 ("sfc: Use TX PIO
for sufficiently small packets") introduced the following warning:
drivers/net/ethernet/sfc/tx.c: In function 'efx_enqueue_skb':
drivers/net/ethernet/sfc/tx.c:432:1: warning: label 'finish_packet' defined but not used
Stick the label inside the same #ifdef that the code which calls
it uses. Note that this is only seen for arch that do not set
ARCH_HAS_IOREMAP_WC, such as arm, mips, sparc, ..., as the others
enable the write combining code and hence use the label.
Cc: Jon Cooper <jcooper@solarflare.com>
Cc: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
drivers/net/ethernet/sfc/tx.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/ethernet/sfc/tx.c b/drivers/net/ethernet/sfc/tx.c
index c49d1fb16965..75d11fa4eb0a 100644
--- a/drivers/net/ethernet/sfc/tx.c
+++ b/drivers/net/ethernet/sfc/tx.c
@@ -429,7 +429,9 @@ netdev_tx_t efx_enqueue_skb(struct efx_tx_queue *tx_queue, struct sk_buff *skb)
}
/* Transfer ownership of the skb to the final buffer */
+#ifdef EFX_USE_PIO
finish_packet:
+#endif
buffer->skb = skb;
buffer->flags = EFX_TX_BUF_SKB | dma_flags;
--
1.8.5.2
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH-net] drivers/net: fix build warning in ethernet/sfc/tx.c
2014-02-06 16:45 [PATCH-net] drivers/net: fix build warning in ethernet/sfc/tx.c Paul Gortmaker
@ 2014-02-06 16:59 ` Shradha Shah
2014-02-07 6:29 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Shradha Shah @ 2014-02-06 16:59 UTC (permalink / raw)
To: Paul Gortmaker; +Cc: netdev, linux-net-drivers, Jon Cooper, Ben Hutchings
On 02/06/2014 04:45 PM, Paul Gortmaker wrote:
> Commit ee45fd92c739db5b7950163d91dfe5f016af6d24 ("sfc: Use TX PIO
> for sufficiently small packets") introduced the following warning:
>
> drivers/net/ethernet/sfc/tx.c: In function 'efx_enqueue_skb':
> drivers/net/ethernet/sfc/tx.c:432:1: warning: label 'finish_packet' defined but not used
>
> Stick the label inside the same #ifdef that the code which calls
> it uses. Note that this is only seen for arch that do not set
> ARCH_HAS_IOREMAP_WC, such as arm, mips, sparc, ..., as the others
> enable the write combining code and hence use the label.
>
> Cc: Jon Cooper <jcooper@solarflare.com>
> Cc: Ben Hutchings <bhutchings@solarflare.com>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Acked-by: Shradha Shah <sshah@solarflare.com>
> ---
> drivers/net/ethernet/sfc/tx.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/net/ethernet/sfc/tx.c b/drivers/net/ethernet/sfc/tx.c
> index c49d1fb16965..75d11fa4eb0a 100644
> --- a/drivers/net/ethernet/sfc/tx.c
> +++ b/drivers/net/ethernet/sfc/tx.c
> @@ -429,7 +429,9 @@ netdev_tx_t efx_enqueue_skb(struct efx_tx_queue *tx_queue, struct sk_buff *skb)
> }
>
> /* Transfer ownership of the skb to the final buffer */
> +#ifdef EFX_USE_PIO
> finish_packet:
> +#endif
> buffer->skb = skb;
> buffer->flags = EFX_TX_BUF_SKB | dma_flags;
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH-net] drivers/net: fix build warning in ethernet/sfc/tx.c
2014-02-06 16:45 [PATCH-net] drivers/net: fix build warning in ethernet/sfc/tx.c Paul Gortmaker
2014-02-06 16:59 ` Shradha Shah
@ 2014-02-07 6:29 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2014-02-07 6:29 UTC (permalink / raw)
To: paul.gortmaker; +Cc: netdev, linux-net-drivers, jcooper, bhutchings
From: Paul Gortmaker <paul.gortmaker@windriver.com>
Date: Thu, 6 Feb 2014 11:45:12 -0500
> Commit ee45fd92c739db5b7950163d91dfe5f016af6d24 ("sfc: Use TX PIO
> for sufficiently small packets") introduced the following warning:
>
> drivers/net/ethernet/sfc/tx.c: In function 'efx_enqueue_skb':
> drivers/net/ethernet/sfc/tx.c:432:1: warning: label 'finish_packet' defined but not used
>
> Stick the label inside the same #ifdef that the code which calls
> it uses. Note that this is only seen for arch that do not set
> ARCH_HAS_IOREMAP_WC, such as arm, mips, sparc, ..., as the others
> enable the write combining code and hence use the label.
>
> Cc: Jon Cooper <jcooper@solarflare.com>
> Cc: Ben Hutchings <bhutchings@solarflare.com>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Applied.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-02-07 6:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-06 16:45 [PATCH-net] drivers/net: fix build warning in ethernet/sfc/tx.c Paul Gortmaker
2014-02-06 16:59 ` Shradha Shah
2014-02-07 6:29 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).