From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS3215 2.6.0.0/16 X-Spam-Status: No, score=-3.8 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 8C33A1F8C6 for ; Tue, 7 Sep 2021 21:30:11 +0000 (UTC) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id B41BC3851C07 for ; Tue, 7 Sep 2021 21:30:10 +0000 (GMT) Received: from esa2.mentor.iphmx.com (esa2.mentor.iphmx.com [68.232.141.98]) by sourceware.org (Postfix) with ESMTPS id 4B9E3385F02C for ; Tue, 7 Sep 2021 21:24:16 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 4B9E3385F02C Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com IronPort-SDR: IaEfuHrfL3Dpp5dMHRBJoGexmKQh1RpU1gSQzoiiQO8gVT5AGD5ZbXV/TjjzQyGdV3NTUPGB+V 0NDp/6Y7CI9AKef087HLF7sVr5wvQ2WYdow4oFzeS/BnQEhnUIstK08yEgWUVGJmslwbnt87jQ 957X9+Ps+opJM3sBLt1bjxghjcE+f6oyMgcnaEoh0QieOuxbfAF3LsUv2wI0SQ5EU81z/ERIfz mJnDy6cEyh28bjwHa4PmMXjisd94tRXvQSHl0vBbCvyUJKcDYnaACBGGo50SgiwhPw5qVMR6RN EP5LVds4Xnji/RqBj3Nd9aWG X-IronPort-AV: E=Sophos;i="5.85,276,1624348800"; d="scan'208";a="65600050" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa2.mentor.iphmx.com with ESMTP; 07 Sep 2021 13:24:15 -0800 IronPort-SDR: N4VQe644Ibst6FLQHQgDQfDng97LuElBWk/0T3beOc2Bo6Y8hkb3/gZfrpFvzrDKvuZhCBnPHk dTz0oPQUNrcPKpaTKVAtSFbsYN/UDoYg8i4PIgK1NbeSF7wpznwhbDdqxtzE2JKbGQ/psSzRBT AHuCOMS3x1hdfkgcoK6r3Ydms1IWom/ONEf1aZitdmMRw+SnrWlubUnKaIkH32F4Wzg4wg80bW 5zP0djSqvtGtVAfoM2MnXkx1ksqVEvBjVWn7hBiLzmTHVZHHD9HrMzkOm9C7CyOFnkslE6W9Kj ME0= Date: Tue, 7 Sep 2021 21:24:10 +0000 From: Joseph Myers X-X-Sender: jsm28@digraph.polyomino.org.uk To: Subject: Add MADV_POPULATE_READ and MADV_POPULATE_WRITE from Linux 5.14 to bits/mman-linux.h Message-ID: User-Agent: Alpine 2.22 (DEB 394 2020-01-19) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: SVR-IES-MBX-04.mgc.mentorg.com (139.181.222.4) To svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+e=80x24.org@sourceware.org Sender: "Libc-alpha" Linux 5.14 adds constants MADV_POPULATE_READ and MADV_POPULATE_WRITE (with the same values on all architectures). Add these to glibc's bits/mman-linux.h. Tested for x86_64. diff --git a/sysdeps/unix/sysv/linux/bits/mman-linux.h b/sysdeps/unix/sysv/linux/bits/mman-linux.h index 3b1ae418e0..31451c28d9 100644 --- a/sysdeps/unix/sysv/linux/bits/mman-linux.h +++ b/sysdeps/unix/sysv/linux/bits/mman-linux.h @@ -89,6 +89,10 @@ # define MADV_KEEPONFORK 19 /* Undo MADV_WIPEONFORK. */ # define MADV_COLD 20 /* Deactivate these pages. */ # define MADV_PAGEOUT 21 /* Reclaim these pages. */ +# define MADV_POPULATE_READ 22 /* Populate (prefault) page tables + readable. */ +# define MADV_POPULATE_WRITE 23 /* Populate (prefault) page tables + writable. */ # define MADV_HWPOISON 100 /* Poison a page for testing. */ #endif -- Joseph S. Myers joseph@codesourcery.com