linux-yocto/include/uapi
Stefano Garzarella 88c0831d68 vsock/uapi: fix linux/vm_sockets.h userspace compilation errors
[ Upstream commit 22bbc1dcd0 ]

If a userspace application just include <linux/vm_sockets.h> will fail
to build with the following errors:

    /usr/include/linux/vm_sockets.h:182:39: error: invalid application of ‘sizeof’ to incomplete type ‘struct sockaddr’
      182 |         unsigned char svm_zero[sizeof(struct sockaddr) -
          |                                       ^~~~~~
    /usr/include/linux/vm_sockets.h:183:39: error: ‘sa_family_t’ undeclared here (not in a function)
      183 |                                sizeof(sa_family_t) -
          |

Include <sys/socket.h> for userspace (guarded by ifndef __KERNEL__)
where `struct sockaddr` and `sa_family_t` are defined.
We already do something similar in <linux/mptcp.h> and <linux/if.h>.

Fixes: d021c34405 ("VSOCK: Introduce VM Sockets")
Reported-by: Daan De Meyer <daan.j.demeyer@gmail.com>
Signed-off-by: Stefano Garzarella <sgarzare@redhat.com>
Link: https://patch.msgid.link/20250623100053.40979-1-sgarzare@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-07-06 10:58:00 +02:00
..
asm-generic syscalls: fix compat_sys_io_pgetevents_time64 usage 2024-07-05 09:31:59 +02:00
drm drm/amdgpu: handle gfx12 in amdgpu_display_verify_sizes 2024-09-12 11:10:28 +02:00
linux vsock/uapi: fix linux/vm_sockets.h userspace compilation errors 2025-07-06 10:58:00 +02:00
misc
mtd
rdma RDMA/irdma: Allow accurate reporting on QP max send/recv WR 2024-03-26 18:20:53 -04:00
scsi scsi: mpi3mr: Avoid memcpy field-spanning write WARNING 2024-05-17 11:56:04 +02:00
sound ASoC: Intel: Skylake: Fix declaration of enum skl_ch_cfg 2023-05-30 14:03:32 +01:00
video
xen
Kbuild