From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 86187CA9EA0 for ; Sun, 20 Oct 2019 10:25:36 +0000 (UTC) Received: from mm01.cs.columbia.edu (mm01.cs.columbia.edu [128.59.11.253]) by mail.kernel.org (Postfix) with ESMTP id 08D89218BA for ; Sun, 20 Oct 2019 10:25:35 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 08D89218BA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvmarm-bounces@lists.cs.columbia.edu Received: from localhost (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 8E7EB4AA46; Sun, 20 Oct 2019 06:25:35 -0400 (EDT) X-Virus-Scanned: at lists.cs.columbia.edu Received: from mm01.cs.columbia.edu ([127.0.0.1]) by localhost (mm01.cs.columbia.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id yAUJqf9YyNmC; Sun, 20 Oct 2019 06:25:34 -0400 (EDT) Received: from mm01.cs.columbia.edu (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 8CDD14AC09; Sun, 20 Oct 2019 06:25:34 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 63FE84AA46 for ; Sun, 20 Oct 2019 06:25:33 -0400 (EDT) X-Virus-Scanned: at lists.cs.columbia.edu Received: from mm01.cs.columbia.edu ([127.0.0.1]) by localhost (mm01.cs.columbia.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FBE1zs38b36m for ; Sun, 20 Oct 2019 06:25:32 -0400 (EDT) Received: from inca-roads.misterjones.org (inca-roads.misterjones.org [213.251.177.50]) by mm01.cs.columbia.edu (Postfix) with ESMTPS id 407D14AA12 for ; Sun, 20 Oct 2019 06:25:32 -0400 (EDT) Received: from 78.163-31-62.static.virginmediabusiness.co.uk ([62.31.163.78] helo=big-swifty.misterjones.org) by cheepnis.misterjones.org with esmtpsa (TLSv1.2:AES256-GCM-SHA384:256) (Exim 4.80) (envelope-from ) id 1iM8Ot-0002G3-V4; Sun, 20 Oct 2019 12:25:29 +0200 Date: Sun, 20 Oct 2019 11:25:24 +0100 Message-ID: <865zkjzpbf.wl-maz@kernel.org> From: Marc Zyngier To: Christoffer Dall Subject: Re: [PATCH v3 0/2] Improve handling of stage 2 aborts without instruction decode In-Reply-To: <20191011110709.2764-1-christoffer.dall@arm.com> References: <20191011110709.2764-1-christoffer.dall@arm.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 EasyPG/1.0.0 Emacs/26 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") X-SA-Exim-Connect-IP: 62.31.163.78 X-SA-Exim-Rcpt-To: christoffer.dall@arm.com, kvmarm@lists.cs.columbia.edu, james.morse@arm.com, julien.thierry.kdev@gmail.com, suzuki.poulose@arm.com, linux-arm-kernel@lists.infradead.org, graf@amazon.com, berrange@redhat.com, xypron.glpk@gmx.de, stefanha@redhat.com, peter.maydell@linaro.org X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on cheepnis.misterjones.org); SAEximRunCond expanded to false Cc: =?UTF-8?B?IkRhbmllbCBQLiBCZXJyYW5nw6ki?= , Heinrich Schuchardt , Stefan Hajnoczi , kvmarm@lists.cs.columbia.edu, linux-arm-kernel@lists.infradead.org X-BeenThere: kvmarm@lists.cs.columbia.edu X-Mailman-Version: 2.1.14 Precedence: list List-Id: Where KVM/ARM decisions are made List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kvmarm-bounces@lists.cs.columbia.edu Sender: kvmarm-bounces@lists.cs.columbia.edu Hi Christoffer, On Fri, 11 Oct 2019 12:07:04 +0100, Christoffer Dall wrote: > > When a guest accesses memory outside the memory slots, KVM usually > bounces the access back to userspace with KVM_EXIT_MMIO. However, on > arm/arm64 systems, certain load/store instructions did not provide > decoding info for the hypervisor to emulate the instruction, and in this > case KVM has rather rudely returned -ENOSYS and printed a not overly > helpful error message: > > load/store instruction decoding not implemented > > This patch series improves the error message and allows userspace to be > notified of this event instead of receiving -ENOSYS, and also allows > userspace to ask KVM to inject an external abort to the guest, which it > can use for any memory access that it either cannot handle. > > One remaining case which this patch set does not address is if the guest > accesses an in-kernel emulated device, such as the VGIC, but using a > load/store instruction which doesn't provide decode info. With these > patches, this will return to userspace for it to handle, but there's no > way for userspace to return the decoding information to KVM and have KVM > complete the access to the in-kernel emulated device. I have no plans > to address this limitation. You had some pending comments on patch 2, and you seem to indicate that you would respin the series. Do you have plans to do so in the coming days? I'd like to put that series into -next, but I can either wait for your respin, or queue it as it is and apply fixes on top. Please let me know what you prefer. Thanks, M. -- Jazz is not dead, it just smells funny. _______________________________________________ kvmarm mailing list kvmarm@lists.cs.columbia.edu https://lists.cs.columbia.edu/mailman/listinfo/kvmarm From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2DE8BCA9EA9 for ; Sun, 20 Oct 2019 10:25:43 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 001D6218BA for ; Sun, 20 Oct 2019 10:25:42 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="DS7w1kc3" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 001D6218BA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Subject:To:From:Message-ID:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=cmENbMgLCdEXb4QiWB83NTJut/oUAc3IEBjwFH7FTd4=; b=DS7w1kc30bVXcp 5L7fSzzznAsQDB1wLtK8SP7+kV9Y3Sk2gD4Ppinrpwgi27tUu8UUej3O0BVtcpIA0LEwFhGn53IO9 LgffoJWc8GKTlEMpXA4j68WXHijjt1xs2oOE8o7VS+MHWbAPCH3YINF8mHnqs3/7+McnvYE3D7Ra9 HdhwL4gSdvrS6o4kbA1J45slNpc0D1mpfHqFRupq0mBzsjhH4ks6dKRloRUTCA3NGOFNpZR/zd5Me 7jKIOEA/FaFHFri7vnBubGfTpIb3o0QLyZ+LTkXQ1QmEUKAT3hYH77XZspB4pqdOTgk5CzyMQ3a4F EwKE1XEImA61zd5qxkOg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iM8P4-0001jW-5T; Sun, 20 Oct 2019 10:25:38 +0000 Received: from inca-roads.misterjones.org ([213.251.177.50]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iM8P1-0001ht-1c for linux-arm-kernel@lists.infradead.org; Sun, 20 Oct 2019 10:25:36 +0000 Received: from 78.163-31-62.static.virginmediabusiness.co.uk ([62.31.163.78] helo=big-swifty.misterjones.org) by cheepnis.misterjones.org with esmtpsa (TLSv1.2:AES256-GCM-SHA384:256) (Exim 4.80) (envelope-from ) id 1iM8Ot-0002G3-V4; Sun, 20 Oct 2019 12:25:29 +0200 Date: Sun, 20 Oct 2019 11:25:24 +0100 Message-ID: <865zkjzpbf.wl-maz@kernel.org> From: Marc Zyngier To: Christoffer Dall Subject: Re: [PATCH v3 0/2] Improve handling of stage 2 aborts without instruction decode In-Reply-To: <20191011110709.2764-1-christoffer.dall@arm.com> References: <20191011110709.2764-1-christoffer.dall@arm.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 EasyPG/1.0.0 Emacs/26 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") X-SA-Exim-Connect-IP: 62.31.163.78 X-SA-Exim-Rcpt-To: christoffer.dall@arm.com, kvmarm@lists.cs.columbia.edu, james.morse@arm.com, julien.thierry.kdev@gmail.com, suzuki.poulose@arm.com, linux-arm-kernel@lists.infradead.org, graf@amazon.com, berrange@redhat.com, xypron.glpk@gmx.de, stefanha@redhat.com, peter.maydell@linaro.org X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on cheepnis.misterjones.org); SAEximRunCond expanded to false X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191020_032535_241170_F01DF93D X-CRM114-Status: GOOD ( 15.20 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell , =?UTF-8?B?IkRhbmllbCBQLiBCZXJyYW5nw6ki?= , Suzuki K Poulose , Heinrich Schuchardt , Alexander Graf , Julien Thierry , Stefan Hajnoczi , James Morse , kvmarm@lists.cs.columbia.edu, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Christoffer, On Fri, 11 Oct 2019 12:07:04 +0100, Christoffer Dall wrote: > > When a guest accesses memory outside the memory slots, KVM usually > bounces the access back to userspace with KVM_EXIT_MMIO. However, on > arm/arm64 systems, certain load/store instructions did not provide > decoding info for the hypervisor to emulate the instruction, and in this > case KVM has rather rudely returned -ENOSYS and printed a not overly > helpful error message: > > load/store instruction decoding not implemented > > This patch series improves the error message and allows userspace to be > notified of this event instead of receiving -ENOSYS, and also allows > userspace to ask KVM to inject an external abort to the guest, which it > can use for any memory access that it either cannot handle. > > One remaining case which this patch set does not address is if the guest > accesses an in-kernel emulated device, such as the VGIC, but using a > load/store instruction which doesn't provide decode info. With these > patches, this will return to userspace for it to handle, but there's no > way for userspace to return the decoding information to KVM and have KVM > complete the access to the in-kernel emulated device. I have no plans > to address this limitation. You had some pending comments on patch 2, and you seem to indicate that you would respin the series. Do you have plans to do so in the coming days? I'd like to put that series into -next, but I can either wait for your respin, or queue it as it is and apply fixes on top. Please let me know what you prefer. Thanks, M. -- Jazz is not dead, it just smells funny. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel