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] xen/blkfront: fix data size for xenbu

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] xen/blkfront: fix data size for xenbus_gather in connect()
From: Xen patchbot-linux-2.6.18-xen <patchbot@xxxxxxx>
Date: Mon, 09 May 2011 10:20:05 +0100
Delivery-date: Mon, 09 May 2011 02:20:10 -0700
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 Jan Beulich <jbeulich@xxxxxxxxxx>
# Date 1304931739 -3600
# Node ID c896d26c6b7c70bc82e353e7d02579fdd26af2f6
# Parent  3cb58d4cdd0b0f0ecd411804f79511cf055ec718
xen/blkfront: fix data size for xenbus_gather in connect()

From: Marek Marczykowski <marmarek@xxxxxxxxxxxx>

barrier variable is int, not long. This overflow caused another
variable override: "err" (in PV code) and "binfo" (in xenlinux code -
drivers/xen/blkfront/blkfront.c). The latter caused incorrect device
flags (RO/removable etc).

Signed-off-by: Marek Marczykowski <marmarek@xxxxxxxxxxxx>
Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---


diff -r 3cb58d4cdd0b -r c896d26c6b7c drivers/xen/blkfront/blkfront.c
--- a/drivers/xen/blkfront/blkfront.c   Tue Apr 05 12:42:02 2011 +0100
+++ b/drivers/xen/blkfront/blkfront.c   Mon May 09 10:02:19 2011 +0100
@@ -360,7 +360,7 @@
        }
 
        err = xenbus_gather(XBT_NIL, info->xbdev->otherend,
-                           "feature-barrier", "%lu", &info->feature_barrier,
+                           "feature-barrier", "%d", &info->feature_barrier,
                            NULL);
        if (err)
                info->feature_barrier = 0;

_______________________________________________
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] xen/blkfront: fix data size for xenbus_gather in connect(), Xen patchbot-linux-2 . 6 . 18-xen <=