[ovs-dev] [PATCH 1/3] datapath: Rename skb_network_protocol() to __skb_network_protocol()

Pravin Shelar pshelar at nicira.com
Tue Jul 9 16:38:32 UTC 2013


On Tue, Jul 9, 2013 at 9:00 AM, Thomas Graf <tgraf at redhat.com> wrote:
> The function skb_network_protocol() is already defined in
> <linux/netdevice.h> upstream but not an exported symbol.
>
> Rename the OVS internal implementation to work around this.
>
Are you seeing problem with RHEL kernel backports?
OVS does not support upstream kernel so this is not problem at this time.


> Signed-off-by: Thomas Graf <tgraf at redhat.com>
> ---
>  datapath/linux/compat/gso.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/datapath/linux/compat/gso.c b/datapath/linux/compat/gso.c
> index 3cadde9..43418d3 100644
> --- a/datapath/linux/compat/gso.c
> +++ b/datapath/linux/compat/gso.c
> @@ -36,7 +36,7 @@
>
>  #include "gso.h"
>
> -static __be16 skb_network_protocol(struct sk_buff *skb)
> +static __be16 __skb_network_protocol(struct sk_buff *skb)
>  {
>         __be16 type = skb->protocol;
>         int vlan_depth = ETH_HLEN;
> @@ -68,7 +68,7 @@ static struct sk_buff *tnl_skb_gso_segment(struct sk_buff *skb,
>
>         /* setup whole inner packet to get protocol. */
>         __skb_pull(skb, mac_offset);
> -       skb->protocol = skb_network_protocol(skb);
> +       skb->protocol = __skb_network_protocol(skb);
>
>         /* setup l3 packet to gso, to get around segmentation bug on older kernel.*/
>         __skb_pull(skb, (pkt_hlen - mac_offset));
> --
> 1.8.3.1
>



More information about the dev mailing list