From patchwork Fri Feb 3 17:18:04 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony Liguori X-Patchwork-Id: 139430 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 2902F104792 for ; Sat, 4 Feb 2012 04:19:54 +1100 (EST) Received: from localhost ([::1]:58650 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtMnd-0000Vd-Jr for incoming@patchwork.ozlabs.org; Fri, 03 Feb 2012 12:19:49 -0500 Received: from eggs.gnu.org ([140.186.70.92]:36630) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtMnU-0000Ux-6x for qemu-devel@nongnu.org; Fri, 03 Feb 2012 12:19:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RtMnO-0000uG-NA for qemu-devel@nongnu.org; Fri, 03 Feb 2012 12:19:40 -0500 Received: from e9.ny.us.ibm.com ([32.97.182.139]:56829) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtMnO-0000tw-Ke for qemu-devel@nongnu.org; Fri, 03 Feb 2012 12:19:34 -0500 Received: from /spool/local by e9.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 3 Feb 2012 12:19:32 -0500 Received: from d01dlp01.pok.ibm.com (9.56.224.56) by e9.ny.us.ibm.com (192.168.1.109) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Fri, 3 Feb 2012 12:19:30 -0500 Received: from d01relay07.pok.ibm.com (d01relay07.pok.ibm.com [9.56.227.147]) by d01dlp01.pok.ibm.com (Postfix) with ESMTP id 1B38C38C806D for ; Fri, 3 Feb 2012 12:19:30 -0500 (EST) Received: from d01av04.pok.ibm.com (d01av04.pok.ibm.com [9.56.224.64]) by d01relay07.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q13HI6JR3027122 for ; Fri, 3 Feb 2012 12:18:07 -0500 Received: from d01av04.pok.ibm.com (loopback [127.0.0.1]) by d01av04.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q13HI6d4031093 for ; Fri, 3 Feb 2012 12:18:06 -0500 Received: from titi.austin.rr.com (sig-9-65-106-20.mts.ibm.com [9.65.106.20]) by d01av04.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id q13HI559030968; Fri, 3 Feb 2012 12:18:05 -0500 From: Anthony Liguori To: qemu-devel@nongnu.org Date: Fri, 3 Feb 2012 11:18:04 -0600 Message-Id: <1328289484-7305-1-git-send-email-aliguori@us.ibm.com> X-Mailer: git-send-email 1.7.4.1 X-Content-Scanned: Fidelis XPS MAILER x-cbid: 12020317-7182-0000-0000-000000ACC222 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 32.97.182.139 Cc: Anthony Liguori , Alex Graf Subject: [Qemu-devel] [PATCH] s390x: fix -drive in the absence of aliases 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 Signed-off-by: Anthony Liguori --- blockdev.c | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/blockdev.c b/blockdev.c index 7e4c548..7d7ac31 100644 --- a/blockdev.c +++ b/blockdev.c @@ -565,7 +565,11 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi) case IF_VIRTIO: /* add virtio block device */ opts = qemu_opts_create(qemu_find_opts("device"), NULL, 0); - qemu_opt_set(opts, "driver", "virtio-blk"); + if (arch_type == QEMU_ARCH_S390X) { + qemu_opt_set(opts, "driver", "virtio-blk-s390"); + } else { + qemu_opt_set(opts, "driver", "virtio-blk-pci"); + } qemu_opt_set(opts, "drive", dinfo->id); if (devaddr) qemu_opt_set(opts, "addr", devaddr);