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] blktap2: Fwd: Fix wild ptr deref duri

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] blktap2: Fwd: Fix wild ptr deref during device destruction.
From: "Xen patchbot-linux-2.6.18-xen" <patchbot-linux-2.6.18-xen@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 01 Mar 2010 02:00:11 -0800
Delivery-date: Mon, 01 Mar 2010 02:00:22 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1267437354 0
# Node ID 46c3ae66c32b97bc66f2ed13a715839712972659
# Parent  4b0c1a686393ed4283e4942c6997354b7c37d370
blktap2: Fwd: Fix wild ptr deref during device destruction.

A put_disk() before blk_cleanup_queue() would free gd before gd->queue
is read.

Signed-off-by: Daniel Stodden <daniel.stodden@xxxxxxxxxx>
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
 drivers/xen/blktap2/device.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -r 4b0c1a686393 -r 46c3ae66c32b drivers/xen/blktap2/device.c
--- a/drivers/xen/blktap2/device.c      Mon Mar 01 09:55:09 2010 +0000
+++ b/drivers/xen/blktap2/device.c      Mon Mar 01 09:55:54 2010 +0000
@@ -1082,8 +1082,8 @@ blktap_device_destroy(struct blktap *tap
 #endif
 
        del_gendisk(dev->gd);
+       blk_cleanup_queue(dev->gd->queue);
        put_disk(dev->gd);
-       blk_cleanup_queue(dev->gd->queue);
 
        dev->gd = NULL;
 

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [linux-2.6.18-xen] blktap2: Fwd: Fix wild ptr deref during device destruction., Xen patchbot-linux-2.6.18-xen <=