Message ID | 20230713131932.133258-4-ilpo.jarvinen@linux.intel.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a6b2:0:b0:3e4:2afc:c1 with SMTP id c18csp1832355vqm; Thu, 13 Jul 2023 06:40:21 -0700 (PDT) X-Google-Smtp-Source: APBJJlGoL2OUtqwB8L3HgJW7Aizo2gLh4S0Vpqw24CzHVNFZg1dMdI6o6uUBrP5LeVst/+/c9RR+ X-Received: by 2002:a17:906:5194:b0:993:e9b8:90f5 with SMTP id y20-20020a170906519400b00993e9b890f5mr1579111ejk.8.1689255620833; Thu, 13 Jul 2023 06:40:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689255620; cv=none; d=google.com; s=arc-20160816; b=XW1FyQYJxJ5/vtT68uyXR7Pmh2wqQYSmi08mbk0DT9qOyxqXsPMW9W4RGehsuQ+e+k 1JDH1omiRRUaxBsNfhxsMLPtlmwJY44F0GoLxXY/sa0TpmEPEublqHYsa9NIDfdyrDJj XsxksYofQ7B3fJ7hEnnZ5po/ecip8f3Srh+ChmxAT+JXZFwB1vFGYdAeuZncWjzX8UlO 6lX8QBOJ2ABk0RvsvLmhK4R6GmS31C5h2OfzpINu/T+Gg8OcIs2AkDPSKLlQX7GOUXBa W/8+VQ+0gbdXKCOXpkOA205mOcQ/SDBlKngdi5VGSap7OFUlcIH/nqo14YCAK/COI+c2 Y/Wg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=BgA+kVcVkVKzO718h4f1Lpy2XcgF6QzinBo5UZXYTzU=; fh=Ub9PFYMxVygA+0Xpq+fwFd2Pqb8XsEOzK1NyFa5MuDg=; b=eWNCI9ttKfzmlhFO7XKOPMIe0ZE3MbxhHmHFWMz2ukcGAEvjjxZNlN+rCpWYbNN55g KY458YIl4XGiXhUXkm5Q+yQep8GP7zF108BBjWM2L53IYkbPBlf5Vs8HeNH26BG3r2oQ 9FNCIex7XZYYgy+ATi0R91FjxFLztNh2z/bW/4TD4Gg2EMJsXrHOnl3oSjgtq3wzgPZ8 5/nwobzFtCw21Ul0bkyGFML8JsMq9gSwr21XQo2iKTSz/nbWLlOeIwHGiE5EN3r4iglF pa6Lvg44vQS/pDsgu+DRv2HZ0bpl1Q/AlVE9zPqu2FSDLiG1QAeXDzAcFruIhYTARxkU Hu2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=V3b4HCbx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r12-20020a170906350c00b00992169858f2si7580013eja.3.2023.07.13.06.39.56; Thu, 13 Jul 2023 06:40:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=V3b4HCbx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234417AbjGMNU6 (ORCPT <rfc822;ybw1215001957@gmail.com> + 99 others); Thu, 13 Jul 2023 09:20:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51738 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234839AbjGMNUh (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 13 Jul 2023 09:20:37 -0400 Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A7BC830E1; Thu, 13 Jul 2023 06:20:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1689254427; x=1720790427; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=8fEVbocJK76OsCYtzLBWGVMQr0k8AvV/EpnfvvAei/8=; b=V3b4HCbxFRaUoXjeZ1j6rDCl2E7ytiwepYJYyS2gCaZvnBcX33DrYZEJ xhTBrMTgXvAJlPfSTRyjSR8EeUx4VbvKd7SvrsUPilb3lPDJHZfCkckxR Z9jVEWjJe53gq3Sqpn6AOibdOErRFvipd3qcDfBOUtnakZ0CieVeKWX3L 71xfONcWojh3zNLeuwREXnqZ3Cre2jcnZm7WPIYGNIkMCP8ZoJdUVSkHR tiPJckV5jvHiQ9hncLfI2cxAfd1uBa3WPD1DP21Qpij6e2XeOPVcLBf+k DZfNK2X7ieUqkjD2iKFCzkHroqvP/enn8oIpOtxfDQP1cbzTiJ+p+oomh A==; X-IronPort-AV: E=McAfee;i="6600,9927,10770"; a="345496565" X-IronPort-AV: E=Sophos;i="6.01,202,1684825200"; d="scan'208";a="345496565" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jul 2023 06:20:27 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10770"; a="968615719" X-IronPort-AV: E=Sophos;i="6.01,202,1684825200"; d="scan'208";a="968615719" Received: from ijarvine-mobl2.ger.corp.intel.com ([10.251.222.39]) by fmsmga006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jul 2023 06:20:24 -0700 From: =?utf-8?q?Ilpo_J=C3=A4rvinen?= <ilpo.jarvinen@linux.intel.com> To: linux-kselftest@vger.kernel.org, Reinette Chatre <reinette.chatre@intel.com>, Shuah Khan <shuah@kernel.org>, Shaopeng Tan <tan.shaopeng@jp.fujitsu.com>, Fenghua Yu <fenghua.yu@intel.com>, Babu Moger <babu.moger@amd.com>, Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com>, linux-kernel@vger.kernel.org Cc: =?utf-8?q?Ilpo_J=C3=A4rvinen?= <ilpo.jarvinen@linux.intel.com> Subject: [PATCH v4 03/19] selftests/resctrl: Unmount resctrl FS if child fails to run benchmark Date: Thu, 13 Jul 2023 16:19:16 +0300 Message-Id: <20230713131932.133258-4-ilpo.jarvinen@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230713131932.133258-1-ilpo.jarvinen@linux.intel.com> References: <20230713131932.133258-1-ilpo.jarvinen@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771312902038736165 X-GMAIL-MSGID: 1771312902038736165 |
Series |
selftests/resctrl: Fixes and cleanups
|
|
Commit Message
Ilpo Järvinen
July 13, 2023, 1:19 p.m. UTC
A child calls PARENT_EXIT() when it fails to run a benchmark to kill
the parent process. PARENT_EXIT() lacks unmount for the resctrl FS and
the parent won't be there to unmount it either after it gets killed.
Add the resctrl FS unmount also to PARENT_EXIT().
Fixes: 591a6e8588fc ("selftests/resctrl: Add basic resctrl file system operations and data")
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
---
tools/testing/selftests/resctrl/resctrl.h | 1 +
1 file changed, 1 insertion(+)
Comments
Hi Ilpo, On 7/13/2023 6:19 AM, Ilpo Järvinen wrote: > A child calls PARENT_EXIT() when it fails to run a benchmark to kill > the parent process. PARENT_EXIT() lacks unmount for the resctrl FS and > the parent won't be there to unmount it either after it gets killed. > > Add the resctrl FS unmount also to PARENT_EXIT(). > > Fixes: 591a6e8588fc ("selftests/resctrl: Add basic resctrl file system operations and data") > Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Thank you. Reviewed-by: Reinette Chatre <reinette.chatre@intel.com> Reinette
diff --git a/tools/testing/selftests/resctrl/resctrl.h b/tools/testing/selftests/resctrl/resctrl.h index 87e39456dee0..f455f0b7e314 100644 --- a/tools/testing/selftests/resctrl/resctrl.h +++ b/tools/testing/selftests/resctrl/resctrl.h @@ -43,6 +43,7 @@ do { \ perror(err_msg); \ kill(ppid, SIGKILL); \ + umount_resctrlfs(); \ exit(EXIT_FAILURE); \ } while (0)