From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A88A7C2D0A8 for ; Mon, 28 Sep 2020 20:46:01 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 286902083B for ; Mon, 28 Sep 2020 20:46:00 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=nvidia.com header.i=@nvidia.com header.b="m5IQA3iW" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 286902083B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nvidia.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 4F56A6B005C; Mon, 28 Sep 2020 16:46:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 4A5BD6B005D; Mon, 28 Sep 2020 16:46:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 3BC4E8E0001; Mon, 28 Sep 2020 16:46:00 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0081.hostedemail.com [216.40.44.81]) by kanga.kvack.org (Postfix) with ESMTP id 26C466B005C for ; Mon, 28 Sep 2020 16:46:00 -0400 (EDT) Received: from smtpin20.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id D7F6D181AE864 for ; Mon, 28 Sep 2020 20:45:59 +0000 (UTC) X-FDA: 77313652038.20.wheel14_0702b1627184 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin20.hostedemail.com (Postfix) with ESMTP id B67AB180C07A3 for ; Mon, 28 Sep 2020 20:45:59 +0000 (UTC) X-HE-Tag: wheel14_0702b1627184 X-Filterd-Recvd-Size: 4081 Received: from hqnvemgate24.nvidia.com (hqnvemgate24.nvidia.com [216.228.121.143]) by imf33.hostedemail.com (Postfix) with ESMTP for ; Mon, 28 Sep 2020 20:45:58 +0000 (UTC) Received: from hqmail.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate24.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Mon, 28 Sep 2020 13:44:18 -0700 Received: from [10.2.53.30] (10.124.1.5) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Mon, 28 Sep 2020 20:45:57 +0000 Subject: Re: [PATCH 8/8] selftests/vm: hmm-tests: remove the libhugetlbfs dependency From: John Hubbard To: Jason Gunthorpe CC: Andrew Morton , Jonathan Corbet , =?UTF-8?B?SsOpcsO0bWUgR2xpc3Nl?= , Ralph Campbell , Shuah Khan , LKML , , , , References: <20200928062159.923212-1-jhubbard@nvidia.com> <20200928062159.923212-9-jhubbard@nvidia.com> <20200928130245.GQ9916@ziepe.ca> <982fd9bf-64cb-00e9-f092-13849c7cf7d9@nvidia.com> Message-ID: Date: Mon, 28 Sep 2020 13:45:57 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 In-Reply-To: <982fd9bf-64cb-00e9-f092-13849c7cf7d9@nvidia.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.124.1.5] X-ClientProxiedBy: HQMAIL111.nvidia.com (172.20.187.18) To HQMAIL107.nvidia.com (172.20.187.13) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1601325858; bh=ZNzUuJga0yAMPUYJp+Mbsk5gWocHn8PGlFF35AeQU6M=; h=Subject:From:To:CC:References:Message-ID:Date:User-Agent: MIME-Version:In-Reply-To:Content-Type:Content-Language: Content-Transfer-Encoding:X-Originating-IP:X-ClientProxiedBy; b=m5IQA3iWGf+mZlD+saPKKaP+GSN4PkecL44skN/WMfHCWeNk37hDn5PMtercS3tK6 Lp2QQuHA9Xj/xMMew2SGfA2kmICe2T0+C2xOut+GVKNp7iBo9QVJ+B6ZTiCBWwct88 T8nBnsGvpfQ0Tv2rc+csXV/eiQOABg6g4J0ThvAIFFQIAE/Gs9RyB7niQarYyAe+HZ QUn0TG+3k8nyf5xQHK59lujZJH/Y3S5qtFqWhA6+9CnsqRq0d9y3dntQbiaKDZ7p1n uq8HRKBsBnaiNvulGdhSjuQVJLSLijDk44AC0NT7oB/9lsTgiZ52taQi/N8J9UtfH5 WACzwgevzothA== 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: On 9/28/20 1:18 PM, John Hubbard wrote: > On 9/28/20 6:02 AM, Jason Gunthorpe wrote: >> On Sun, Sep 27, 2020 at 11:21:59PM -0700, John Hubbard wrote: > ... >>> +gcc -c $tmpfile_c -o $tmpfile_o >/dev/null 2>&1 >> >> This gcc has to come from some makefile variable I plan on posting a v2 with this additional change, to fix the above point: diff --git a/tools/testing/selftests/vm/Makefile b/tools/testing/selftests/vm/Makefile index 986a90fa9653..019cbb7f3cf8 100644 --- a/tools/testing/selftests/vm/Makefile +++ b/tools/testing/selftests/vm/Makefile @@ -138,7 +138,7 @@ $(OUTPUT)/hmm-tests: local_config.h $(OUTPUT)/hmm-tests: LDLIBS += $(HMM_EXTRA_LIBS) local_config.mk local_config.h: check_config.sh - ./check_config.sh + ./check_config.sh $(CC) EXTRA_CLEAN += local_config.mk local_config.h diff --git a/tools/testing/selftests/vm/check_config.sh b/tools/testing/selftests/vm/check_config.sh index 651a4b192479..079c8a40b85d 100755 --- a/tools/testing/selftests/vm/check_config.sh +++ b/tools/testing/selftests/vm/check_config.sh @@ -16,7 +16,8 @@ echo "#include " > $tmpfile_c echo "#include " >> $tmpfile_c echo "int func(void) { return 0; }" >> $tmpfile_c -gcc -c $tmpfile_c -o $tmpfile_o >/dev/null 2>&1 +CC=${1:?"Usage: $0 # example compiler: gcc"} +$CC -c $tmpfile_c -o $tmpfile_o >/dev/null 2>&1 if [ -f $tmpfile_o ]; then echo "#define LOCAL_CONFIG_HAVE_LIBHUGETLBFS 1" > $OUTPUT_H_FILE thanks, -- John Hubbard NVIDIA