[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] target/xtensa: linux-user: fix sysv IPC structu
From: |
Max Filippov |
Subject: |
Re: [Qemu-devel] [PATCH] target/xtensa: linux-user: fix sysv IPC structures |
Date: |
Sun, 1 Apr 2018 13:22:54 -0700 |
On Sun, Apr 1, 2018 at 12:57 PM, Laurent Vivier <address@hidden> wrote:
> Le 01/04/2018 à 21:24, Max Filippov a écrit :
>> struct target_shmid_ds {
>> struct target_ipc_perm shm_perm; /* operation permission struct */
>> - abi_int shm_segsz; /* size of segment in bytes */
>> + abi_long shm_segsz; /* size of segment in bytes */
>> +#ifdef TARGET_WORDS_BIGENDIAN
>> + abi_ulong __unused1;
>> abi_long shm_atime; /* time of last shmat() */
>> + abi_ulong __unused2;
>> abi_long shm_dtime; /* time of last shmdt() */
>> + abi_ulong __unused3;
>> abi_long shm_ctime; /* time of last change by shmctl()
>> */
>> - abi_ushort shm_cpid; /* pid of creator */
>> - abi_ushort shm_lpid; /* pid of last shmop */
>> - abi_ushort shm_nattch; /* number of current attaches */
>> - abi_ushort shm_unused; /* compatibility */
>> +#else
>> + abi_long shm_atime; /* time of last shmat() */
>> + abi_ulong __unused1;
>> + abi_long shm_dtime; /* time of last shmdt() */
>> abi_ulong __unused2;
>> + abi_long shm_ctime; /* time of last change by shmctl()
>> */
>> abi_ulong __unused3;
>> +#endif
>> + abi_uint shm_cpid; /* pid of creator */
>> + abi_uint shm_lpid; /* pid of last shmop */
>> + abi_ulong shm_nattch; /* number of current attaches */
>> + abi_ulong __unused4;
>> + abi_ulong __unused5;
>> };
>
> This is weird: shmid64_ds in arch/xtensa/include/uapi/asm/shmbuf.h has
> two part like yours, but both parts have exactly the same fields order.
>
> Could you explain?
Ooops, my bad. I haven't checked how this part works and I guess
the kernel definitions were meant to be different, but alas, they're not.
I'll drop this part.
--
Thanks.
-- Max