From patchwork Fri Dec 11 16:53:07 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefano Stabellini X-Patchwork-Id: 555829 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 1D58D1402A9 for ; Sat, 12 Dec 2015 03:54:14 +1100 (AEDT) Received: from localhost ([::1]:48517 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7QxQ-000513-23 for incoming@patchwork.ozlabs.org; Fri, 11 Dec 2015 11:54:12 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39534) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7Qx2-0004R7-6k for qemu-devel@nongnu.org; Fri, 11 Dec 2015 11:53:48 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a7Qwx-0001uI-Dn for qemu-devel@nongnu.org; Fri, 11 Dec 2015 11:53:48 -0500 Received: from smtp.citrix.com ([66.165.176.89]:21549) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7Qwx-0001u4-6A for qemu-devel@nongnu.org; Fri, 11 Dec 2015 11:53:43 -0500 X-IronPort-AV: E=Sophos;i="5.20,414,1444694400"; d="scan'208";a="318159348" From: Stefano Stabellini To: Date: Fri, 11 Dec 2015 16:53:07 +0000 Message-ID: <1449852787-20314-1-git-send-email-stefano.stabellini@eu.citrix.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: MIME-Version: 1.0 X-DLP: MIA2 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 66.165.176.89 Cc: xen-devel@lists.xensource.com, qemu-devel@nongnu.org, Stefano Stabellini Subject: [Qemu-devel] [PULL 1/1] xen_disk: treat "vhd" as "vpc" X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org The Xen toolstack uses "vhd" to specify a disk in VHD format, however the name of the driver in QEMU is "vpc". Replace "vhd" with "vpc", so that QEMU can find the right driver to use for it. Signed-off-by: Stefano Stabellini --- hw/block/xen_disk.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/block/xen_disk.c b/hw/block/xen_disk.c index 8146650..a48e726 100644 --- a/hw/block/xen_disk.c +++ b/hw/block/xen_disk.c @@ -825,6 +825,9 @@ static int blk_init(struct XenDevice *xendev) if (!strcmp("aio", blkdev->fileproto)) { blkdev->fileproto = "raw"; } + if (!strcmp("vhd", blkdev->fileproto)) { + blkdev->fileproto = "vpc"; + } if (blkdev->mode == NULL) { blkdev->mode = xenstore_read_be_str(&blkdev->xendev, "mode"); }