From patchwork Wed Jun 8 15:31:04 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Liu X-Patchwork-Id: 9165035 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A3C3E60572 for ; Wed, 8 Jun 2016 15:33:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 967F428047 for ; Wed, 8 Jun 2016 15:33:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8B3C3282DC; Wed, 8 Jun 2016 15:33:40 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 040CB28047 for ; Wed, 8 Jun 2016 15:33:39 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bAfRm-00084y-6F; Wed, 08 Jun 2016 15:31:10 +0000 Received: from mail6.bemta6.messagelabs.com ([85.158.143.247]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bAfRk-00084s-SY for xen-devel@lists.xenproject.org; Wed, 08 Jun 2016 15:31:08 +0000 Received: from [85.158.143.35] by server-3.bemta-6.messagelabs.com id D8/73-25713-C3A38575; Wed, 08 Jun 2016 15:31:08 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrOLMWRWlGSWpSXmKPExsXitHSDva61VUS 4QdcsE4vvWyYzOTB6HP5whSWAMYo1My8pvyKBNePSixbWgnU8FTtnJTQwruboYuTkkBDwl5j7 dxIziM0moCzxs7OXDcQWEdCTaDrwnLGLkYuDWWA5o8Tbve1gCWEBP4nda4+DNbAIqEj8OfYHz OYVcJI49XsKK8RQOYnzx3+CxYUEFCQ6ph9jgqgRlDg58wkLiM0sICFx8MULoBoOoHpuib/d9h MYeWYhqZqFpGoBI9MqRvXi1KKy1CJdQ72kosz0jJLcxMwcXUMDM73c1OLixPTUnMSkYr3k/Nx NjMAAYQCCHYw7nzsdYpTkYFIS5VV0Dw8X4kvKT6nMSCzOiC8qzUktPsQow8GhJMFbYhkRLiRY lJqeWpGWmQMMVZi0BAePkghvN0iat7ggMbc4Mx0idYpRUUqctxYkIQCSyCjNg2uDxcclRlkpY V5GoEOEeApSi3IzS1DlXzGKczAqCfMuAJnCk5lXAjf9FdBiJqDFy4+EgywuSURISTUwVhxi/l 7VtktN57bMlelem8K7G5vevQmYEjgnpO3Ts0tL6lZuu2T3cL1j9gmVd8fSPCf+3xY4f7bwrZn XMg88WJqy+bjCbru2oG2u/svebOYrFp+1X7Nqp+spzqVeAja/aypWFjMveLuH8eTdiVKTT64v MakK3Csp9O1Iw+8DJhZZwd+25GWsuabEUpyRaKjFXFScCABDokNyigIAAA== X-Env-Sender: prvs=960e31256=wei.liu2@citrix.com X-Msg-Ref: server-6.tower-21.messagelabs.com!1465399866!17958961!1 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 8.46; banners=-,-,- X-VirusChecked: Checked Received: (qmail 10533 invoked from network); 8 Jun 2016 15:31:07 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-6.tower-21.messagelabs.com with RC4-SHA encrypted SMTP; 8 Jun 2016 15:31:07 -0000 X-IronPort-AV: E=Sophos;i="5.26,439,1459814400"; d="scan'208";a="366016618" From: Wei Liu To: Xen-devel Date: Wed, 8 Jun 2016 16:31:04 +0100 Message-ID: <1465399864-9711-1-git-send-email-wei.liu2@citrix.com> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 X-DLP: MIA1 Cc: Anthony PERARD , George Dunlap , Ian Jackson , Wei Liu Subject: [Xen-devel] [PATCH for-4.7] Revert "libxl: No emulated disk driver for xvdX disk" X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP This reverts c0c099d157cc5bc942afef766cf141628a6380a1. That commit causes regression on the semantics of our diskspec. See [0] for more information. [0] http://lists.xen.org/archives/html/xen-devel/2016-05/msg02876.html Signed-off-by: Wei Liu Acked-by: Ian Jackson --- Please review carefully about this patch. There are one commit that is of interest: ef6cb76026628e26e3d1ae53c50ccde1c3c78b1b I believe the reverting the snippet in question won't cause security issue as described in XSA-142, because the code to create IDE disk still checks if the disk is read-only. --- tools/libxl/libxl_dm.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/tools/libxl/libxl_dm.c b/tools/libxl/libxl_dm.c index 155a653..6ff05c3 100644 --- a/tools/libxl/libxl_dm.c +++ b/tools/libxl/libxl_dm.c @@ -1422,12 +1422,6 @@ static int libxl__build_device_model_args_new(libxl__gc *gc, format, &disks[i], colo_mode); - } else if (strncmp(disks[i].vdev, "xvd", 3) == 0) { - /* - * Do not add any emulated disk when PV disk are - * explicitly asked for. - */ - continue; } else if (disk < 6 && b_info->u.hvm.hdtype == LIBXL_HDTYPE_AHCI) { if (!disks[i].readwrite) { LOG(ERROR, "qemu-xen doesn't support read-only AHCI disk drivers");