mirror of
git://git.musl-libc.org/musl
synced 2025-03-06 20:48:29 +01:00
allow archs to define IPC_STAT, propagate time64 bit to other macros
to make use of {sem,shm,msg}ctl IPC_STAT functionality to provide 64-bit time_t on 32-bit archs, IPC_STAT and related macros must be defined with bit 8 (0x100) set. allow archs to define IPC_STAT in bits/ipc.h, and define the other macros in terms of it so that they all get the same value of the time64 bit.
This commit is contained in:
parent
72f50245d0
commit
3c02bacf0f
4 changed files with 8 additions and 6 deletions
|
@ -29,7 +29,9 @@ extern "C" {
|
|||
|
||||
#define IPC_RMID 0
|
||||
#define IPC_SET 1
|
||||
#ifndef IPC_STAT
|
||||
#define IPC_STAT 2
|
||||
#endif
|
||||
#define IPC_INFO 3
|
||||
|
||||
#define IPC_PRIVATE ((key_t) 0)
|
||||
|
|
|
@ -25,9 +25,9 @@ typedef unsigned long msglen_t;
|
|||
#define MSG_NOERROR 010000
|
||||
#define MSG_EXCEPT 020000
|
||||
|
||||
#define MSG_STAT 11
|
||||
#define MSG_STAT (11 | (IPC_STAT & 0x100))
|
||||
#define MSG_INFO 12
|
||||
#define MSG_STAT_ANY 13
|
||||
#define MSG_STAT_ANY (13 | (IPC_STAT & 0x100))
|
||||
|
||||
struct msginfo {
|
||||
int msgpool, msgmap, msgmax, msgmnb, msgmni, msgssz, msgtql;
|
||||
|
|
|
@ -31,9 +31,9 @@ extern "C" {
|
|||
|
||||
#define _SEM_SEMUN_UNDEFINED 1
|
||||
|
||||
#define SEM_STAT 18
|
||||
#define SEM_STAT (18 | (IPC_STAT & 0x100))
|
||||
#define SEM_INFO 19
|
||||
#define SEM_STAT_ANY 20
|
||||
#define SEM_STAT_ANY (20 | (IPC_STAT & 0x100))
|
||||
|
||||
struct seminfo {
|
||||
int semmap;
|
||||
|
|
|
@ -33,9 +33,9 @@ extern "C" {
|
|||
|
||||
#define SHM_LOCK 11
|
||||
#define SHM_UNLOCK 12
|
||||
#define SHM_STAT 13
|
||||
#define SHM_STAT (13 | (IPC_STAT & 0x100))
|
||||
#define SHM_INFO 14
|
||||
#define SHM_STAT_ANY 15
|
||||
#define SHM_STAT_ANY (15 | (IPC_STAT & 0x100))
|
||||
#define SHM_DEST 01000
|
||||
#define SHM_LOCKED 02000
|
||||
#define SHM_HUGETLB 04000
|
||||
|
|
Loading…
Add table
Reference in a new issue