From patchwork Tue May 24 16:29:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Michal_Koutn=C3=BD?= X-Patchwork-Id: 12860368 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 784E2C433EF for ; Tue, 24 May 2022 16:30:23 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id F2C958D0005; Tue, 24 May 2022 12:30:20 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id EB84E8D0001; Tue, 24 May 2022 12:30:20 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id BA3808D0001; Tue, 24 May 2022 12:30:20 -0400 (EDT) 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 9AB638D0005 for ; Tue, 24 May 2022 12:30:20 -0400 (EDT) Received: from smtpin30.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 6D32A348B8 for ; Tue, 24 May 2022 16:30:20 +0000 (UTC) X-FDA: 79501174200.30.207FA3F Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by imf23.hostedemail.com (Postfix) with ESMTP id C79461400E9 for ; Tue, 24 May 2022 16:29:58 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 83F4621A19; Tue, 24 May 2022 16:30:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1653409811; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0aOp5yJI56RJ+SoECoGbDOaEZ7yLii4c891MVbbA4to=; b=vWivk4oDuWVezANW9v3pF+X1FQpt89ke1A10GKiVNLMUJ+jKgPPHySGQopTrxU0imeKFLr k+1ZR6j/nCl9XEAgMYfAPpUpabKowr0uyuLmMwXw0sARrEEeOtbpG4gcmjsoNanvdpJ34L 3mSGJgG0AgCIjZnsfZVZLvG7LV9vDyg= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 435A913ADF; Tue, 24 May 2022 16:30:11 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id Y49RDxMIjWJaWgAAMHmgww (envelope-from ); Tue, 24 May 2022 16:30:11 +0000 From: =?utf-8?q?Michal_Koutn=C3=BD?= To: cgroups@vger.kernel.org, linux-mm@kvack.org Cc: Andrew Morton , Johannes Weiner , Michal Hocko , Roman Gushchin , Shakeel Butt , linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, Richard Palethorpe , Muhammad Usama Anjum Subject: [PATCH v3 0/5] memcontrol selftests fixups Date: Tue, 24 May 2022 18:29:50 +0200 Message-Id: <20220524162955.8635-1-mkoutny@suse.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: C79461400E9 X-Stat-Signature: najdenmkpetmu8wx94zuofjc17hwwm9q Authentication-Results: imf23.hostedemail.com; dkim=pass header.d=suse.com header.s=susede1 header.b=vWivk4oD; spf=pass (imf23.hostedemail.com: domain of mkoutny@suse.com designates 195.135.220.28 as permitted sender) smtp.mailfrom=mkoutny@suse.com; dmarc=pass (policy=quarantine) header.from=suse.com X-Rspam-User: X-HE-Tag: 1653409798-952114 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: Hello. I'm just flushing the patches to make memcontrol selftests check the events behavior we had consensus about (test_memcg_low fails). (test_memcg_reclaim, test_memcg_swap_max fail for me now but it's present even before the refactoring.) The two bigger changes are: - adjustment of the protected values to make tests succeed with the given tolerance, - both test_memcg_low and test_memcg_min check protection of memory in populated cgroups (actually as per Documentation/admin-guide/cgroup-v2.rst memory.min should not apply to empty cgroups, which is not the case currently. Therefore I unified tests with the populated case in order to to bring more broken tests). Thanks, Michal Changes from v2 (https://lore.kernel.org/r/20220518161859.21565-2-mkoutny@suse.com/) - rebased on mm-stable 02e34fff195d3a5f67cbb553795dc109a37d1dcf - collected acked-bys - proper Fixes: tag Changes from v1 (https://lore.kernel.org/r/20220513171811.730-1-mkoutny@suse.com/) - fixed mis-rebase in compilation fix patch, - added review, ack tags from v1, - applied feedback from v1 (Octave script in git tree), - added one more patch extracting common parts, - rebased on mm-stable bbe832b9db2e. Michal Koutný (5): selftests: memcg: Fix compilation selftests: memcg: Expect no low events in unprotected sibling selftests: memcg: Adjust expected reclaim values of protected cgroups selftests: memcg: Remove protection from top level memcg selftests: memcg: Factor out common parts of memory.{low,min} tests MAINTAINERS | 1 + .../selftests/cgroup/memcg_protection.m | 89 +++++++ .../selftests/cgroup/test_memcontrol.c | 247 +++++------------- 3 files changed, 152 insertions(+), 185 deletions(-) create mode 100644 tools/testing/selftests/cgroup/memcg_protection.m Acked-by: Roman Gushchin