Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp1333199pxm; Thu, 3 Mar 2022 15:29:26 -0800 (PST) X-Google-Smtp-Source: ABdhPJz1HlWxq1qfWK/QGoxxQSZsn8e4/GOaRyZ2+WCBzn76uqGjDxhyZ4Xaz513qAZLCc+vxBnc X-Received: by 2002:a17:907:7f1f:b0:6da:7d72:1352 with SMTP id qf31-20020a1709077f1f00b006da7d721352mr6656480ejc.225.1646350166635; Thu, 03 Mar 2022 15:29:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646350166; cv=none; d=google.com; s=arc-20160816; b=HL2rRFNbU7OGQKVrcHzwF0+3cGGZZrxYR1GiFwCiOtkNlnfrD+u+nTWCtfh7+DJOtr o7KXLCXnK0ZeouXaGVqwJjdB0cMep+ZBIO7edbNyNvCjfylNJTR9j78yb3KgG9P4zXHd hbiYWec0ZIbpyb1aWdOHl4Tq1srcFLr/gDB0CO5o54TcxG4l6LBweYJsf2UaZfGHpvA3 Vw57s04nb5RlNHbn9kmJyLGIhzynNekd/9wb6eNCK8CfSI/cr0DYRqAi1h1UspTSuvYC 8IAvLE5IQ/o99kzgnQpZEGEWZnQDWOqZAYqHcIL6SrKR2rJCyzeivvhJdvLPpT+XOHhF XlrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=ih0JJt97BBLYj6Fn0f3k3bViw991U3vBLG4c2N4VIno=; b=NsxcbdC54MIWcttPROQTvtvUaIHrCX5ggB6Sq8+JhGl4JzVh+4SXUGDJ6bRhqJMS1Z 0CLBrnlsWV7pH/wh2T+kklc48e+tdTNmEaDi6v1LlrW9BYdnL/fCA24kUSnKEVMjfBYU emx3Xsch7oobOclBebmY2K+QTvjX15V4fHV166xleJRg2oCbdUC+jrJdY4kwyUPiYxh/ D8tiyzbOcIH+GV8i+rQgxA2Sh/oi4ybYwTtuJ4ROaEHqAOmTb1rMmCrPJYaYpXWY+tAA GLRmcmBvw9iIhvv0o5CBdnqNaHfXkETKsyODmJMENKPznyyrDGO4OUdLkVnz1Mraxw1D Av+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=google header.b=Pf7u6B9w; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p8-20020a50cd88000000b00413a306e96csi2029583edi.292.2022.03.03.15.29.03; Thu, 03 Mar 2022 15:29:26 -0800 (PST) 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=@linuxfoundation.org header.s=google header.b=Pf7u6B9w; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234856AbiCCV2c (ORCPT + 99 others); Thu, 3 Mar 2022 16:28:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44710 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232855AbiCCV2a (ORCPT ); Thu, 3 Mar 2022 16:28:30 -0500 Received: from mail-io1-xd34.google.com (mail-io1-xd34.google.com [IPv6:2607:f8b0:4864:20::d34]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BF3220F6B for ; Thu, 3 Mar 2022 13:27:43 -0800 (PST) Received: by mail-io1-xd34.google.com with SMTP id u2so5348731ioc.11 for ; Thu, 03 Mar 2022 13:27:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ih0JJt97BBLYj6Fn0f3k3bViw991U3vBLG4c2N4VIno=; b=Pf7u6B9wHbx5Ozd3EXU+1heavGLb89mO4+WtHg+MxHJM7uaFi7TVvEc7m8OxmUOd7X PDHum2XOROhKVlbmwnJ6p4R4fO325YxCEo8Zwn+nSpeNthHHTQvx8pdExlbnGzEYv+6X /R3lrU9fRntHH+wdRb5Tlgp/HD6eIbsc2wHJg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ih0JJt97BBLYj6Fn0f3k3bViw991U3vBLG4c2N4VIno=; b=lFKbPL5/6MuTvJUw3HcL+jDs+qHmDEGrDuNmXhZUHfoIJsOKP0zc4GylNuG/lCxnST qYf3EHeCeF2SZ3USvumSN8BZsBRk3aMTtCSuQnEVvgprsgLC0Qkf4qfeMpkuHs9tVW0D iObz/cSP9a7LW0QFFQU0gM1MDHruW57SCrHl4PDWAARa9j5px9iZvUR7lMnRoo9b7yyH lMM0IiM/PGv0EYp79qR4leYhBs3J1O8HqWKaD489PyrcCFpfM2RTWgQ9kn1gWhDOIkc5 eyLB2Yl45rTnbAAtGQ5lsZBWwGSbPdJdb8Ay99pIoySiNj9MfkB4wzY0YzoWyL59JNy+ bxNw== X-Gm-Message-State: AOAM531kvjZ3nuWGyA40v8yo5hFIfl1HRiZoQXNo9lY/9SsWY3ykfk9B q8pE15DT4ni+4ffCVALhE257qw== X-Received: by 2002:a05:6602:1541:b0:645:7001:8ad1 with SMTP id h1-20020a056602154100b0064570018ad1mr2991689iow.192.1646342862987; Thu, 03 Mar 2022 13:27:42 -0800 (PST) Received: from [192.168.1.128] ([71.205.29.0]) by smtp.gmail.com with ESMTPSA id l1-20020a056e021aa100b002c56271ac39sm3120534ilv.56.2022.03.03.13.27.41 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 03 Mar 2022 13:27:42 -0800 (PST) Subject: Re: [PATCH 2/2] kselftest/vm: fix tests build with old libc To: Chengming Zhou , akpm@linux-foundation.org, shuah@kernel.org Cc: linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, Shuah Khan References: <20220227055330.43087-1-zhouchengming@bytedance.com> <20220227055330.43087-2-zhouchengming@bytedance.com> From: Shuah Khan Message-ID: Date: Thu, 3 Mar 2022 14:27:41 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <20220227055330.43087-2-zhouchengming@bytedance.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,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: X-Mailing-List: linux-kernel@vger.kernel.org On 2/26/22 10:53 PM, Chengming Zhou wrote: > The error message when I build vm tests on debian10 (GLIBC 2.28): > > userfaultfd.c: In function ‘userfaultfd_pagemap_test’: > userfaultfd.c:1393:37: error: ‘MADV_PAGEOUT’ undeclared (first use > in this function); did you mean ‘MADV_RANDOM’? > if (madvise(area_dst, test_pgsize, MADV_PAGEOUT)) > ^~~~~~~~~~~~ > MADV_RANDOM > > This patch includes these newer definitions from UAPI linux/mman.h, > is useful to fix tests build on systems without these definitions in > glibc sys/mman.h. > > Signed-off-by: Chengming Zhou > --- > tools/testing/selftests/vm/userfaultfd.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/tools/testing/selftests/vm/userfaultfd.c b/tools/testing/selftests/vm/userfaultfd.c > index 2f49c9af1b58..3fc1d2ee2948 100644 > --- a/tools/testing/selftests/vm/userfaultfd.c > +++ b/tools/testing/selftests/vm/userfaultfd.c > @@ -46,6 +46,7 @@ > #include > #include > #include > +#include > #include > #include > #include > Looks good to me. Andrew, If you want to take this through your tree or I can apply it. Reviewed-by: Shuah Khan thanks, -- Shuah