Skip to content

Commit 149d392

Browse files
authored
Merge pull request #4173 from devnexen/map_droppable_linux
Adding MAP_DROPPABLE for Linux (6.11)
2 parents a8628c3 + 40a4d33 commit 149d392

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

libc-test/build.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4246,6 +4246,9 @@ fn test_linux(target: &str) {
42464246
"EPIOCSPARAMS"
42474247
| "EPIOCGPARAMS" => true,
42484248

4249+
// FIXME: Requires >= 6.11 kernel headers.
4250+
"MAP_DROPPABLE" => true,
4251+
42494252
_ => false,
42504253
}
42514254
});

libc-test/semver/linux.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1586,6 +1586,7 @@ MADV_UNMERGEABLE
15861586
MADV_WILLNEED
15871587
MADV_WIPEONFORK
15881588
MAP_DENYWRITE
1589+
MAP_DROPPABLE
15891590
MAP_EXECUTABLE
15901591
MAP_FILE
15911592
MAP_FIXED_NOREPLACE

src/unix/linux_like/linux/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4767,6 +4767,7 @@ pub const UDP_NO_CHECK6_RX: c_int = 102;
47674767

47684768
// include/uapi/linux/mman.h
47694769
pub const MAP_SHARED_VALIDATE: c_int = 0x3;
4770+
pub const MAP_DROPPABLE: c_int = 0x8;
47704771

47714772
// include/uapi/asm-generic/mman-common.h
47724773
pub const MAP_FIXED_NOREPLACE: c_int = 0x100000;

0 commit comments

Comments
 (0)