From patchwork Sat Oct 12 02:10:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinjiang Tu X-Patchwork-Id: 13833390 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 81F32D1A42C for ; Sat, 12 Oct 2024 02:12:04 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E77716B00A4; Fri, 11 Oct 2024 22:12:03 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id DFF486B00A6; Fri, 11 Oct 2024 22:12:03 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CA1296B00A8; Fri, 11 Oct 2024 22:12:03 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id A951D6B00A4 for ; Fri, 11 Oct 2024 22:12:03 -0400 (EDT) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 2E2F5AD0E5 for ; Sat, 12 Oct 2024 02:11:53 +0000 (UTC) X-FDA: 82663324884.11.5040EBF Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by imf27.hostedemail.com (Postfix) with ESMTP id 5AF3340009 for ; Sat, 12 Oct 2024 02:11:56 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf27.hostedemail.com: domain of tujinjiang@huawei.com designates 45.249.212.255 as permitted sender) smtp.mailfrom=tujinjiang@huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1728698983; 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: references; bh=+vPwOjYhKyzvANVcxt42VcszJrRvLYBuPZAoHatJk5U=; b=qvKDB/iXB3nh82xhUo/+jD8O2oximja/mmrxXFfY5v5rg5mwCmv5r0+fgi5dFwQL2KK99H LkSR9SZKkSad4uv/QRTR6AkxrA2lgc1nKgZ1N1Tw3Dztz4YBAzitYjhz9U3iQbybqh3PwK +ireqwGnGx5PkeV0/rYOgRndTf+sYLk= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1728698983; a=rsa-sha256; cv=none; b=W2vtgahMVOO9wV6f/5JBc7LnIgUm+QjYV0TPu8W4aYF82vu4g5Cf8m14MLKS0eV9BLHsH+ 0Acqr2Zf5pzfL3eWF4vWlBv8lcCqL0wJAzPGcmcQ0k4aepWivYx9PhQb6XtAlb8A8/jB2G lCxRAt7PkslzOj8iXU/0yrozZ83A3k8= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf27.hostedemail.com: domain of tujinjiang@huawei.com designates 45.249.212.255 as permitted sender) smtp.mailfrom=tujinjiang@huawei.com Received: from mail.maildlp.com (unknown [172.19.163.174]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4XQRlh5jH6z1T8Xw; Sat, 12 Oct 2024 10:10:08 +0800 (CST) Received: from dggpeml500011.china.huawei.com (unknown [7.185.36.84]) by mail.maildlp.com (Postfix) with ESMTPS id 93639140157; Sat, 12 Oct 2024 10:11:55 +0800 (CST) Received: from huawei.com (10.175.113.32) by dggpeml500011.china.huawei.com (7.185.36.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Sat, 12 Oct 2024 10:11:54 +0800 From: Jinjiang Tu To: , , , , , , CC: , , , Subject: [PATCH -next] selftests: memcg: remove useless code in test_memcg_oom_group_leaf_events Date: Sat, 12 Oct 2024 10:10:57 +0800 Message-ID: <20241012021057.993520-1-tujinjiang@huawei.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Originating-IP: [10.175.113.32] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpeml500011.china.huawei.com (7.185.36.84) X-Rspamd-Queue-Id: 5AF3340009 X-Stat-Signature: 8jrw55iu5pnfz8j6zs8rmhmcbz3mz4uz X-Rspamd-Server: rspam09 X-Rspam-User: X-HE-Tag: 1728699116-855122 X-HE-Meta: U2FsdGVkX18Vunh1CgNo0uYB/7oCG/XvJ+RivkBmpDHKh6Q6VsE7JxD3X/byVjlRNOjNEbteRFuCmoj4wL4rAMzL9yMcz6wVYcrOM2TrXtuf1ErWxHeq/y+uoSCXLFPvyE+I1Jl1g/NeP5xaTOssunLrYmdO7v/R5drPOf5l6Kbb2x26xLAMWFepzsJq6ja459BEYDfS0fh4ERN7YIfjXCcByzb7KDPfDNRmJYG4LI4Ot+NKSeQGq2saSDOf/G2kTI+SRSyUtS82zvhwoDq+AA0rJeJm+4OqRfcz5cdcMNz//mV0XeV/P5hBkensl5vn66ekFGi1ldCHUn/Fu5rAIZH8KUoNBLPv9dRb72WL83gjsKbj2YweUj1alA0UkWJYb/TIo4Y5owUTsxnVxTfkZ+MqI+TSGGVnaD9u4P/dl9AcWNU6hZdkP78Th0snnvXNbg1eEkfUKG8WrpRzqo6zboKq1bbKwc6acWJU9ZGIv0cXi/ZWdutn/BTLg76IYBhmbJdbfVvtS8eeddCTJYUwhWqgICpxyJXWU8AeWavj0hmoNk1ZQqsQpeKn4JD2CO+vcMdg21KdtzqYuRzSv/m+u0XGRWbSFJl+y89tpgKtptm1TDWsT82HO2XjR3246uLYHnsbY5aoJbt24Ir6j5knACJZvDDCmRjy2BMS97jeeOwtYWk0CHlp51okc5vd/Ekdo4o7O9PGzILeQHpL/kNj186DsvBobKbSdSRtaWTcxX9Sl56TimQECO3mJ8ZLuLeJWtnaYzGubP7agINxjGdIM9/s1AeoPi+ZHSvoOWxJRgzTSXniPr4FMlWbffaImMCTCauPcXmX+CZehFTVscWtVatFUgOxMendii+dT3REV2wdatBV9wcQcwGEj4BVViUrTbiY31OYgqH4ySSFtsziiJdOl8JoPL7EMsMYy577f6F1vSh1cwUTNpXAPP+aWexzoKxyWtoIa9z7F2EtXju dayRUn3l 7ZR+NsSKzNdR3UjYALlHFspYy3izN8XpIR+QCS8PFrx/2fZt8SMoSxTFj2LwAy2Yh6Jv48lKfPkU9gXxXoF0n4LQ9ueRqg7UdZUoVMw1s7KmEDBiskkLVRdBWmDS9Z23zKgcFU7DyOF+okACDNOYIRhqikD+rNdlq9/3sXpbL6dOK9VYftJbk8Rmcn+opzKGc6xgv 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: Due to No Internal Process Constraint, parent cgroup couldn't contain any process, the code `cg_run_nowait(parent, ...)` fails to execute and return -1 in fact. So remove the useless code to avoid misunderstanding. Fixes: a987785dcd6c ("Add tests for memory.oom.group") Signed-off-by: Jinjiang Tu --- tools/testing/selftests/cgroup/test_memcontrol.c | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/testing/selftests/cgroup/test_memcontrol.c b/tools/testing/selftests/cgroup/test_memcontrol.c index 16f5d74ae762..1be36cff72a0 100644 --- a/tools/testing/selftests/cgroup/test_memcontrol.c +++ b/tools/testing/selftests/cgroup/test_memcontrol.c @@ -1392,7 +1392,6 @@ static int test_memcg_oom_group_leaf_events(const char *root) if (cg_write(child, "memory.oom.group", "1")) goto cleanup; - cg_run_nowait(parent, alloc_anon_noexit, (void *) MB(60)); cg_run_nowait(child, alloc_anon_noexit, (void *) MB(1)); cg_run_nowait(child, alloc_anon_noexit, (void *) MB(1)); if (!cg_run(child, alloc_anon, (void *)MB(100)))