netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] vxlan: make get_rx_port static
@ 2013-12-14  0:37 Stephen Hemminger
  2013-12-17 20:19 ` David Miller
  2013-12-19 20:00 ` Joseph Gasparakis
  0 siblings, 2 replies; 3+ messages in thread
From: Stephen Hemminger @ 2013-12-14  0:37 UTC (permalink / raw)
  To: David Miller; +Cc: netdev

Make local function static, only used in vxlan itself right now.
Maybe someone had ideas about offload, but they can expose it when
they send their offload upstream.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>

--- a/drivers/net/vxlan.c	2013-12-12 11:48:17.057855220 -0800
+++ b/drivers/net/vxlan.c	2013-12-12 11:56:55.949774139 -0800
@@ -2039,7 +2039,7 @@ static struct device_type vxlan_type = {
  * supply the listening VXLAN udp ports. Callers are expected
  * to implement the ndo_add_vxlan_port.
  */
-void vxlan_get_rx_port(struct net_device *dev)
+static void vxlan_get_rx_port(struct net_device *dev)
 {
 	struct vxlan_sock *vs;
 	struct net *net = dev_net(dev);
--- a/include/net/vxlan.h	2013-12-12 11:48:17.057855220 -0800
+++ b/include/net/vxlan.h	2013-12-12 11:56:55.949774139 -0800
@@ -41,11 +41,4 @@ __be16 vxlan_src_port(__u16 port_min, __
 /* IPv6 header + UDP + VXLAN + Ethernet header */
 #define VXLAN6_HEADROOM (40 + 8 + 8 + 14)
 
-#if IS_ENABLED(CONFIG_VXLAN)
-void vxlan_get_rx_port(struct net_device *netdev);
-#else
-static inline void vxlan_get_rx_port(struct net_device *netdev)
-{
-}
-#endif
 #endif

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] vxlan: make get_rx_port static
  2013-12-14  0:37 [PATCH net-next] vxlan: make get_rx_port static Stephen Hemminger
@ 2013-12-17 20:19 ` David Miller
  2013-12-19 20:00 ` Joseph Gasparakis
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2013-12-17 20:19 UTC (permalink / raw)
  To: stephen; +Cc: netdev

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 13 Dec 2013 16:37:22 -0800

> -void vxlan_get_rx_port(struct net_device *dev)
> +static void vxlan_get_rx_port(struct net_device *dev)

If you are going to make this static, you need to remove the
module symbol export as well.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] vxlan: make get_rx_port static
  2013-12-14  0:37 [PATCH net-next] vxlan: make get_rx_port static Stephen Hemminger
  2013-12-17 20:19 ` David Miller
@ 2013-12-19 20:00 ` Joseph Gasparakis
  1 sibling, 0 replies; 3+ messages in thread
From: Joseph Gasparakis @ 2013-12-19 20:00 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: David Miller, netdev@vger.kernel.org



On Fri, 13 Dec 2013, Stephen Hemminger wrote:

> Make local function static, only used in vxlan itself right now.
> Maybe someone had ideas about offload, but they can expose it when
> they send their offload upstream.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> 
> --- a/drivers/net/vxlan.c	2013-12-12 11:48:17.057855220 -0800
> +++ b/drivers/net/vxlan.c	2013-12-12 11:56:55.949774139 -0800
> @@ -2039,7 +2039,7 @@ static struct device_type vxlan_type = {
>   * supply the listening VXLAN udp ports. Callers are expected
>   * to implement the ndo_add_vxlan_port.
>   */
> -void vxlan_get_rx_port(struct net_device *dev)
> +static void vxlan_get_rx_port(struct net_device *dev)
>  {
>  	struct vxlan_sock *vs;
>  	struct net *net = dev_net(dev);
> --- a/include/net/vxlan.h	2013-12-12 11:48:17.057855220 -0800
> +++ b/include/net/vxlan.h	2013-12-12 11:56:55.949774139 -0800
> @@ -41,11 +41,4 @@ __be16 vxlan_src_port(__u16 port_min, __
>  /* IPv6 header + UDP + VXLAN + Ethernet header */
>  #define VXLAN6_HEADROOM (40 + 8 + 8 + 14)
>  
> -#if IS_ENABLED(CONFIG_VXLAN)
> -void vxlan_get_rx_port(struct net_device *netdev);
> -#else
> -static inline void vxlan_get_rx_port(struct net_device *netdev)
> -{
> -}
> -#endif
>  #endif
> --

Please do not apply this patch. Jeff Kirsher is about to send a patch that 
takes advantage of vxlan_get_rx_port in i40e.

> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-12-19 19:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-14  0:37 [PATCH net-next] vxlan: make get_rx_port static Stephen Hemminger
2013-12-17 20:19 ` David Miller
2013-12-19 20:00 ` Joseph Gasparakis

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).