Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp2610556rdh; Wed, 27 Sep 2023 07:40:30 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF9wBg5+g1XDHSvDT0V6ECan9OuUDRMgduZUSaUgjfPHuVmipzMM5NFxPVJNCTa+A0eE+yX X-Received: by 2002:a54:4e92:0:b0:3a8:472b:febf with SMTP id c18-20020a544e92000000b003a8472bfebfmr2245127oiy.21.1695825630370; Wed, 27 Sep 2023 07:40:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695825630; cv=none; d=google.com; s=arc-20160816; b=apZakqaBHD120tHQnpkzX5L9mrZv4C7PRVVBiiHZr1Q2Yvg1mZGDe2v5p5miq0vM82 KK6rQY9Y2XfEP8CH4jETrgLv1Exywrzn0+H/g27SIHMar94YX3kTf8esj/k+JKF5yaYu URMzqYuWDmRpGGpaoaG264996D/xNGzYveWntLpZYayNUpXvn9+p7XWikfYjBuptSDRk 4RCyqjJbufat7Munjk+J9U0JAoEZ7+rK8MwwvowGukiBjQ5LptoUNl/3ZlPT3RGxGLy0 LgTzWmC7eHcSk5fcwvbmQlgsqE1M9DrCbO+j0hYvswzvHUgLNx+HpHjoD8WDO1Z4WJwY gSfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:dkim-signature:date; bh=3hbQpc4UesV7IX0JvCrTUx6QA3LAg9gDtHymuaQldZw=; fh=WbkrpF6qxcl6ll7yVPUh84YLj1wCrkpipaDzBCIMAnQ=; b=fAlI2ynqdjVJHUAbyi6ccP2VXL4imXM7cl9rTLbHF/MlNi5gr+fS5mnLuD+BWBPCec XHBDUTiD0e1YEDte7pEjbdDJlk5Ttfvb0+8+IQohbI0z26RkWL9vtNdSC4puslwNY0Vt VGmvPbamPtbyRMk1m/AUsgkWEvcGBr9sJQCsDc6eM3NT2Ue2MTiPaG0idXs/6alMNOc8 1jWAgIJKTJ4eHZ5ogE6BAJ34DMzqhg26WobK3Dx09cxpDnPn/zdSEPRLMPkjGPJyRSyd mBbKQmCM3S59CJTk3RXWygfxY53Q+sgwRS9ZiG1KXv6Jgot7BFsXCguP7w89A5fQZ5Y5 DsNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=eifoM+TF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id s21-20020a056a00179500b0069026254582si16825190pfg.98.2023.09.27.07.40.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 07:40:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=eifoM+TF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 0BEA5802EEE3; Tue, 26 Sep 2023 23:01:36 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229849AbjI0GBb (ORCPT + 99 others); Wed, 27 Sep 2023 02:01:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40652 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229753AbjI0GAy (ORCPT ); Wed, 27 Sep 2023 02:00:54 -0400 Received: from out-191.mta0.migadu.com (out-191.mta0.migadu.com [91.218.175.191]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 89F4B10E9 for ; Tue, 26 Sep 2023 23:00:29 -0700 (PDT) Date: Wed, 27 Sep 2023 06:00:20 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1695794425; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=3hbQpc4UesV7IX0JvCrTUx6QA3LAg9gDtHymuaQldZw=; b=eifoM+TFNp9/h7Xw9Ksm3RmCyTja/wb9Dr3OWTc22KJpHs9wmNbtVeET3FYkloyTu7fIjd E4bRUlHqgYeMPyaiXAUsLVgNAXBqbN2+i4L2JojMXPPPRKd61taTGJJYHyYST+kc+3gprs QgKoQIfrsbwo964baGJO29+Ss2z6v/0= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Oliver Upton To: Kristina Martsenko Cc: kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, Marc Zyngier , James Morse , Suzuki K Poulose , Zenghui Yu , Catalin Marinas , Will Deacon , Vladimir Murzin , Colton Lewis , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 0/2] KVM: arm64: Support for Arm v8.8 memcpy instructions in KVM guests Message-ID: References: <20230922112508.1774352-1-kristina.martsenko@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230922112508.1774352-1-kristina.martsenko@arm.com> X-Migadu-Flow: FLOW_OUT X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Tue, 26 Sep 2023 23:01:36 -0700 (PDT) Hi Kristina, On Fri, Sep 22, 2023 at 12:25:06PM +0100, Kristina Martsenko wrote: > Hi, > > This is v2 of the series to allow using the new Arm memory copy instructions > in KVM guests. See v1 for more information [1]. Thanks for sending out the series. I've been thinking about what the architecture says for MOPS, and I wonder if what's currently in the Arm ARM is clear enough for EL1 software to be written robustly. While HCRX_EL2.MCE2 allows the hypervisor to intervene on MOPS exceptions from EL1, there's no such control for EL0. So when vCPU migration occurs EL1 could get an unexpected MOPS exception, even for a process that was pinned to a single (virtual) CPU implementation. Additionally, the wording of I_NXHPS seems to suggest that EL2 handling of MOPS exceptions is only expected in certain circumstances where EL1 is incapable of handling an exception. Is the unwritten expectation then that EL1 software should tolerate 'unexpected' MOPS exceptions from EL1 and EL0, even if EL1 did not migrate the PE context? Perhaps I'm being pedantic, but I'd really like for there to be some documentation that suggests MOPS exceptions can happen due to context migration done by a higher EL as that is the only option in the context of virtualization. -- Thanks, Oliver