Received: by 2002:a05:7412:7c14:b0:fa:6e18:a558 with SMTP id ii20csp445rdb; Sun, 21 Jan 2024 14:32:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IG55mWjmulBpjTfPx/h9leZZWW0nTuT1fyTDtf2j0la8GWTg2HxzB16RrKZJzhC3SVntXr6 X-Received: by 2002:a17:906:a56:b0:a2d:8089:9b85 with SMTP id x22-20020a1709060a5600b00a2d80899b85mr880583ejf.269.1705876326677; Sun, 21 Jan 2024 14:32:06 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705876326; cv=pass; d=google.com; s=arc-20160816; b=GXGgXe6WosMjAmLePNMyIqc5Q2RnBQCulq95eWfztRX2vTkfyitIZrZJXJtJmPvS8p DN7mOsUpQ6+d+az1oQTqOthRlicY3SpOYcTGsYbsmHPFondva+Uh3gMbdf7F2gpYvTSI UdhxQy7Jrr+HtQ/9jIGUtathDG9Dq3M6vcTv/4D1KiYzmt99Rq8/65kK+d4UGWreIGoK wiCX26t2dZNsANkqdQkVj/P6gyAmeAFKXzvTKklujqcmAjvKXG+YAsbps8jiw2S8Mek7 iSVu1MIxxMFHzaFCns5k3T+cubVi/UCZCixdLyr/683J+MUMKqDVP4tIphjG7JnLgDU4 okhw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=bpZHHl7W/YPNyNRX4YmMbRGBfgPEjFVNxyFteww6AMU=; fh=CqNx7Zp7/7EDz3Pjd6TMrUbikDpoQX1K0B5Y7dvqCzU=; b=I4ld1hvNEjGF6fgl2AqYq16t/lih4rWQzOjC91AaZYW2V7uS4PGN+UlBUUtyP6g495 iNxEoQpnxcr+qzIRYGkAw+CX8kE4TNGC8KTqvNJsS6dWL1ng1b92B4RVIVc3Cb7h+J+9 qSdpFfgbcErzvuvJVw0JKWu18x1JZaHvdAIbcVVNQNWWpphcgNcCbGtD5aNFP4+EW53f pNj+Nce01v7r+XznpJ1iWR4N0iAcaLF7bJt2I3kN8UFln9MF+PzjPRL9vkgUu9aKDSTK yDVV7yshaxdxG0MLc7iwhZP9HpwMDMfw+a07T8uuSa9TDzKlZOiNHsp1Spfspz6aepuk 5neg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=x4DdY3Co; arc=pass (i=1 dkim=pass dkdomain=linux-foundation.org); spf=pass (google.com: domain of linux-kernel+bounces-32208-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32208-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id zg22-20020a170907249600b00a2dd18ae684si7098335ejb.74.2024.01.21.14.32.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 21 Jan 2024 14:32:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-32208-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=x4DdY3Co; arc=pass (i=1 dkim=pass dkdomain=linux-foundation.org); spf=pass (google.com: domain of linux-kernel+bounces-32208-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32208-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 538661F21835 for ; Sun, 21 Jan 2024 22:32:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D768438384; Sun, 21 Jan 2024 22:31:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="x4DdY3Co" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EBD8A31A61; Sun, 21 Jan 2024 22:31:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705876318; cv=none; b=jFHB6++frrh14OWbjpkEfu2lk40aRy+dWWZfsOFNilpMkUP8gEIwHXtoHHk1lE2GpUDRIxipaM4CzvMzvF6ffwFRUZXMexfucrGsLuubOa6X5PCULwReFHND23Do0RjhuMsSh5+HgrCkC3iJo6xYjz11GoBARNNcx85Q5H53GHY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705876318; c=relaxed/simple; bh=rkM/sUveJZH/3tT1dW1uZCos4SbkOb6XoszRZAKTad0=; h=Date:From:To:Cc:Subject:Message-Id:In-Reply-To:References: Mime-Version:Content-Type; b=HtpG1QxRQbNv3Ld0jOU29zAvcTFWMzMSA0d97uPyMASKLpKERDiRTox72RPVEh9oPZLr69cy+GMctFkgXGfK6kvHZ71nMSv9lBzOIRPkVtSjsm0Sz0bT9dNUD9ya+vnpCPgim3mdeUNvX59G/RkMEdIgpvVd+YcJIrVSQ2tcrgM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=x4DdY3Co; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 875C4C433F1; Sun, 21 Jan 2024 22:31:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1705876317; bh=rkM/sUveJZH/3tT1dW1uZCos4SbkOb6XoszRZAKTad0=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=x4DdY3Coz92mTQor+OYJ+Gu0tmUhkt3KAOd6xfdJ1+YRk8ff82QKalabBHoyjvGJT T+T1iJNXuJ/h5BCM9brDS7l8l7ef3BIcE39VyQ74274yQ/NZbP62vgezklm57PwJP2 F/nnz7NzHCCben/wdY8WTm4XMTXVtpRUuk1DI4Qo= Date: Sun, 21 Jan 2024 14:31:53 -0800 From: Andrew Morton To: Audra Mitchell Cc: shuah@kernel.org, linux-kselftest@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, raquini@redhat.com, Adam Sindelar Subject: Re: [PATCH] selftests/mm: Update va_high_addr_switch.sh to check CPU for la57 flag Message-Id: <20240121143153.5dcfe26dea53ba0e896dbf85@linux-foundation.org> In-Reply-To: <20240119205801.62769-1-audra@redhat.com> References: <20240119205801.62769-1-audra@redhat.com> X-Mailer: Sylpheed 3.8.0beta1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Fri, 19 Jan 2024 15:58:01 -0500 Audra Mitchell wrote: > In order for the page table level 5 to be in use, the CPU must have the > setting enabled in addition to the CONFIG option. Check for the flag to be > set to avoid false test failures on systems that do not have this cpu flag > set. > Thanks. I'll add Cc: Adam Sindelar Fixes: 4f2930c6718a ("selftests/vm: only run 128TBswitch with 5-level paging") Cc: A more complete description of these "test failures" would be helpful please. > --- a/tools/testing/selftests/mm/va_high_addr_switch.sh > +++ b/tools/testing/selftests/mm/va_high_addr_switch.sh > @@ -29,9 +29,15 @@ check_supported_x86_64() > # See man 1 gzip under '-f'. > local pg_table_levels=$(gzip -dcfq "${config}" | grep PGTABLE_LEVELS | cut -d'=' -f 2) > > + local cpu_supports_pl5=$(awk '/^flags/ {if (/la57/) {print 0;} > + else {print 1}; exit}' /proc/cpuinfo 2>/dev/null) > + > if [[ "${pg_table_levels}" -lt 5 ]]; then > echo "$0: PGTABLE_LEVELS=${pg_table_levels}, must be >= 5 to run this test" > exit $ksft_skip > + elif [[ "${cpu_supports_pl5}" -ne 0 ]]; then > + echo "$0: CPU does not have the necessary la57 flag to support page table level 5" > + exit $ksft_skip > fi > } > > -- > 2.43.0