From mboxrd@z Thu Jan 1 00:00:00 1970 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 257A9C5478C for ; Tue, 5 Mar 2024 05:49:14 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7A1FB6B007D; Tue, 5 Mar 2024 00:49:13 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 7294A6B0080; Tue, 5 Mar 2024 00:49:13 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 5F0296B0081; Tue, 5 Mar 2024 00:49:13 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 4C0316B007D for ; Tue, 5 Mar 2024 00:49:13 -0500 (EST) Received: from smtpin27.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id C1E138093E for ; Tue, 5 Mar 2024 05:49:12 +0000 (UTC) X-FDA: 81861907344.27.82D1C9A Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) by imf14.hostedemail.com (Postfix) with ESMTP id 1457C100003 for ; Tue, 5 Mar 2024 05:49:09 +0000 (UTC) Authentication-Results: imf14.hostedemail.com; dkim=pass header.d=collabora.com header.s=mail header.b=jJ0V8bya; spf=pass (imf14.hostedemail.com: domain of usama.anjum@collabora.com designates 46.235.227.194 as permitted sender) smtp.mailfrom=usama.anjum@collabora.com; dmarc=pass (policy=quarantine) header.from=collabora.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1709617750; 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=i5Icje+UcpNKSOgrhczbeShW7zQ0cZ/zKpq5I1bUWKc=; b=XrYXNEd4y7O+CZ+TqRao2pQy7mLxtoAs0mUSjuDKqNOqgRQLGY5MINSaBm98yjUMRTr1Ca 4MdlpoWmaghdQ57UtkR2Y6E8OlOaAGQDFhp2INFZNe0wBbT2pxdWepYMwtG9wjulPZHRDB MrEhouoVlLvNVMf1CR0KfKy5GQHGCW8= ARC-Authentication-Results: i=1; imf14.hostedemail.com; dkim=pass header.d=collabora.com header.s=mail header.b=jJ0V8bya; spf=pass (imf14.hostedemail.com: domain of usama.anjum@collabora.com designates 46.235.227.194 as permitted sender) smtp.mailfrom=usama.anjum@collabora.com; dmarc=pass (policy=quarantine) header.from=collabora.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1709617750; a=rsa-sha256; cv=none; b=MnYC4tNqpLbZ+RdbwwCvwTH/Fseq7T5Qokn7PE87SJAkz4ymvsJSPrqW7jtnQgIw57yJcx kgQ191I0MXGNm20/uGGrcsI/WscJpN3ALOR1Zo2T0z2swCIsp2gdt/fj7zS2GMvx63n8Hh XwmSwE5J5WbGxcEA67w/E3GiiL+kCHI= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1709617748; bh=wvRgZJSM1dR6WL3p4B7kWeQbutXl/5mwa20uQCoAsGY=; h=Date:Cc:Subject:To:References:From:In-Reply-To:From; b=jJ0V8byayTEgMZL4kBldTYLQrlEonK+fc6F5TwjUzftk4ghhwqtX6Odj4blpQOVCc GVm5aZZnsop7HOWDKvaPTCeduxiQ6/iGUEaA7f6Ge6HHYbRgz5UllKw4qNQUj7Ilex MhZglMcPzxwFHAoS0VMXJXLqybhZAk3ltu6p/DZygrguHF4jwMslnbY9QMez6eFUQF d7Rlh3jmAhdomIikF7b6HGjm9vA+T7lUZjbyb+eI/LUZnNWA6DsNMIxg9KY5Ul+VBk D6lpnjW/R9yrZx/FDp4yzPucWP7+09N2bue67H1TW9heul5htyJ3dnbAIhtyqdNsSg 923hs3u0p4qeQ== Received: from [10.193.1.1] (broslavsky.collaboradmins.com [68.183.210.73]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: usama.anjum) by madrid.collaboradmins.com (Postfix) with ESMTPSA id A7D4437820CC; Tue, 5 Mar 2024 05:49:04 +0000 (UTC) Message-ID: <2b4cd134-1a90-42aa-ac25-8dc6db5cce27@collabora.com> Date: Tue, 5 Mar 2024 10:49:31 +0500 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Cc: Muhammad Usama Anjum , linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, ben@decadent.org.uk, shuah@kernel.org, akpm@linux-foundation.org Subject: Re: [PATCH] selftests/mm: Dont fail testsuite due to a lack of hugepages To: Nico Pache References: <20240301073300.287508-1-npache@redhat.com> Content-Language: en-US From: Muhammad Usama Anjum In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 1457C100003 X-Rspam-User: X-Stat-Signature: tjjnk7nw37hb44c71ioeouyz3im7c1qo X-Rspamd-Server: rspam01 X-HE-Tag: 1709617749-562110 X-HE-Meta: U2FsdGVkX19dmuN3R6+iZExZkWwQ0TPME8ah6GTsOYXAUCJjs0FDN/QA/Nhckauv0kTjHzZay44XqZqCuXsaG0wcPjo7+tYdm+im149AxhHrgYgKnYOzvdasMPGnLvXtF9QQJBEWlB/zUq1Rk2Jyj4CLoZ5ZpgQehEr1auP0dthW/UyMuiiFU7jzhgJbJe0Rk+tUQtWgIgH7k8jzx84TWozs+pbMaa1dp4ic0ewmd30+3Iz48sJJZarXmzyrnqQq/UOm6u7v4htXdz3gLqduZRIeIBk3FXEB8MfLFDI83sn+Uyp+01eTTvcR6K3Yoj3WminiOSgszaHlD6nhbl4OzrkU9gJiPaATQkFyyBI2p5MZWAFVvqWqAMBs7Chs+t1326lT547ToQaSvGKEBWpQuR7lylkvvaJCvByFmck1IsmhL4oLSL+ye1Y0XhsyQOZPt0uOq53w1YxTn4MEIooawoNLZZ9ep5PkRHeeESVnPuxEGNZzRujIMoYRZ/qiA/iRAm/J9i3ooe7vB7Gxz8xxFbDdUQjesb3UmJ2lHDtjNoQB8kaPvcuCebgm1TSxRzXOfw87ZjbzD3fcELa/b71D7iS6ls7+j1sGGh/oZny2k+pwZCrG9K5vWL3BBP8eJq45YNkUMXLIhbEkGUSke1KXq3ZaK6FFrrwRq6fPCPLhRGjKRI9bcRPMDvciCmxtfRSRI5ibmz5P4AKMPZBXCKYmv/Fa6Nm9Ya68BW6Ay/jSMRCX+HWqjReF+pkVDBX96SUbDWzBD2Lxeo480Oky5eOLQtLtAYp9Ek6K6ZelSW9qi2ayl5vPBayDOpcU/Dhog6POzNz7VKBpU9KOtqY8uLm19XVtXIpzYO0BIJDvcZoBDXDsySILh0fMMmXE/KrXpZLOKwRk3tjfceVGz0dH6e0KSVeFwsgsA5UkP95cwcU3KZHV2u4rHPa/dCoU+tXdfuqb X-Bogosity: Ham, tests=bogofilter, spamicity=0.000001, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On 3/5/24 12:08 AM, Nico Pache wrote: > On Fri, Mar 1, 2024 at 2:35 AM Muhammad Usama Anjum > wrote: >> >> On 3/1/24 12:33 PM, Nico Pache wrote: >>> On systems that have large core counts and large page sizes, but limited >>> memory, the userfaultfd test hugepage requirement is too large. >>> >>> Exiting early due to missing one test's requirements is a rather aggressive >>> strategy, and prevents a lot of other tests from running. Remove the >>> early exit to prevent this. >> Why don't we only skip that particular test which requires huge number of >> pages instead? Thus the behavior of this script would remain same. > Hi Muhammad, > > That would not solve the problem-- The issue is not with the > userfaultfd test, but rather this part of the script that tries to > allocate the hugepages. If it doesnt succeed at allocating the right > amount of hugepages it will exit the run_vmtests.sh script, thus > stopping all other tests. With the `exit` removed, the test suite is > able to run, and upon running the userfaultfd test will result in a > failed test case. > > If you'd like I can follow up with a patch to skip the test cases (in > the actually test) rather than failing. Its just that we don't want failures if there are less number of huge pages available. CI people would mind finding failures. Tests should be updated to skip in those cases then. > > Cheers, > -- Nico >> >>> >>> Fixes: ee00479d6702 ("selftests: vm: Try harder to allocate huge pages") >>> Signed-off-by: Nico Pache >>> --- >>> tools/testing/selftests/mm/run_vmtests.sh | 1 - >>> 1 file changed, 1 deletion(-) >>> >>> diff --git a/tools/testing/selftests/mm/run_vmtests.sh b/tools/testing/selftests/mm/run_vmtests.sh >>> index 246d53a5d7f28..727ea22ba408e 100755 >>> --- a/tools/testing/selftests/mm/run_vmtests.sh >>> +++ b/tools/testing/selftests/mm/run_vmtests.sh >>> @@ -173,7 +173,6 @@ if [ -n "$freepgs" ] && [ -n "$hpgsize_KB" ]; then >>> if [ "$freepgs" -lt "$needpgs" ]; then >>> printf "Not enough huge pages available (%d < %d)\n" \ >>> "$freepgs" "$needpgs" >>> - exit 1 >>> fi >>> else >>> echo "no hugetlbfs support in kernel?" >> >> -- >> BR, >> Muhammad Usama Anjum >> > > -- BR, Muhammad Usama Anjum