Thread (3 messages) flat view 3 messages, 3 authors, 2017-08-04

Re: [PATCH] uapi: fix another asm/shmbuf.h userspace compilation error

From: Arnd Bergmann <arnd@arndb.de>
Date: 2017-03-02 13:16:46
Also in: linux-alpha, linux-arch, linux-mips, linux-s390, lkml, sparclinux

On Thu, Mar 2, 2017 at 1:46 AM, Dmitry V. Levin [off-list ref] wrote:
Replace size_t with __kernel_size_t to fix asm/shmbuf.h userspace
compilation errors like this:

/usr/include/asm-generic/shmbuf.h:28:2: error: unknown type name 'size_t'
  size_t   shm_segsz; /* size of segment (bytes) */

x32 is the only architecture where sizeof(size_t) is less than
sizeof(__kernel_size_t), but as the kernel treats shm_segsz field as
__kernel_size_t anyway, UAPI should follow.  Thanks to little-endiannes
of x32 and 64-bit alignment of the field following shm_segsz, this
change doesn't break ABI, and the difference doesn't manifest itself
easily.

Signed-off-by: Dmitry V. Levin <redacted>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help