Skip to content

Commit ad894ac

Browse files
committed
Auto merge of #3140 - sunfishcode:sunfishcode/map-sync-sock-seqpacket, r=JohnTitor
Fix `SOCK_SEQPACKET` and `MAP_SYNC` on musl powerpc and s390. - On powerpc musl, add definitions for `MAP_HUGETLB` and `MAP_SYNC`. - On powerpc64 musl, add a definition for `SOCK_SEQPACKET`. - On s390x musl, add definitions for `SOCK_SEQPACKET` and `MAP_SYNC`. - On mips, just move the existing `MAP_HUGETLB` definition to be near the other `MAP_*` constants.
2 parents 7d6c050 + 70b7015 commit ad894ac

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

src/unix/linux_like/linux/musl/b32/mips/mod.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,7 @@ pub const MAP_NORESERVE: ::c_int = 0x0400;
261261
pub const MAP_POPULATE: ::c_int = 0x10000;
262262
pub const MAP_NONBLOCK: ::c_int = 0x20000;
263263
pub const MAP_STACK: ::c_int = 0x40000;
264+
pub const MAP_HUGETLB: ::c_int = 0x80000;
264265

265266
pub const EDEADLK: ::c_int = 45;
266267
pub const ENAMETOOLONG: ::c_int = 78;
@@ -382,8 +383,6 @@ pub const SIG_UNBLOCK: ::c_int = 2;
382383

383384
pub const EXTPROC: ::tcflag_t = 0o200000;
384385

385-
pub const MAP_HUGETLB: ::c_int = 0x80000;
386-
387386
pub const F_GETLK: ::c_int = 33;
388387
pub const F_GETOWN: ::c_int = 23;
389388
pub const F_SETLK: ::c_int = 34;

src/unix/linux_like/linux/musl/b32/powerpc.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,8 @@ pub const MAP_NORESERVE: ::c_int = 0x00040;
254254
pub const MAP_POPULATE: ::c_int = 0x08000;
255255
pub const MAP_NONBLOCK: ::c_int = 0x010000;
256256
pub const MAP_STACK: ::c_int = 0x020000;
257+
pub const MAP_HUGETLB: ::c_int = 0x040000;
258+
pub const MAP_SYNC: ::c_int = 0x080000;
257259

258260
pub const SOCK_STREAM: ::c_int = 1;
259261
pub const SOCK_DGRAM: ::c_int = 2;

src/unix/linux_like/linux/musl/b64/s390x.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@ pub const MAP_POPULATE: ::c_int = 0x08000;
177177
pub const MAP_NONBLOCK: ::c_int = 0x010000;
178178
pub const MAP_STACK: ::c_int = 0x020000;
179179
pub const MAP_HUGETLB: ::c_int = 0x040000;
180+
pub const MAP_SYNC: ::c_int = 0x080000;
180181

181182
pub const EDEADLOCK: ::c_int = 35;
182183
pub const ENAMETOOLONG: ::c_int = 36;

0 commit comments

Comments
 (0)