162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ 262306a36Sopenharmony_ci#ifndef _ASM_X86_SEMBUF_H 362306a36Sopenharmony_ci#define _ASM_X86_SEMBUF_H 462306a36Sopenharmony_ci 562306a36Sopenharmony_ci#include <asm/ipcbuf.h> 662306a36Sopenharmony_ci 762306a36Sopenharmony_ci/* 862306a36Sopenharmony_ci * The semid64_ds structure for x86 architecture. 962306a36Sopenharmony_ci * Note extra padding because this structure is passed back and forth 1062306a36Sopenharmony_ci * between kernel and user space. 1162306a36Sopenharmony_ci * 1262306a36Sopenharmony_ci * Pad space is left for: 1362306a36Sopenharmony_ci * - 2 miscellaneous 32-bit values 1462306a36Sopenharmony_ci * 1562306a36Sopenharmony_ci * x86_64 and x32 incorrectly added padding here, so the structures 1662306a36Sopenharmony_ci * are still incompatible with the padding on x86. 1762306a36Sopenharmony_ci */ 1862306a36Sopenharmony_cistruct semid64_ds { 1962306a36Sopenharmony_ci struct ipc64_perm sem_perm; /* permissions .. see ipc.h */ 2062306a36Sopenharmony_ci#ifdef __i386__ 2162306a36Sopenharmony_ci unsigned long sem_otime; /* last semop time */ 2262306a36Sopenharmony_ci unsigned long sem_otime_high; 2362306a36Sopenharmony_ci unsigned long sem_ctime; /* last change time */ 2462306a36Sopenharmony_ci unsigned long sem_ctime_high; 2562306a36Sopenharmony_ci#else 2662306a36Sopenharmony_ci __kernel_long_t sem_otime; /* last semop time */ 2762306a36Sopenharmony_ci __kernel_ulong_t __unused1; 2862306a36Sopenharmony_ci __kernel_long_t sem_ctime; /* last change time */ 2962306a36Sopenharmony_ci __kernel_ulong_t __unused2; 3062306a36Sopenharmony_ci#endif 3162306a36Sopenharmony_ci __kernel_ulong_t sem_nsems; /* no. of semaphores in array */ 3262306a36Sopenharmony_ci __kernel_ulong_t __unused3; 3362306a36Sopenharmony_ci __kernel_ulong_t __unused4; 3462306a36Sopenharmony_ci}; 3562306a36Sopenharmony_ci 3662306a36Sopenharmony_ci#endif /* _ASM_X86_SEMBUF_H */ 37