]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - src/patches/suse-2.6.27.31/patches.xen/782-netback-error-handling.patch
Reenabled linux-xen, added patches for Xen Kernel Version 2.6.27.31,
[people/pmueller/ipfire-2.x.git] / src / patches / suse-2.6.27.31 / patches.xen / 782-netback-error-handling.patch
diff --git a/src/patches/suse-2.6.27.31/patches.xen/782-netback-error-handling.patch b/src/patches/suse-2.6.27.31/patches.xen/782-netback-error-handling.patch
new file mode 100644 (file)
index 0000000..7d07c4e
--- /dev/null
@@ -0,0 +1,27 @@
+From: http://xenbits.xensource.com/linux-2.6.18-xen.hg?rev/51decc39e5e7
+# HG changeset 782 patch
+# User Keir Fraser <keir.fraser@citrix.com>
+# Date 1233150129 0
+# Node ID 51decc39e5e73ea201d0b96108f8a893106a6864
+# Parent  c9783c08495c56337dec371582b3f948e3b5ed8d
+Subject: linux/netback: unmap tx ring gref when mapping of rx ring gref failed
+Patch-mainline: obsolete
+
+Signed-off-by: Jan Beulich <jbeulich@novell.com>
+
+--- head-2009-02-02.orig/drivers/xen/netback/interface.c       2009-02-02 09:28:02.000000000 +0100
++++ head-2009-02-02/drivers/xen/netback/interface.c    2009-02-02 09:40:43.000000000 +0100
+@@ -219,6 +219,13 @@ static int map_frontend_pages(
+               BUG();
+       if (op.status) {
++              struct gnttab_unmap_grant_ref unop;
++
++              gnttab_set_unmap_op(&unop,
++                                  (unsigned long)netif->tx_comms_area->addr,
++                                  GNTMAP_host_map, netif->tx_shmem_handle);
++              VOID(HYPERVISOR_grant_table_op(GNTTABOP_unmap_grant_ref,
++                                             &unop, 1));
+               DPRINTK(" Gnttab failure mapping rx_ring_ref!\n");
+               return op.status;
+       }