From patchwork Sun Jan 8 19:51:33 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: 134924 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 B9A5EB6F68 for ; Mon, 9 Jan 2012 06:53:13 +1100 (EST) Received: from localhost ([::1]:54525 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RjynV-0004km-Rj for incoming@patchwork.ozlabs.org; Sun, 08 Jan 2012 14:52:53 -0500 Received: from eggs.gnu.org ([140.186.70.92]:35497) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RjynN-0004Zy-N7 for qemu-devel@nongnu.org; Sun, 08 Jan 2012 14:52:46 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RjynM-0004mb-7Y for qemu-devel@nongnu.org; Sun, 08 Jan 2012 14:52:45 -0500 Received: from mga02.intel.com ([134.134.136.20]:43876) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RjynL-0004mK-Uj for qemu-devel@nongnu.org; Sun, 08 Jan 2012 14:52:44 -0500 Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP; 08 Jan 2012 11:52:43 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.67,352,1309762800"; d="scan'208";a="94193944" Received: from unknown (HELO jljusten-laptop.amr.corp.intel.com) ([10.255.13.217]) by orsmga001.jf.intel.com with ESMTP; 08 Jan 2012 11:52:43 -0800 From: Jordan Justen To: qemu-devel@nongnu.org Date: Sun, 8 Jan 2012 11:51:33 -0800 Message-Id: <1326052300-1172-2-git-send-email-jordan.l.justen@intel.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1326052300-1172-1-git-send-email-jordan.l.justen@intel.com> References: <1326052300-1172-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: 134.134.136.20 Cc: Jordan Justen Subject: [Qemu-devel] [PATCH v10 1/8] 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 c832782..2d1b8f7 100644 --- a/blockdev.c +++ b/blockdev.c @@ -557,7 +557,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; }