Received: by 2002:a05:6358:f14:b0:e5:3b68:ec04 with SMTP id b20csp5729228rwj; Wed, 21 Dec 2022 06:24:41 -0800 (PST) X-Google-Smtp-Source: AMrXdXtDjDF8e12Mj30WDX7H/SuUXxOhiZPxuYfj4NpKwXhQDl3fBIZHVp56AdGOhZ6yFQdaeyft X-Received: by 2002:a05:6a20:3a92:b0:a4:c81c:30ae with SMTP id d18-20020a056a203a9200b000a4c81c30aemr2500161pzh.46.1671632680739; Wed, 21 Dec 2022 06:24:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671632680; cv=none; d=google.com; s=arc-20160816; b=AuUEiriippG3f6rIANsjaSEynfxmXZXXF0GYl/lmP8IciX6Wy5oTe+7IKRiJ26qu75 zCQJsdbA3GOehnQZ5Ztjz+5KyBiq+jxhPs7YekUitMlG1meVzmOrCXgnW/XShvLfun7u wjjLxrjZQX4hZOmIcxPNc67hoVpg5GSAjbRdA0P8KqiwEiuAwj7YMFr0BJLFGomYft6b Tcwm8eO8vVNiOTdYvgtfZ8rCTwIRFVHVDlKTSV1W0+Pz9rR289mKpNtaCahkCY0D2qIp S7E8GcFKL+KDwMCX2JlDdkI4wjOdpJq8a+hjw6tAk0EaTO/VvIKpf9+/f+oPOtAXgUkC JyDw== 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:date:dkim-signature; bh=WqWR0d44+oC0M51OxsJIk5oYzW5Ewe38o6BJGMCz944=; b=QuQvCRFf4TN0n4M5SNadNlCy4OL7Qas0n6QTb9eozOb/YCqN6rZCpNJilVVxcaIcDP 5nsXPyLjrCyFEctQBqkTftVeyuUYd7yp5gAuJ5kvVW+ikNyK1TaE7AwOZbBd2aEKVHyl hbRWt3XvEertgkrif40O+quVsBi2iLVC2r0sOmjezYlQSXowsZw4Sucw+UWTxTOYZssU YmeXcgNYaMWcgN70aiz1QrdzAcwbGo5ROkZxbeGR5bWSpSAlk0ugQpzGUw6h1buXErIa OQ3QJ/xHl7O74G83lqvYGuj0ManhRCqkhZF05OKNE/fx+08GMbwlCDDPmTL8xhgPS5RH 6OhA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=QSN6k2D3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z63-20020a633342000000b0046b3ba2c806si16215244pgz.145.2022.12.21.06.24.29; Wed, 21 Dec 2022 06:24:40 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=QSN6k2D3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231855AbiLUNew (ORCPT + 69 others); Wed, 21 Dec 2022 08:34:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41236 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232209AbiLUNeq (ORCPT ); Wed, 21 Dec 2022 08:34:46 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 248FA19035 for ; Wed, 21 Dec 2022 05:34:46 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id AD2B6617CB for ; Wed, 21 Dec 2022 13:34:45 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5FF18C433F0; Wed, 21 Dec 2022 13:34:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671629685; bh=WqWR0d44+oC0M51OxsJIk5oYzW5Ewe38o6BJGMCz944=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=QSN6k2D3YaVWrsm0u1NnBATOWav1SPvpxVC5Qc3+KeNG4kFYC5BhBlpRUkUuffEHo V7tOKTKpWTi8p82CMsN7tiDvBA34Uc1gR7mMrdwD315dPO5RUP3u85SpQ0++9C9XaO 2jBoCAhOVg/6bnz+J+IrkfN6pKwcqMCBkxJnLjIa+S//8J7fIjJSNTFLO9YbpkprCy hSHebH+WnK21ogAZxqRvkBPiFJRQGgodD3QxNpdDb7As0CjBWyOB/YTyDeIjg7Ahq6 Xv60z9ryBv4gfT4g7hDGD/dYkBebh4LupvK57Dh5AYlcZNaLCVPy71ZI8vvhrX82oa KcjdrPs5K23xg== Date: Wed, 21 Dec 2022 13:34:38 +0000 From: Mark Brown To: Marc Zyngier Cc: Dong Bo , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, kvmarm@lists.cs.columbia.edu, Nianyao Tang , James Morse , Alexandru Elisei , Suzuki K Poulose , Oliver Upton , Catalin Marinas , Will Deacon Subject: Re: [PATCH] KVM: arm64: Synchronize SMEN on vcpu schedule out Message-ID: References: <20221220105024.13484-1-dongbo4@huawei.com> <86v8m6bcuh.wl-maz@kernel.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="X1wLM/v5tW57IqQt" Content-Disposition: inline In-Reply-To: <86v8m6bcuh.wl-maz@kernel.org> X-Cookie: Programming is an unnatural act. X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --X1wLM/v5tW57IqQt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Dec 20, 2022 at 10:15:18AM +0000, Marc Zyngier wrote: > Dong Bo wrote: > > If we have VHE and need to reenable SME for host in > > kvm_arch_vcpu_put_fp, CPACR.SMEN is modified from 0 to 1. Trap > > control for reading SVCR is modified from enable to disable. > > Synchronization is needed before reading SVCR later in > > fpsimd_save, or it may cause sync exception which can not be > > handled by host. Reviewed-by: Mark Brown --X1wLM/v5tW57IqQt Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmOjC24ACgkQJNaLcl1U h9BfMgf/Q43z96bvYnITDmaGHJxEC1F3oW2EdvKLoge3nzDZJTbsZX1jqW5k6Hes vfx8GK+A0zVG6XqyT6MpRm6WIldfEpQwTtvdTDFs1DiY2GEpfQozQKllrquASy9W W3B1UCB90Dv4c519bT3WRCInlUpHRJijyj/m4cijPK4bhLWqVlJXEPJCZ9kZtd3+ zaoOdLKZliZ4qYYe1KydiQO+tBNtSwflYRRfD0taUdpYPjDURuIcGubtuwdOkAqa 4enKZHb2JCUxTuBqOw9ocMglWfRjG+RtRmTdqHap1s0dmP0ywB7v79TBty2HYd7A JcOErjeidYrL4XN6aYR91H1EtqhvKg== =+pAK -----END PGP SIGNATURE----- --X1wLM/v5tW57IqQt--