From patchwork Wed Apr 12 16:42:18 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Xu X-Patchwork-Id: 82575 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp472490vqo; Wed, 12 Apr 2023 09:56:49 -0700 (PDT) X-Google-Smtp-Source: AKy350ZoWCs1siDZ9+DpV39+5eXnI7tgxUxEGn994Hfq0BKSCGXoK0uJ1XAo8bHo+DMzS/DU95XT X-Received: by 2002:aa7:d919:0:b0:4fa:4b1c:5ea3 with SMTP id a25-20020aa7d919000000b004fa4b1c5ea3mr6053693edr.23.1681318609293; Wed, 12 Apr 2023 09:56:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681318609; cv=none; d=google.com; s=arc-20160816; b=X63S6sdzJp1G/R3v9zhw4V4JDAiKyogUXdapVd2NuX2yMEdGQeT6TMEVVtwqo8JYNu H0J7aw5xYb2flz/ECMzOzJJMwp7moltEyddcAz4xVpHk/3dVjfU0hFNVXVeePj2gOtyW sT/kGGL+BfwttKB7Bf2GMUJJbTU6RUDPrmLTcJMtc87jvpW/PV5cycFpMpBXNJz1v501 NgJZy6NWyRMTnnqfsflGGwDHfzP9ToihSbGEXut55AG9CdF9WwFGtwBPGqW7449s1zxX 2IUnt+OTeuMVYg1RzSJl3sWgu+8sqXD/JS0KTefFnAxWkQRdkmMtEgplu94Ct2Sn29FN JU2g== 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=gGqh0HGkgoECYjM8JfbpdJ2gFcbvM7PfOwSnAOWQ14c=; b=mwQ1a8YCM0iUx0d2ccHss+kCow5yTzsrfK4idXTwUzkc7NEyrFwfr2DYM2CeEbGSUS Lh2m2sWkv5XAH74DpiPjhARjuu3ukdR4aZ0dRddu+S/5s8KIcuNRjJ3WfkD80+vnCRzR ft2jo8WpsdodO3b6o5vkSrceYI/d7bOU30N+OqPATVmQ1cZ4wW3NTOMdQXS/QJ65UoWm JnMtOmKFiaSFUfRWbBPYAfOk/6iuPPdHwtJ/9/D5z9UKxkyliTifADNV+zvCq/EfcmsH 3R7pm/MuGRwD+ZLbNNVKK3K4/57176tlZNXR76mM7h7Asoekt7NMEE0EJvQuLGWB6fCA WFbw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=XG7SZZDV; 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=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z13-20020aa7d40d000000b00504add60b18si6725821edq.532.2023.04.12.09.56.25; Wed, 12 Apr 2023 09:56:49 -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=@redhat.com header.s=mimecast20190719 header.b=XG7SZZDV; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229820AbjDLQnY (ORCPT + 99 others); Wed, 12 Apr 2023 12:43:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39992 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229845AbjDLQnV (ORCPT ); Wed, 12 Apr 2023 12:43:21 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 502468A4F for ; Wed, 12 Apr 2023 09:42:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1681317743; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=gGqh0HGkgoECYjM8JfbpdJ2gFcbvM7PfOwSnAOWQ14c=; b=XG7SZZDV7NPWxthngLwoA6PvfqSU5TZBEeUQeHXyo3Q0gxew8acy1Tovpt0pf0rLYZtiIl yVJtQZ9am5wQpUiIJrVf/ftSACdSpHy42yuisDv7xWol6OhHI8fYGOgx5474SeHufLQSC2 AaODQrumAxFw/m0LMUynpqjomDxsUbY= Received: from mail-qt1-f197.google.com (mail-qt1-f197.google.com [209.85.160.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-602-FeBVkfCMP0W4YjwS14y3sw-1; Wed, 12 Apr 2023 12:42:21 -0400 X-MC-Unique: FeBVkfCMP0W4YjwS14y3sw-1 Received: by mail-qt1-f197.google.com with SMTP id d75a77b69052e-3e69901d854so893931cf.0 for ; Wed, 12 Apr 2023 09:42:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681317740; x=1683909740; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gGqh0HGkgoECYjM8JfbpdJ2gFcbvM7PfOwSnAOWQ14c=; b=LFjsObXzNEcojeVMNC4lxvJgU+wiqwbaDTR8xcRsuKwCGTb3v2ePQChP2JPlLz07tJ haK73+wmXoy/vRJd69ibiilACfHHKDCyvjSo9CXQo/d9xwOvNngbRaLsU64bS007B59W 6fCQTEKJZfg2VlvwwV0685dMOKxHt5HerHnjcXKlGRaCSNo+DRzCGzPirUnNdcgr25nJ ZJ3XMaViUzgnVISWQwZYFnZR5d9Vq5K2Q6ziVMGnp6chP2LB4JS/GtBB1vjjBmrcSenK YUcjEN58XwLth+URq1AX24/5PotphDl3MQJMsHt8xNLorPGuNapXj2RDgN88uJJVWpMN B3bw== X-Gm-Message-State: AAQBX9e6kyKKbpMA38/atBV2NHW/GXXSnzIrBjbsVZjdlHC6yb8mwmLl qXpXqAsac1ZSaT5i8Nw7Pvwoi0d22gWkI4y7VTjiyULOSpLXnXMPHlugv0w5VEt6l6kyoccSipJ Nq8joxIkfppdeChNSCszBlLddCJ5LzIlMXRev18JT9FC7SLQn2tVZC3LKzRnNWSKyttTk8VRp+S 15xKgwhA== X-Received: by 2002:a05:622a:314:b0:3e8:e986:b20b with SMTP id q20-20020a05622a031400b003e8e986b20bmr2585191qtw.6.1681317740330; Wed, 12 Apr 2023 09:42:20 -0700 (PDT) X-Received: by 2002:a05:622a:314:b0:3e8:e986:b20b with SMTP id q20-20020a05622a031400b003e8e986b20bmr2585158qtw.6.1681317740031; Wed, 12 Apr 2023 09:42:20 -0700 (PDT) Received: from x1n.redhat.com (bras-base-aurron9127w-grc-40-70-52-229-124.dsl.bell.ca. [70.52.229.124]) by smtp.gmail.com with ESMTPSA id i18-20020ac860d2000000b003e45a39ed74sm4352477qtm.81.2023.04.12.09.42.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Apr 2023 09:42:19 -0700 (PDT) From: Peter Xu To: linux-kernel@vger.kernel.org, linux-mm@kvack.org Cc: Andrew Morton , Andrea Arcangeli , Mike Kravetz , Nadav Amit , David Hildenbrand , Mike Rapoport , Axel Rasmussen , Leonardo Bras Soares Passos , peterx@redhat.com, Mike Rapoport Subject: [PATCH v2 05/31] selftests/mm: Use TEST_GEN_PROGS where proper Date: Wed, 12 Apr 2023 12:42:18 -0400 Message-Id: <20230412164218.328104-1-peterx@redhat.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230412163922.327282-1-peterx@redhat.com> References: <20230412163922.327282-1-peterx@redhat.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762990342115178025?= X-GMAIL-MSGID: =?utf-8?q?1762990342115178025?= TEST_GEN_PROGS and TEST_GEN_FILES are used randomly in the mm/Makefile to specify programs that need to build. Logically all these binaries should all fall into TEST_GEN_PROGS. Replace those TEST_GEN_FILES with TEST_GEN_PROGS, so that we can reference all the tests easily later. Reviewed-by: David Hildenbrand Reviewed-by: Mike Rapoport (IBM) Signed-off-by: Peter Xu --- tools/testing/selftests/mm/Makefile | 63 +++++++++++++++-------------- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/tools/testing/selftests/mm/Makefile b/tools/testing/selftests/mm/Makefile index 9d9822b4bf24..74988f5adc5f 100644 --- a/tools/testing/selftests/mm/Makefile +++ b/tools/testing/selftests/mm/Makefile @@ -31,35 +31,36 @@ MAKEFLAGS += --no-builtin-rules CFLAGS = -Wall -I $(top_srcdir) $(EXTRA_CFLAGS) $(KHDR_INCLUDES) LDLIBS = -lrt -lpthread -TEST_GEN_FILES = cow -TEST_GEN_FILES += compaction_test -TEST_GEN_FILES += gup_test -TEST_GEN_FILES += hmm-tests -TEST_GEN_FILES += hugetlb-madvise -TEST_GEN_FILES += hugepage-mmap -TEST_GEN_FILES += hugepage-mremap -TEST_GEN_FILES += hugepage-shm -TEST_GEN_FILES += hugepage-vmemmap -TEST_GEN_FILES += khugepaged + +TEST_GEN_PROGS = cow +TEST_GEN_PROGS += compaction_test +TEST_GEN_PROGS += gup_test +TEST_GEN_PROGS += hmm-tests +TEST_GEN_PROGS += hugetlb-madvise +TEST_GEN_PROGS += hugepage-mmap +TEST_GEN_PROGS += hugepage-mremap +TEST_GEN_PROGS += hugepage-shm +TEST_GEN_PROGS += hugepage-vmemmap +TEST_GEN_PROGS += khugepaged TEST_GEN_PROGS = madv_populate -TEST_GEN_FILES += map_fixed_noreplace -TEST_GEN_FILES += map_hugetlb -TEST_GEN_FILES += map_populate -TEST_GEN_FILES += memfd_secret -TEST_GEN_FILES += migration +TEST_GEN_PROGS += map_fixed_noreplace +TEST_GEN_PROGS += map_hugetlb +TEST_GEN_PROGS += map_populate +TEST_GEN_PROGS += memfd_secret +TEST_GEN_PROGS += migration TEST_GEN_PROGS += mkdirty -TEST_GEN_FILES += mlock-random-test -TEST_GEN_FILES += mlock2-tests -TEST_GEN_FILES += mrelease_test -TEST_GEN_FILES += mremap_dontunmap -TEST_GEN_FILES += mremap_test -TEST_GEN_FILES += on-fault-limit -TEST_GEN_FILES += thuge-gen -TEST_GEN_FILES += transhuge-stress -TEST_GEN_FILES += userfaultfd +TEST_GEN_PROGS += mlock-random-test +TEST_GEN_PROGS += mlock2-tests +TEST_GEN_PROGS += mrelease_test +TEST_GEN_PROGS += mremap_dontunmap +TEST_GEN_PROGS += mremap_test +TEST_GEN_PROGS += on-fault-limit +TEST_GEN_PROGS += thuge-gen +TEST_GEN_PROGS += transhuge-stress +TEST_GEN_PROGS += userfaultfd TEST_GEN_PROGS += soft-dirty TEST_GEN_PROGS += split_huge_page_test -TEST_GEN_FILES += ksm_tests +TEST_GEN_PROGS += ksm_tests TEST_GEN_PROGS += ksm_functional_tests TEST_GEN_PROGS += mdwe_test @@ -77,24 +78,24 @@ CFLAGS += -no-pie endif ifeq ($(CAN_BUILD_I386),1) -TEST_GEN_FILES += $(BINARIES_32) +TEST_GEN_PROGS += $(BINARIES_32) endif ifeq ($(CAN_BUILD_X86_64),1) -TEST_GEN_FILES += $(BINARIES_64) +TEST_GEN_PROGS += $(BINARIES_64) endif else ifneq (,$(findstring $(MACHINE),ppc64)) -TEST_GEN_FILES += protection_keys +TEST_GEN_PROGS += protection_keys endif endif ifneq (,$(filter $(MACHINE),arm64 ia64 mips64 parisc64 ppc64 riscv64 s390x sh64 sparc64 x86_64)) -TEST_GEN_FILES += va_128TBswitch -TEST_GEN_FILES += virtual_address_range -TEST_GEN_FILES += write_to_hugetlbfs +TEST_GEN_PROGS += va_128TBswitch +TEST_GEN_PROGS += virtual_address_range +TEST_GEN_PROGS += write_to_hugetlbfs endif TEST_PROGS := run_vmtests.sh