Message ID | 20090217093908.GB5341@ff.dom.local |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
Jarek Poplawski wrote: > Sorry: > -----------------> take 2: changelog fix only > > vlan: Update skb->mac_header in __vlan_put_tag(). > > After moving mac addresses in __vlan_put_tag() skb->mac_header needs > to be updated. > This works on IPoE. I notice no change with or w/o this patch on IPoE only routing. However has no effect on the original problem i reported with IPoA --> NAT --> VLAN Tested-by: Karl Hiramoto <karl@hiramoto.org> > Reported-by: Karl Hiramoto <karl@hiramoto.org> > Signed-off-by: Jarek Poplawski <jarkao2@gmail.com> > --- > > include/linux/if_vlan.h | 1 + > 1 files changed, 1 insertions(+), 0 deletions(-) > > diff --git a/include/linux/if_vlan.h b/include/linux/if_vlan.h > index f8ff918..e1ff5b1 100644 > --- a/include/linux/if_vlan.h > +++ b/include/linux/if_vlan.h > @@ -210,6 +210,7 @@ static inline struct sk_buff *__vlan_put_tag(struct sk_buff *skb, u16 vlan_tci) > > /* Move the mac addresses to the beginning of the new header. */ > memmove(skb->data, skb->data + VLAN_HLEN, 2 * VLAN_ETH_ALEN); > + skb->mac_header -= VLAN_HLEN; > > /* first, the ethernet type */ > veth->h_vlan_proto = htons(ETH_P_8021Q); > > -- > 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 > > -- 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
On Tue, Feb 17, 2009 at 12:05:24PM +0100, Karl Hiramoto wrote: > > > Jarek Poplawski wrote: > > Sorry: > > -----------------> take 2: changelog fix only > > > > vlan: Update skb->mac_header in __vlan_put_tag(). > > > > After moving mac addresses in __vlan_put_tag() skb->mac_header needs > > to be updated. > > > This works on IPoE. I notice no change with or w/o this patch on IPoE > only routing. However has no effect on the original problem i > reported with IPoA --> NAT --> VLAN > > Tested-by: Karl Hiramoto <karl@hiramoto.org> Yes, since it didn't affect the working case with your patch, I didn't expect it would matter here, but it looks like needed so good to know it seems not to make anything wrong at least. Thanks for testing, Jarek P. > > > Reported-by: Karl Hiramoto <karl@hiramoto.org> > > Signed-off-by: Jarek Poplawski <jarkao2@gmail.com> > > --- > > > > include/linux/if_vlan.h | 1 + > > 1 files changed, 1 insertions(+), 0 deletions(-) > > > > diff --git a/include/linux/if_vlan.h b/include/linux/if_vlan.h > > index f8ff918..e1ff5b1 100644 > > --- a/include/linux/if_vlan.h > > +++ b/include/linux/if_vlan.h > > @@ -210,6 +210,7 @@ static inline struct sk_buff *__vlan_put_tag(struct sk_buff *skb, u16 vlan_tci) > > > > /* Move the mac addresses to the beginning of the new header. */ > > memmove(skb->data, skb->data + VLAN_HLEN, 2 * VLAN_ETH_ALEN); > > + skb->mac_header -= VLAN_HLEN; > > > > /* first, the ethernet type */ > > veth->h_vlan_proto = htons(ETH_P_8021Q); > > > > -- > > 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 > > > > > -- 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
From: Jarek Poplawski <jarkao2@gmail.com> Date: Tue, 17 Feb 2009 09:39:08 +0000 > vlan: Update skb->mac_header in __vlan_put_tag(). > > After moving mac addresses in __vlan_put_tag() skb->mac_header needs > to be updated. > > Reported-by: Karl Hiramoto <karl@hiramoto.org> > Signed-off-by: Jarek Poplawski <jarkao2@gmail.com> Patch applied, this is correct even though it doesn't fix the bug. I'm pretty sure that packet corruption is a driver error of some kind rather than some kind of generic problem. -- 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
diff --git a/include/linux/if_vlan.h b/include/linux/if_vlan.h index f8ff918..e1ff5b1 100644 --- a/include/linux/if_vlan.h +++ b/include/linux/if_vlan.h @@ -210,6 +210,7 @@ static inline struct sk_buff *__vlan_put_tag(struct sk_buff *skb, u16 vlan_tci) /* Move the mac addresses to the beginning of the new header. */ memmove(skb->data, skb->data + VLAN_HLEN, 2 * VLAN_ETH_ALEN); + skb->mac_header -= VLAN_HLEN; /* first, the ethernet type */ veth->h_vlan_proto = htons(ETH_P_8021Q);
Sorry: -----------------> take 2: changelog fix only vlan: Update skb->mac_header in __vlan_put_tag(). After moving mac addresses in __vlan_put_tag() skb->mac_header needs to be updated. Reported-by: Karl Hiramoto <karl@hiramoto.org> Signed-off-by: Jarek Poplawski <jarkao2@gmail.com> --- include/linux/if_vlan.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) -- 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