From patchwork Mon Oct 9 12:09:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 13413530 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B177E95A9D for ; Mon, 9 Oct 2023 12:14:04 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 1B9F18D0067; Mon, 9 Oct 2023 08:14:04 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 0F5818D0031; Mon, 9 Oct 2023 08:14:04 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EBCF48D0067; Mon, 9 Oct 2023 08:14:03 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id D51E58D0031 for ; Mon, 9 Oct 2023 08:14:03 -0400 (EDT) Received: from smtpin13.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id A7881120241 for ; Mon, 9 Oct 2023 12:14:03 +0000 (UTC) X-FDA: 81325814766.13.0E7405B Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by imf05.hostedemail.com (Postfix) with ESMTP id A8FF7100006 for ; Mon, 9 Oct 2023 12:14:01 +0000 (UTC) Authentication-Results: imf05.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=Z5tE8lnm; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf05.hostedemail.com: domain of broonie@kernel.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=broonie@kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1696853641; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=VZa+yVxoJy4ei1p3UG9WfSrCLoFBnIYNn1ZiZhJXbbg=; b=3/P7H9uyIYdk2XhuXY7AFWL9hhbym7Pe/aUsXymiVj3YdoD/4n0lx6faljysqgyeEZF7Vd lO6je251UKemCNBjf8vGIp9Ksf1T5nlILnAkCb4uJpTEk21PiUzjw8gSWDiyHahHQMGptx GZGm7QgY+DFmSKgn8idIerpP7ywmwsI= ARC-Authentication-Results: i=1; imf05.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=Z5tE8lnm; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf05.hostedemail.com: domain of broonie@kernel.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=broonie@kernel.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1696853641; a=rsa-sha256; cv=none; b=l3t1j8P7VOWXaLUQuq/Qfl2odrjG6qEwON8u35CIYjWfnxlCVD5guJrMHL9NEGOqOOQtrH SOpB0tubVFvmOyU8rzRIXDCK3zkzDWIUBmo0KRl4z2/oBD8MDnp8ei+InkJrXIwhn+799W HOtMhgbTtpNLlnZ7Np+omQqkdj7+1hk= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by ams.source.kernel.org (Postfix) with ESMTP id 54CF7B8112C; Mon, 9 Oct 2023 12:14:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D1117C433C9; Mon, 9 Oct 2023 12:13:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1696853640; bh=Go+3eKanODPQVKnV1QnMIrC75/lXwO2PkPnkMfOn2oA=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=Z5tE8lnmdXjuy2FqbmQSDL/utDLHfOoZ4eKkj7w/pFe+3P01nqhLYlWUbu46Kb66T MQggDAPnYeq7fIffhSX2fspIXyhKvHV3fcYzejotBmZFk0/3MKUyi/jRYi5wNt5K+X Oa54ejUABuIC3+Js8winzFrZE+yubCehE6R1fsFaKY82wL9X3leYnlD8DgFEeJC1Wt vRFhGhw4q2GODqA4+lX1CM7HM2u3IvA003ToN+sKy1g4py3QVoI+lxBQqzVi5BRe8B QNxy5na8NSMcK74IKtvdeJxxYDIFj9484A4tWvzdF6gUaaprljtOF3zzC/XcH3gwSs f+M/VlaD8QrCg== From: Mark Brown Date: Mon, 09 Oct 2023 13:09:03 +0100 Subject: [PATCH v6 29/38] kselftest/arm64: Add GCS as a detected feature in the signal tests MIME-Version: 1.0 Message-Id: <20231009-arm64-gcs-v6-29-78e55deaa4dd@kernel.org> References: <20231009-arm64-gcs-v6-0-78e55deaa4dd@kernel.org> In-Reply-To: <20231009-arm64-gcs-v6-0-78e55deaa4dd@kernel.org> To: Catalin Marinas , Will Deacon , Jonathan Corbet , Andrew Morton , Marc Zyngier , Oliver Upton , James Morse , Suzuki K Poulose , Arnd Bergmann , Oleg Nesterov , Eric Biederman , Kees Cook , Shuah Khan , "Rick P. Edgecombe" , Deepak Gupta , Ard Biesheuvel , Szabolcs Nagy Cc: "H.J. Lu" , Paul Walmsley , Palmer Dabbelt , Albert Ou , Florian Weimer , Christian Brauner , linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, kvmarm@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-arch@vger.kernel.org, linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, Mark Brown X-Mailer: b4 0.13-dev-0438c X-Developer-Signature: v=1; a=openpgp-sha256; l=1828; i=broonie@kernel.org; h=from:subject:message-id; bh=Go+3eKanODPQVKnV1QnMIrC75/lXwO2PkPnkMfOn2oA=; b=owEBbQGS/pANAwAKASTWi3JdVIfQAcsmYgBlI+2oIo6FOsWYrBJln/h48RApJUprOroIIr+6v3AC j4QlW3qJATMEAAEKAB0WIQSt5miqZ1cYtZ/in+ok1otyXVSH0AUCZSPtqAAKCRAk1otyXVSH0KBKB/ 4rQ16IAS5wQp6WQY1eD2bS9klRAJX/EGZrEuSxlVT2NgqoWHdyR64Ppf4FG1FKuUqvMND5hTvoNO5r j6KcnXXEnvj1rbqL+4p87ulL7NX44680MNQJqrr2ev8vbbzXgOZpLp8yKaAV+ZTeW3adrfCoHaRd68 4vj9950qxYJkRIpQs3PWHIQl7LTy0wFOhiBvvyeygH8sAlKEce8j/t0SCSj1+irzRPsWT7VolGRuoz 26oZ3vn8jKDTn8gqey9cIe2Kg+tDLrK/FU+K4451nNXAvOqRl7LoBBpIbrg5H0LgHewcu+t0rhnLyW 9vQzfxF+XMWgy4/GxIOBR1MUoAluz0 X-Developer-Key: i=broonie@kernel.org; a=openpgp; fpr=3F2568AAC26998F9E813A1C5C3F436CA30F5D8EB X-Rspam-User: X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: A8FF7100006 X-Stat-Signature: c39x5u1rpkm4c8zmgiu6jdytnxfe4rum X-HE-Tag: 1696853641-659229 X-HE-Meta: U2FsdGVkX1+RKIlNexM6i2Xo/VZk0uOzOg6wU1qgzk2LitmQDVTPMrkrWfHnAZSLTksHeqrHXbnBug61618kcMH2lz5ryaesQ8H99ztn81avyoDfbJ5SWKUppckfWO62ZQYuZ98UposehhwvxaY/16Boq2p3oli+BICP3GTZbKoNe2mmS1X1uz7YoTx2ez8AzMzjD8P7Sw0gLz2L1XzOrpDOX0qxcOWcis6W3yt4XZoCZEciTZP3mxRbSrIde2A4bWZzutZ+KhAnAH7dgr7/tK0QgHT7lhSb5vH0/Uqgjb0RUm40ngpz6a0M1ovTWrthC5GfwawWaBKX0Gk/1QwkTtEYSZnS2ROz/VE786MhYeeqtuu1mDzwnfYakvJaj83j9qZbO4RpwD9s3gYEhAWVPMPQ9YFEbJpWFZUXjHwu4c1GAiZyf94Oy4ZmKFiPtnx7g1T3P4RfqPXrnVl9BJOSf1lAK/w7vV7sdA0oejZIUVGfpNxfD2ctcqf5PrwHFFWdCO+npdEPK7HmgzHTG5+y3Kr4VGrlByqse//6TKNQmcCZEI5ldn9itG4ux5qRgOEO8PRv05UeHHEv8D3ONi/nm5kBLcHLd5o6vR676NeQ6NiBo+WDyIlwRjC9SA0Fz12+rI6CQrS5galL/LuWwoMVzR4AHR5OvjIOQxGRyWafzituaKhQ2ulw8YTqa17KhBr6897mxqt9qKohHNkT7Vqh3XImr9uRnmGb08LcNVi1/oUSd8EzRid+bZij4e3WNIDQXGYhIxLPOM/obrn4OyQ6cLiTajQxU5lvK0CTvMWyBikVZQGV7i5x1btfbwys0YgoZ9HamNFmCTX6nsJTXXWzYEgrN1k28CwE9wq6+E4DpLBT6ZxRHLkenecAH9O3AiNAFxbmcd3JgTIL8xsa1kUwWzHmWjgfk8evdV6PAwsKEYyP1E4ba5KtJtjyd8lRQIBy1yvkSPtoo/RaPiOhfBz nzWs4FMZ Tcm6TvVrnvRhL/pbr4fSlucgKSMn2DSTiDk7u7gRimaFzM4v7ajaFP4EQrHchnr1s9iBnyOqZspYHWnjiXX6aJaGY+nVdahN3+AMXCxDuCUKXL4dNyeZIPN2+HTgsxqq5+JQVaq4+rasFMD8udCFDPcibHGQhV0T778OXr361iLFOotwaMJIOpAAr+GaPxl9EAM4oV1SL6jsj3/aB+YgVMZ945XaUT8zuNJJMml6RAxTNKVyLRdCSpx1ZuRq9/ShrsjIVgrBLHHlpwSkpRn/8oEGO8W0y6VjmgQ+20jxVt2NaCrwBugZMxIT3GA8H6DceWUy4sQOD+yROqZU= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: In preparation for testing GCS related signal handling add it as a feature we check for in the signal handling support code. Signed-off-by: Mark Brown --- tools/testing/selftests/arm64/signal/test_signals.h | 2 ++ tools/testing/selftests/arm64/signal/test_signals_utils.c | 3 +++ 2 files changed, 5 insertions(+) diff --git a/tools/testing/selftests/arm64/signal/test_signals.h b/tools/testing/selftests/arm64/signal/test_signals.h index 1e6273d81575..7ada43688c02 100644 --- a/tools/testing/selftests/arm64/signal/test_signals.h +++ b/tools/testing/selftests/arm64/signal/test_signals.h @@ -35,6 +35,7 @@ enum { FSME_BIT, FSME_FA64_BIT, FSME2_BIT, + FGCS_BIT, FMAX_END }; @@ -43,6 +44,7 @@ enum { #define FEAT_SME (1UL << FSME_BIT) #define FEAT_SME_FA64 (1UL << FSME_FA64_BIT) #define FEAT_SME2 (1UL << FSME2_BIT) +#define FEAT_GCS (1UL << FGCS_BIT) /* * A descriptor used to describe and configure a test case. diff --git a/tools/testing/selftests/arm64/signal/test_signals_utils.c b/tools/testing/selftests/arm64/signal/test_signals_utils.c index 0dc948db3a4a..89ef95c1af0e 100644 --- a/tools/testing/selftests/arm64/signal/test_signals_utils.c +++ b/tools/testing/selftests/arm64/signal/test_signals_utils.c @@ -30,6 +30,7 @@ static char const *const feats_names[FMAX_END] = { " SME ", " FA64 ", " SME2 ", + " GCS ", }; #define MAX_FEATS_SZ 128 @@ -329,6 +330,8 @@ int test_init(struct tdescr *td) td->feats_supported |= FEAT_SME_FA64; if (getauxval(AT_HWCAP2) & HWCAP2_SME2) td->feats_supported |= FEAT_SME2; + if (getauxval(AT_HWCAP2) & HWCAP2_GCS) + td->feats_supported |= FEAT_GCS; if (feats_ok(td)) { if (td->feats_required & td->feats_supported) fprintf(stderr,