130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#ifndef __ASM_GENERIC_MSGBUF_H 230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define __ASM_GENERIC_MSGBUF_H 330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng 430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#include <asm/bitsperlong.h> 530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/* 630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * generic msqid64_ds structure. 730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * 830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Note extra padding because this structure is passed back and forth 930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * between kernel and user space. 1030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * 1130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * msqid64_ds was originally meant to be architecture specific, but 1230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * everyone just ended up making identical copies without specific 1330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * optimizations, so we may just as well all use the same one. 1430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * 1530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * 64 bit architectures typically define a 64 bit __kernel_time_t, 1630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * so they do not need the first three padding words. 1730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * On big-endian systems, the padding is in the wrong place. 1830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * 1930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Pad space is left for: 2030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * - 64-bit time_t to solve y2038 problem 2130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * - 2 miscellaneous 32-bit values 2230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */ 2330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng 2430692c65c4174412c90e79489e98ab85c1a7412fBen Chengstruct msqid64_ds { 2530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng struct ipc64_perm msg_perm; 2630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng __kernel_time_t msg_stime; /* last msgsnd time */ 2730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#if __BITS_PER_LONG != 64 2830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng unsigned long __unused1; 2930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#endif 3030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng __kernel_time_t msg_rtime; /* last msgrcv time */ 3130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#if __BITS_PER_LONG != 64 3230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng unsigned long __unused2; 3330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#endif 3430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng __kernel_time_t msg_ctime; /* last change time */ 3530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#if __BITS_PER_LONG != 64 3630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng unsigned long __unused3; 3730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#endif 38e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl __kernel_ulong_t msg_cbytes; /* current number of bytes on queue */ 39e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl __kernel_ulong_t msg_qnum; /* number of messages in queue */ 40e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl __kernel_ulong_t msg_qbytes; /* max number of bytes on queue */ 4130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng __kernel_pid_t msg_lspid; /* pid of last msgsnd */ 4230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng __kernel_pid_t msg_lrpid; /* last receive pid */ 43e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl __kernel_ulong_t __unused4; 44e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl __kernel_ulong_t __unused5; 4530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng}; 4630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng 4730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#endif /* __ASM_GENERIC_MSGBUF_H */ 48