linux-yocto/include
Stefano Garzarella dbcd546400 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 11:01:40 +02:00
..
acpi ACPICA: Avoid sequence overread in call to strncmp() 2025-06-27 11:11:26 +01:00
asm-generic mm: hugetlb: Add huge page size param to huge_ptep_get_and_clear() 2025-03-13 13:02:17 +01:00
clocksource
crypto crypto: ahash - Set default reqsize from ahash_alg 2025-05-29 11:02:40 +02:00
cxl
drm drm/gem: Internally test import_attach for imported objects 2025-05-29 11:03:26 +02:00
dt-bindings
keys
kunit kunit: platform: Resolve 'struct completion' warning 2025-02-21 14:01:25 +01:00
kvm
linux mm/hugetlb: unshare page tables during VMA split, not before 2025-06-27 11:11:40 +01:00
math-emu
media media: v4l: Memset argument to 0 before calling get_mbus_config pad op 2025-05-29 11:02:49 +02:00
memory
misc
net Bluetooth: hci_core: Fix use-after-free in vhci_flush() 2025-07-06 11:01:39 +02:00
pcmcia
ras
rdma RDMA/uverbs: Propagate errors from rdma_lookup_get_uobject() 2025-05-29 11:02:19 +02:00
rv rv: Reset per-task monitors also for idle tasks 2025-02-17 10:05:30 +01:00
scsi
soc soc: qcom: ice: introduce devm_of_qcom_ice_get 2025-05-02 07:58:52 +02:00
sound ALSA: core: fix up bus match const issues. 2025-06-19 15:31:33 +02:00
target
trace erofs: remove unused trace event erofs_destroy_inode 2025-06-27 11:11:40 +01:00
uapi vsock/uapi: fix linux/vm_sockets.h userspace compilation errors 2025-07-06 11:01:40 +02:00
ufs scsi: ufs: Introduce quirk to extend PA_HIBERN8TIME for UFS devices 2025-05-29 11:01:58 +02:00
vdso
video
xen xen/mcelog: Add __nonstring annotations for unterminated strings 2025-04-20 10:15:12 +02:00