From patchwork Wed Feb 22 07:18:48 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: jordan.l.justen@intel.com X-Patchwork-Id: 142412 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 DE317B6FAB for ; Wed, 22 Feb 2012 19:08:12 +1100 (EST) Received: from localhost ([::1]:36056 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S06UM-0006yh-Qk for incoming@patchwork.ozlabs.org; Wed, 22 Feb 2012 02:19:46 -0500 Received: from eggs.gnu.org ([140.186.70.92]:41736) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S06Tu-0006Cc-O4 for qemu-devel@nongnu.org; Wed, 22 Feb 2012 02:19:21 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S06To-0007nI-Bb for qemu-devel@nongnu.org; Wed, 22 Feb 2012 02:19:18 -0500 Received: from mga14.intel.com ([143.182.124.37]:51996) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S06Tn-0007n5-Vx for qemu-devel@nongnu.org; Wed, 22 Feb 2012 02:19:12 -0500 Received: from azsmga002.ch.intel.com ([10.2.17.35]) by azsmga102.ch.intel.com with ESMTP; 21 Feb 2012 23:19:09 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.71,315,1320652800"; d="scan'208";a="68967697" Received: from unknown (HELO jljusten-laptop.amr.corp.intel.com) ([10.255.15.109]) by AZSMGA002.ch.intel.com with ESMTP; 21 Feb 2012 23:19:09 -0800 From: Jordan Justen To: qemu-devel@nongnu.org Date: Tue, 21 Feb 2012 23:18:48 -0800 Message-Id: <1329895136-20494-2-git-send-email-jordan.l.justen@intel.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1329895136-20494-1-git-send-email-jordan.l.justen@intel.com> References: <1329895136-20494-1-git-send-email-jordan.l.justen@intel.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 143.182.124.37 Cc: Jordan Justen Subject: [Qemu-devel] [PATCH v11 1/9] blockdev: allow read-only pflash devices 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: Jordan Justen --- blockdev.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/blockdev.c b/blockdev.c index 7a6613a..2c132a3 100644 --- a/blockdev.c +++ b/blockdev.c @@ -595,7 +595,8 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi) /* CDROM is fine for any interface, don't check. */ ro = 1; } else if (ro == 1) { - if (type != IF_SCSI && type != IF_VIRTIO && type != IF_FLOPPY && type != IF_NONE) { + if (type != IF_SCSI && type != IF_VIRTIO && type != IF_FLOPPY && + type != IF_NONE && type != IF_PFLASH) { error_report("readonly not supported by this bus type"); goto err; }