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=-5.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 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 55C3DC4742C for ; Mon, 16 Nov 2020 19:46:44 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 E410F2075E for ; Mon, 16 Nov 2020 19:46:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="wyR3f0j2"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="VjNU6UWP" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E410F2075E 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+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=merlin.20170209; h=Sender:Content-Type:Cc: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=tvIouT3BfIltDFwuMhfTOimI8HmJEgHgsasBEbxzwfU=; b=wyR3f0j2xiK7+ZU5q0XcXXUgq bNpW+0zDWyCIWuqvIBs3JYkfh7z+j/S2vjTxI0FAxUFWc7NJXHigaiEndaXx4Ll4qCVdLJZla4YUO 5YcA6NWWrVBiZaKDgC29Oq7sZkx3c4KnX7KrOmUeKJ5310OnkCbH5OjQQ81LoZJ40j7DAyNK5Q+4q rFuS8Bwmzo4BfDXQcrqasxBSpjbMsOe9GToQ2da4bFq1dNJBmUon+Szdp7hzTwsdkMsvH3eoFPpfc usx8p7TZyaPcr8cf2FERrOc6eyQacQ1E+p35FkzW1hXv/IKNBtJBZkZQQYhjlsnmEtsduXDu/b5z0 +5PDPNN9g==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kekS5-0008Cg-T8; Mon, 16 Nov 2020 19:46:13 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kekS3-0008CJ-Pf for linux-arm-kernel@lists.infradead.org; Mon, 16 Nov 2020 19:46:12 +0000 Received: from localhost (fw-tnat.cambridge.arm.com [217.140.96.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2B6DB2075A; Mon, 16 Nov 2020 19:46:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605555970; bh=cFSF3jMuJVO+c65u5u4W5fZlP2oIidi8SuayKipi9Ig=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=VjNU6UWP4Rbm1G9xTbryAoLF9BAk1R/QnrL3NOVzicUJsu38TtRTOIgpvwYkVHXUv uaSx+1CRfw0JTrz8I6SMFToTkY4MoMHGg1yoRMVqGYOOXzGniGLESf1rDwWxwRzb5N gdrdWTLOfKmaCA/ure18H/0haX13xW6JMqC3nWVo= Date: Mon, 16 Nov 2020 19:45:51 +0000 From: Mark Brown To: Dave Martin Subject: Re: [PATCH v5 1/2] arm64/sve: Don't disable SVE on syscalls return Message-ID: <20201116194551.GG4739@sirena.org.uk> References: <20201106193553.22946-1-broonie@kernel.org> <20201106193553.22946-2-broonie@kernel.org> <20201113184855.GF3212@gaia> <20201113201328.GG4828@sirena.org.uk> <20201116175938.GA6882@arm.com> MIME-Version: 1.0 In-Reply-To: <20201116175938.GA6882@arm.com> X-Cookie: Immanuel doesn't pun, he Kant. User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201116_144611_921906_B82848B9 X-CRM114-Status: GOOD ( 18.00 ) 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: Julien Grall , Catalin Marinas , Zhang Lei , Julien Grall , Will Deacon , linux-arm-kernel@lists.infradead.org, Daniel Kiss Content-Type: multipart/mixed; boundary="===============3871255250420331597==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============3871255250420331597== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="eMnpOGXCMazMAbfp" Content-Disposition: inline --eMnpOGXCMazMAbfp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Nov 16, 2020 at 05:59:39PM +0000, Dave Martin wrote: > So far as I can see, TIF_SVE_NEEDS_FLUSH is a special state in which SVE > is half-enabled and the SVE regs half-loaded, so it's not an orthogonal > flag, but a distinct state that sits between the others. > In this state the regs are neither fully saved nor fully loaded, and we > haven't committed to either enabling or disabling SVE for userspace. > It's an intermediate state which we can choose our path out of based on > policy or performance concerns. When I say orthogonal I mean to TIF_SVE only - to me that's essentially unrelated while we're in the kernel. It's true that we'll have to decide if we want to transition on return to userspace but for the time we're in the kernel it doesn't need to interact and we don't need to pay attention to TIF_SVE when we're returning. TIF_FOREIGN_FPSTATE is more tied up, it's definitely can't be thought of as orthogonal. I think of that more like what Catalin was suggesting where it's a flag about where the data is stored rather than about the state we want to go into, which I found makes it fairly easy to reason about. --eMnpOGXCMazMAbfp Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAl+y1u4ACgkQJNaLcl1U h9B/3gf+KxbifRnBBKDkFcwWI0k5948cnIvADmsLY7RZrtSl2OLVA4UOWojD1tqO 1oe4wrSRh5E431fNHic88U2sn5Kszogc/4qexfVvY26zCgIMaooPT/l1QU+U5ABU f8snnNP6WLJKqEH5zOtCVKrh8qBABh/+xILT7BH3xqaWaFy1iqC3Pruu6KolRcid ZbsYAopG7vjOdtHytiLPQ5X7YrCkIrYaUTQB+REaE8p2NX0WRO8lAvoRM9pDBFlQ It9zf/+XhsiUVe2DUPKIjaKdG2VQ+GLFcpTzoB5SAI1KW/e/rH+LvWqQpb3jUMM4 +bOnm5tBkXVycAkllZYIRUYpSPOOHA== =dwra -----END PGP SIGNATURE----- --eMnpOGXCMazMAbfp-- --===============3871255250420331597== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============3871255250420331597==--