Thread (1 message) 1 message, 1 author, 2014-05-21

Re: [PATCH v2.57] datapath: Add basic MPLS support to kernel

From: Jesse Gross <hidden>
Date: 2014-05-21 02:30:38

On Thu, May 15, 2014 at 4:07 PM, Simon Horman [off-list ref] wrote:
quoted hunk
diff --git a/datapath/linux/compat/gso.c b/datapath/linux/compat/gso.c
index 9ded17c..d9b4485 100644
--- a/datapath/linux/compat/gso.c
+++ b/datapath/linux/compat/gso.c
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3,11,0)
 static bool dev_supports_vlan_tx(struct net_device *dev)
 {
-#if defined(HAVE_VLAN_BUG_WORKAROUND)
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)
+       return true;
Should this be greater than 2.6.37 instead of less than?
quoted hunk
diff --git a/datapath/linux/compat/include/linux/netdevice.h b/datapath/linux/compat/include/linux/netdevice.h
index d726390..0381002 100644
--- a/datapath/linux/compat/include/linux/netdevice.h
+++ b/datapath/linux/compat/include/linux/netdevice.h
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,38)
 #define netif_skb_features rpl_netif_skb_features
 netdev_features_t rpl_netif_skb_features(struct sk_buff *skb);
Currently this function doesn't look at mpls_features. Should it for
things other than TSO?
quoted hunk
diff --git a/datapath/linux/compat/netdevice.c b/datapath/linux/compat/netdevice.c
index 1dc5abf..d22fced 100644
--- a/datapath/linux/compat/netdevice.c
+++ b/datapath/linux/compat/netdevice.c
@@ -78,6 +83,9 @@ struct sk_buff *rpl_skb_gso_segment(struct sk_buff *skb,
        __be16 skb_proto;
        struct sk_buff *skb_gso;

+       if (eth_p_mpls(skb->protocol))
+               type = ovs_skb_get_inner_protocol(skb);
+
        while (type == htons(ETH_P_8021Q)) {
                struct vlan_hdr *vh;
Is the ordering on this backwards given that we expect that VLANs can
be on the outside but not the other way around?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help