From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 DC89A382385; Tue, 21 Jul 2026 22:45:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784673937; cv=none; b=G2IvNrJmhETXAV9786L7por1MQhlBw2G4amZZYAQ4XkWrpd4P9HfYylxApBVwG++w/fRyNdT6PnRiZpzZiOuNl0I7J0pCCaLC3o7SCH1gUK3ROm+lNafoUHFVbjN5xaQHwbiyVzxoPz7lKFk61oIObMLAmU0jgxWC4B+Ev6mEds= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784673937; c=relaxed/simple; bh=YfX0noPw2y6jW4GzPFwKRIm3lQCJbXBPAGLYmpsC0UI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=t2T4zNixwYJ6ByjReCOwUz6CFn7Oap3TwZgPr22QmXiXocg0wxm6a6wCW1XZeI0d09wR3ibJMqX8KtUoe1WFYzasyk4dxxr7e1owY1obRJy/zXyIiYLoiigMdIT3Ggmov/jOTGBHR6Jusm8ooxAAFwZjhi0Te8NRPduMfik1sI4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=n3waJFIr; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="n3waJFIr" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 264FB1F000E9; Tue, 21 Jul 2026 22:45:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784673935; bh=pxNQtaMMx1FMB0Ksz7k7lo6MHfR4iCwx4zctKoWDmPw=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=n3waJFIrQ9y5aOIZRgqsWkbijmOSPl4cT6IRzjMwdTx29xjyR9MhGepBZjmWGTkKq exwzyyxQnkb55B61fT5jY1/Wca7Mc8XgRoDcoVzYLgKnDD22hrbl2UGfoV+eTit6IZ tm4k7sCKcpvUJrn38mbUjd6VP/wmCkdyAiHzCITo= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Sayali Patil , Venkat Rao Bagalkote , "David Hildenbrand (Arm)" , Dev Jain , Liam Howlett , Miaohe Lin , Michal Hocko , Oscar Salvador , "Ritesh Harjani (IBM)" , Shuah Khan , Zi Yan , Andrew Morton , Sasha Levin Subject: [PATCH 5.10 350/699] selftests/mm: clarify alternate unmapping in compaction_test Date: Tue, 21 Jul 2026 17:21:49 +0200 Message-ID: <20260721152403.589061301@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260721152355.667394603@linuxfoundation.org> References: <20260721152355.667394603@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.10-stable review patch. If anyone has any objections, please let me know. ------------------ From: Sayali Patil [ Upstream commit 69ba1d76d93ab818245333cf400928477ba72053 ] Add a comment explaining that every other entry in the list is unmapped to intentionally create fragmentation with locked pages before invoking check_compaction(). Link: https://lore.kernel.org/da5e0a8d5152e54152c0d2f456aac2fac35af291.1779296493.git.sayalip@linux.ibm.com Fixes: bd67d5c15cc1 ("Test compaction of mlocked memory") Signed-off-by: Sayali Patil Tested-by: Venkat Rao Bagalkote Cc: David Hildenbrand (Arm) Cc: Dev Jain Cc: Liam Howlett Cc: Miaohe Lin Cc: Michal Hocko Cc: Oscar Salvador Cc: "Ritesh Harjani (IBM)" Cc: Shuah Khan Cc: Zi Yan Signed-off-by: Andrew Morton Signed-off-by: Sasha Levin --- tools/testing/selftests/vm/compaction_test.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/testing/selftests/vm/compaction_test.c b/tools/testing/selftests/vm/compaction_test.c index 00ebd9d508ffdf..442960f3381dbc 100644 --- a/tools/testing/selftests/vm/compaction_test.c +++ b/tools/testing/selftests/vm/compaction_test.c @@ -231,6 +231,9 @@ int main(int argc, char **argv) mem_fragmentable_MB -= MAP_SIZE_MB; } + /* Unmap every other entry in the list to create fragmentation with + * locked pages before invoking check_compaction(). + */ for (entry = list; entry != NULL; entry = entry->next) { munmap(entry->map, MAP_SIZE); if (!entry->next) -- 2.53.0