Received: by 2002:a05:7412:bc1a:b0:d7:7d3a:4fe2 with SMTP id ki26csp773894rdb; Sun, 20 Aug 2023 02:03:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEp8TbQDez5vJDobQVofU+JfCNQPs5wBgE+Jum13gZ8PuCrbESyBb7ytxcewcpsluc2u/u7 X-Received: by 2002:a05:6a00:4692:b0:68a:2260:c84d with SMTP id de18-20020a056a00469200b0068a2260c84dmr3699075pfb.10.1692522227312; Sun, 20 Aug 2023 02:03:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692522227; cv=none; d=google.com; s=arc-20160816; b=CR7oxBAV77bMk+GBj+jh5T2N0lAxfty5fraHnI3Gf8aADf5b9pMMvSgQ2Fli7WWy6h gg1kgd2W5zDVavuS51qj51W5CvchlXlXghMkVsJWJrGw53KmiGRl/bjQxs4WyUy2bggu onPb0zNXKw9QwUcnYhjkaNs5YBVdftVWQim2ZWUW9CfDl7cU24fK3MNs6mvewGaX0789 Du4qoPRl95UqVSMWHyMIxmqFCnl+EyK4ypoDjYjjvw4llZkU4vH0sFJm4uxS3IFTCwjF Oj9wRlSfnCHtHUnPD3e9AjrzYjHyGthGkPmf59XQ8iGbmL6UQn3c7RxdXKb7Uz2/Tbxf cqzQ== 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=kBNpf6usJkYJxcjcZeAmas/CIm0R7FnTpWgSlB7A0tY=; fh=uN3Q0r4oBnUn8xtaMd5zmZJXTnvmcvdm0XcFkdiLzDQ=; b=It3IUa66VInMzMRvCjGx5SbZtgB2djiYde9KgvYll4c7Lgi/R1UZTfR+y6fQ9Hg6vV OtZfzppvGUxfoyhw6RjVg+etJV0aZmTzomHLeIMvCN5K71P5ClrYi51gK/ynar9LSkbq Kls2lbTZk65PCWUh0xi31XvlhxLHLoBraeRtzc3mnZ5mwmnK/z4cvxQdIwy7IqEwO1it G/HuFrD4jfPzwEWLUFCOgZqNIJDUHJgSONP2/Ku/oNw/4qeWK64EkxUpaRQ2lTmsnDxe me3LdfZ26V/T+1s0M/s09GpYpgH9f9fDnB0nMHAgQGIfiqxY3g3A9sf55rd8LP6ejJhO ka1A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PqWr121x; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id l70-20020a638849000000b005695e8ab459si3273718pgd.174.2023.08.20.02.03.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 20 Aug 2023 02:03:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PqWr121x; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 68A3C24BCB9; Sat, 19 Aug 2023 11:36:49 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343623AbjHPOcT (ORCPT + 99 others); Wed, 16 Aug 2023 10:32:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38452 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343657AbjHPOcH (ORCPT ); Wed, 16 Aug 2023 10:32:07 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 555C82716 for ; Wed, 16 Aug 2023 07:32:03 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id E01186630E for ; Wed, 16 Aug 2023 14:32:02 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id EFB66C433C8; Wed, 16 Aug 2023 14:32:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1692196322; bh=GcEwYp6TztIvoHV57BX8j32YSSYSJBrx3eIgVWF2nqY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=PqWr121xIoP7vi6BlvLBd/qEb9E8WAk2HdhVddrPIhNNgJt7IyXj4ZJj5sFB2B8U+ CqnYgNKOmmtvz6o7yAbT28ObYlrqTJeDeNN/qZC5lw8+c4TvS0XBlz2NinymaF8QBN ghw1Aqfc7RRlhv8g1RN40KzzyqBmAxkB49uCHStKVoyPQhzC+n5k38upYkzpsONnyY K0hF6ytFaZ0tWgljEd06phVIXifpuEcBe4qlQL2V+eTzXGE30/bPjUu4vYN9dV14qP NuA++LIC75rUhmGEQqTzKT6ocRqec76TiAyowXSKU2SSptNWqKv5xioVcT8yJnFrPv jDEyf5ZF4DKqg== Date: Wed, 16 Aug 2023 15:31:57 +0100 From: Mark Brown To: Will Deacon Cc: Catalin Marinas , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, David Spickett Subject: Re: [PATCH] arm64/ptrace: Ensure that the task sees ZT writes on first use Message-ID: References: <20230814-arm64-zt-ptrace-first-use-v1-1-fc8e8022140f@kernel.org> <20230816142219.GA13526@willie-the-truck> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="s4rNUHRjF2KWGoco" Content-Disposition: inline In-Reply-To: <20230816142219.GA13526@willie-the-truck> X-Cookie: Old soldiers never die. Young ones do. X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, 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 --s4rNUHRjF2KWGoco Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Aug 16, 2023 at 03:22:19PM +0100, Will Deacon wrote: > On Mon, Aug 14, 2023 at 10:27:51PM +0100, Mark Brown wrote: > > @@ -1182,6 +1187,8 @@ static int zt_set(struct task_struct *target, > > if (ret =3D=3D 0) > > target->thread.svcr |=3D SVCR_ZA_MASK; > > =20 > > + set_tsk_thread_flag(target, TIF_SME); > Hmm, this is now weirdly inconsistent with za_set(), which doesn't touch > the thread flag unless the regset copy succeeds. Is that intentional? Not particularly, it's just a product of the more complex parsing that ZA needs due to the variable size and optional payload. Either way is fine so long as we allocated the storage but it would be better if they were consistent, I'll update this to match what ZA does. --s4rNUHRjF2KWGoco Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmTc3dwACgkQJNaLcl1U h9AtVgf9HS5c0fIU8LG6aCTVzGi9dcQfpW6cnpakre3AJZCpNHjXZpBOM0Zg6F2A 4ZkPLxjQHzc3NtHxV1cmUq2L1+wGGRdQGQAXRFioQ6wrDPCepA9QYTG+gsn6k2Ba 9Ov7Vtrj0aCCTaWYDlSxECVSFehAnIYmiWKrDiba4FC4m1/uk//9yh5gEmO3Z1P/ YcMC46CH7WQKlDSTJmzgJeeDc7osxd/o0VA34Prt7/POCpmP8F2VrCnQXbL9tQpG 9zXadPU+Hvb8ice3WEU/Uc0z50XIIg/lyfob4Q+XfJL46LM+L+voA2Ae4RhPT0AV +tRQlAiDPBoOZd3/xbKRTuEuUp40+A== =Hdmf -----END PGP SIGNATURE----- --s4rNUHRjF2KWGoco--