Received: by 2002:a05:7412:bb8d:b0:d7:7d3a:4fe2 with SMTP id js13csp2255420rdb; Thu, 17 Aug 2023 15:58:16 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHbxsd5NKMOT3VUkkvngO5lQtLpXbJFMmsQLOXit7s9dRe51FpZRdAUCVYeupO//oKH8+KI X-Received: by 2002:a05:6a00:22c1:b0:689:f13a:5eb5 with SMTP id f1-20020a056a0022c100b00689f13a5eb5mr1111449pfj.28.1692313096163; Thu, 17 Aug 2023 15:58:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692313096; cv=none; d=google.com; s=arc-20160816; b=c81FsLqviKfNNQ8e4kGpeeMRJiJq1PqXzpks5my4hmo/GyL0S1mUrED9n6FSWE4IyX PNQbUiiXzyQuIsiqdCADDjP31mhoVOY7WRt/pXNxaMgekXTihDoCb63P5jOOPZ+GVrIt 6Oc2tRCe+vvaLVtIY07C/yCW5mkgEeDQIhlizrJlC996G5ArrEt1qHZUiEREBqdOdfer prd8wshKowsssrHRa9bZthf0cSldPKTs2qfKv+bFmfmWy6tQsT6LNzQwAJ3mPg/R3huZ ot0OzeIKJMYnrt1I7/I8TPMdhsmiI7Pi32helGhySWgiarb1JkTz2ADN6LGgXuWpqG97 JDbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=pKc1aLOeFQrGvB+5YIf5i9obwwDTfCsd7+tVkEGuFfo=; fh=quVB3ZCfctWYdbJS2gwgjaMVQR1HbRUCHhAAUTD1W88=; b=xKk5creP5JfV5GZcvLD9Wj6z0MYfZvkSuTpIpVN8m/fNRGwbD1pj/dd6kkO9f1VRIN uSkPm6XrQQjvjM9yASVGx98x9qiPdcXbPoSyDlCzldIAc8vC+n812F73lEnsXt8dd1Ra rFhfmLchKRoJjD/ZxLfnG+7Uc3AihACOrOytd/cRbLMaiiOq5lCTUAs8/eIcwm3KMpef eubcDF2tMdM7Tc3dpVVT6O/Y9mu8SpduDZB4TBlfN5sjGbRvW6p1C1yUpC4tAmrFOXU5 UTmujBv52T9377g7pntqKJVuqJfyje4/kooeXqrXnCUWFV5rb8aKeUH4Nx2AOBYg/sa4 o34Q== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id cq11-20020a056a00330b00b006872ac0a222si404314pfb.100.2023.08.17.15.58.03; Thu, 17 Aug 2023 15:58:16 -0700 (PDT) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1354616AbjHQSyv (ORCPT + 99 others); Thu, 17 Aug 2023 14:54:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48654 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1354649AbjHQSyd (ORCPT ); Thu, 17 Aug 2023 14:54:33 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AC3732727; Thu, 17 Aug 2023 11:54:32 -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 45DCE67760; Thu, 17 Aug 2023 18:54:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 36824C433C8; Thu, 17 Aug 2023 18:54:30 +0000 (UTC) From: Catalin Marinas To: Will Deacon , Oleg Nesterov , Mark Brown Cc: David Spickett , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] arm64/ptrace: Ensure that SME is set up for target when writing SSVE state Date: Thu, 17 Aug 2023 19:54:27 +0100 Message-Id: <169229846427.1184154.14407026846596603141.b4-ty@arm.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230810-arm64-fix-ptrace-race-v1-1-a5361fad2bd6@kernel.org> References: <20230810-arm64-fix-ptrace-race-v1-1-a5361fad2bd6@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,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 On Thu, 10 Aug 2023 12:28:19 +0100, Mark Brown wrote: > When we use NT_ARM_SSVE to either enable streaming mode or change the > vector length for a process we do not currently do anything to ensure that > there is storage allocated for the SME specific register state. If the > task had not previously used SME or we changed the vector length then > the task will not have had TIF_SME set or backing storage for ZA/ZT > allocated, resulting in inconsistent register sizes when saving state > and spurious traps which flush the newly set register state. > > [...] Applied to arm64 (for-next/fixes), thanks! [1/1] arm64/ptrace: Ensure that SME is set up for target when writing SSVE state https://git.kernel.org/arm64/c/5d0a8d2fba50 -- Catalin