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-devel

[Xen-devel] [PATCH] linux-2.6.18/blktap2: fix after c/s 1035

To: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] linux-2.6.18/blktap2: fix after c/s 1035
From: "Jan Beulich" <JBeulich@xxxxxxxxxx>
Date: Wed, 17 Nov 2010 15:15:01 +0000
Cc: Olaf Hering <olaf@xxxxxxxxx>
Delivery-date: Wed, 17 Nov 2010 07:15:58 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
The grant handle must be invalidated only in the error path.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>

--- a/drivers/xen/blktap2/device.c
+++ b/drivers/xen/blktap2/device.c
@@ -516,8 +516,8 @@ blktap_map_foreign(struct blktap *tap,
                                WARN_ON(table->grants[grant].status == 
GNTST_eagain);
                                BTERR("invalid user buffer: could not remap 
it\n");
                                err |= 1;
+                               table->grants[grant].handle = 
INVALID_GRANT_HANDLE;
                        }
-                       table->grants[grant].handle = INVALID_GRANT_HANDLE;
                        request->handles[i].user = table->grants[grant].handle;
                        grant++;
                }



Attachment: xen-blktap2-fix-1035.patch
Description: Text document

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>