Skip to contentSkip to conversation

Why is compat_uid_t a u16 value?

Q Carlos O'Donell 2 participants 2 messages Sep 12, 2004

lore
Share & tools
lore
#0 lore raw

ia64-ml,

The ia32 emulation code is using 'unsigned int' for uid_t returned back to userspace. While the compat.h definitions uses compat_uid_t, which is defined as u16. Is this correct? I would assume that compat_uid_t should be u32 under ia64.

Is there any reason it is currently defined as u16? Is the compat.h definition of compat_uid_t ever used anywhere?

I'm testing some patches to cleanup compat code, but I noticed some discrepancies in the ia64 definitions of compat.h.

Cheers,
Carlos.

#1 lore raw
Quoted 3 lines · Carlos O'Donell

The ia32 emulation code is using 'unsigned int' for uid_t returned back to userspace. While the compat.h definitions uses compat_uid_t, which is defined as u16.

Some older parts of the x86 ABI use a 16-bit UID in places (sysv IPC and stat probably, I didn't check).

Quoted 2 lines

Is this correct? I would assume that compat_uid_t should be u32 under ia64.

Then running applications using the old x86 ABI would break.