From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796459641; b=cCA+x794ZLVCLb3y2JeGPsRjPUrGG/YtlgHV1rsvXwo6M3EU3XTdAeZ0HDQdePtzKH5T 2mK7Wzw776D38Q7adc1Eh4K8x35OhDI3Owg4rfLYzbG911/SD/1SFZLs61MnzjoLp5bwl s2vaHauc0lTkLvSiEygMiFVguCdU7fpdRRiqO79dEXAFeau8OH3trh9e4aR+VlND90Qfo 2t34x7+2148uNyLr8SF0ywrxDdDqnu3NO5RDea3DvqEDBtXy1bNyUDuoPwgBz9f+gsKwy PwGDun2Lsn3Hitjw25qNuqi6S37cqvUqR5IwjK2RJMFCr8EzgAknrwz2H98ik7k5UyA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796459641; h=Received:DKIM-Signature:Date:From:To:Cc:Subject:Message-Id: In-Reply-To:References:X-Mailer:Mime-Version:Content-Type: Content-Transfer-Encoding; bh=lE/UL3EDiv7msbXjiVDbM62CMrrFv21GlSCf/gJ0vVE=; b=yEAmGvtyOm8ZSGIqUqL/FqEv6imrrTCByjH4lBmivXiAkTQgLLL3KFwvFxqp2nq7okby HC3qfFBAWtTICezVL6DNudmpf+DiMdIW1C0XZw62P3+KZiJUVcPj5E14eWO1ilB9jOfr+ 6J47fAemiqjvGOmh0nkySEJSMN3+dZPI9Up7uBCqNGmBNUPJ5SRCKDp4uGO+RD1fb/ow1 nRdbG6jcg4697z1wryaQdnnrnFCfejbQDeOM4X2mcZlgeDKRP86O6xMIEN5LEbBDbaZ2j pvUy/RVF8SCR4PMpBQCN5K/HSLhCZwXxCbBNKZrfy8RDXh5U0caKAJpCk4s4O9E0BXw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linux-foundation.org header.i=@linux-foundation.org header.a=rsa-sha256 header.s=korg header.b=uQGU6A3Q; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 27B21606A322; Sat, 5 Dec 2026 08:34:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=linux-foundation.org header.i=@linux-foundation.org header.a=rsa-sha256 header.s=korg header.b=uQGU6A3Q Received: by smtp.kernel.org (Postfix) with ESMTPSA id 582D51F00936; Sat, 5 Dec 2026 08:34:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=korg; t=1796459640; bh=lE/UL3EDiv7msbXjiVDbM62CMrrFv21GlSCf/gJ0vVE=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=uQGU6A3QOmuhp/6l8S1SoDDqvzbLE2bJziyJHxX5B1EC8kDW2MUGAgrcVFXPkqSxD fndTzlAODoclz2Q2CJOZrjo9fdzHD5WXwnG+LdLkBYhn5tNlUmqm8Cgot48xIrT6ri HuZuJr0+Wn1BBUSmX90ysoVpe2dvkuH1qFq8kEpE= Date: Sat, 5 Dec 2026 00:33:59 -0800 From: Andrew Morton To: Kurt Lin Cc: David Hildenbrand , "Liam R. Howlett" , Vlastimil Babka , Mike Rapoport , Michal Hocko , Shuah Khan , Mina Almasry , Sayali Patil , Zi Yan , Song Hu , linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, Li Wang Subject: Re: [PATCH 0/4] selftests/mm: run all hugetlb cgroup reservation tests Message-Id: <20261205003359.261a676af447f5e8d90ef790@linux-foundation.org> In-Reply-To: <20261205-hugetlb-charge-multi-cgroup-v1-0-e88105afc12a@gmail.com> References: <20261205-hugetlb-charge-multi-cgroup-v1-0-e88105afc12a@gmail.com> X-Mailer: Sylpheed 3.8.0beta1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Sat, 05 Dec 2026 01:31:56 +0800 Kurt Lin wrote: > Song's "selftests/mm: restore hidden hugetlb reservation scenarios" was > dropped from mm-unstable because it made the hugetlb category of the > linux-mm CI time out [1]. The time goes into a 60 second wait in the > cases that expect a reservation to fail. As there has been no follow-up, > this series carries Song's patch (3/4, unchanged) behind fixes for that > (1-2/4), and fixes the multiple cgroups test it had to leave skipped > (4/4). That test failed only because of bugs in the script. > > Tested in a virtme-ng guest on mm-new: charge_reserved_hugetlb.sh > -cgroup-v2 passes all 84 checks in about 62 seconds, and > run_vmtests.sh -t hugetlb passes in 87 seconds. It also passes with > KASAN and lockdep on an mm-new that includes David's "mm/hugetlb: > various fixes (2)" v1. argh, this thing. 60 seconds isn't acceptable for a selftest! selftests are to test kernel functionality and nothing else. No stress testing, no performance testing. In, check, out, done. I'll grab these 4 on the grounds that they take the situation from "utterly awful" to merely "really bad", but tokenbot tells me that all this functionality (plus the functionality which the script fails to check) can be tested in about 1 second. > Found and fixed with the help of an AI coding assistant. I told it : That script takes about a minute to run whch is not acceptable for a ; selftest. Selftests are to test kernel fuctionality and nothing else. : No stress tests, no performance tests. : : I want you to figure out what kernel functionality that thing is : testing then propose a replacement C program which tests the same : functionality in a few seconds. Don't write anything yet - just scope : out the work. then : Is there additional related functionality which this script should test : but fails to so do? Result: it's not a trivial project. Numerous design-level decisions must be made which will require understanding of the APIs which are being tested and, in some cases, of their internal implementation details. And the "internal implementation details" part is problematic. Those things can change and we shouldn't implement tests which are designed to match observed current-kernel behavior! The tests should test the interface as we designed it and as we documented it and as we expect userspace to use it. > Not tested with cgroup v1 or other huge page sizes. That would need to change ;)