WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [linux-2.6.18-xen] merge with linux-2.6.18-xen.hg (stagi

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] merge with linux-2.6.18-xen.hg (staging)
From: "Xen patchbot-linux-2.6.18-xen" <patchbot-linux-2.6.18-xen@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 31 Oct 2007 15:00:18 -0700
Delivery-date: Wed, 31 Oct 2007 15:00:49 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Alex Williamson <alex.williamson@xxxxxx>
# Date 1193083057 21600
# Node ID 8a30e505c2a3c87b2e2e2c65ac8a0341386eff8e
# Parent  3b7be86c0eb1414a86ec6cfe404f8cc47fc9d62c
# Parent  709db80c03c3d7606744a71f48f5186358a5e659
merge with linux-2.6.18-xen.hg (staging)
---
 include/linux/netfilter_bridge.h |   14 +++++++++-----
 net/bridge/br_netfilter.c        |    4 ++--
 2 files changed, 11 insertions(+), 7 deletions(-)

diff -r 3b7be86c0eb1 -r 8a30e505c2a3 include/linux/netfilter_bridge.h
--- a/include/linux/netfilter_bridge.h  Sun Oct 21 15:08:11 2007 -0600
+++ b/include/linux/netfilter_bridge.h  Mon Oct 22 13:57:37 2007 -0600
@@ -7,6 +7,7 @@
 #include <linux/netfilter.h>
 #if defined(__KERNEL__) && defined(CONFIG_BRIDGE_NETFILTER)
 #include <linux/if_ether.h>
+#include <linux/if_vlan.h>
 #endif
 
 /* Bridge Hooks */
@@ -54,16 +55,19 @@ int nf_bridge_maybe_copy_header(struct s
 
        if (skb->nf_bridge) {
                if (skb->protocol == __constant_htons(ETH_P_8021Q)) {
-                       err = skb_cow(skb, 18);
+                       int header_size = ETH_HLEN + VLAN_HLEN;
+
+                       err = skb_cow(skb, header_size);
                        if (err)
                                return err;
-                       memcpy(skb->data - 18, skb->nf_bridge->data, 18);
-                       skb_push(skb, 4);
+                       memcpy(skb->data - header_size, skb->nf_bridge->data,
+                              header_size);
+                       skb_push(skb, VLAN_HLEN);
                } else {
-                       err = skb_cow(skb, 16);
+                       err = skb_cow(skb, ETH_HLEN);
                        if (err)
                                return err;
-                       memcpy(skb->data - 16, skb->nf_bridge->data, 16);
+                       memcpy(skb->data - ETH_HLEN, skb->nf_bridge->data, 
ETH_HLEN);
                }
        }
        return 0;
diff -r 3b7be86c0eb1 -r 8a30e505c2a3 net/bridge/br_netfilter.c
--- a/net/bridge/br_netfilter.c Sun Oct 21 15:08:11 2007 -0600
+++ b/net/bridge/br_netfilter.c Mon Oct 22 13:57:37 2007 -0600
@@ -127,10 +127,10 @@ static inline struct nf_bridge_info *nf_
 
 static inline void nf_bridge_save_header(struct sk_buff *skb)
 {
-        int header_size = 16;
+        int header_size = ETH_HLEN;
 
        if (skb->protocol == htons(ETH_P_8021Q))
-               header_size = 18;
+               header_size += VLAN_HLEN;
 
        memcpy(skb->nf_bridge->data, skb->data - header_size, header_size);
 }

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>