public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next v2 0/4] net: uapi: Provide an UAPI definition of 'struct sockaddr'
@ 2026-01-20 14:10 Thomas Weißschuh
  2026-01-20 14:10 ` [PATCH net-next v2 1/4] selftests: net: Move some UAPI header inclusions after libc ones Thomas Weißschuh
                   ` (4 more replies)
  0 siblings, 5 replies; 19+ messages in thread
From: Thomas Weißschuh @ 2026-01-20 14:10 UTC (permalink / raw)
  To: Eric Dumazet, Kuniyuki Iwashima, Paolo Abeni, Willem de Bruijn,
	David S. Miller, Jakub Kicinski, Simon Horman, Shuah Khan,
	Matthieu Baerts, Mat Martineau, Geliang Tang,
	Mickaël Salaün, Günther Noack, Alexei Starovoitov,
	Daniel Borkmann, Jesper Dangaard Brouer, John Fastabend,
	Stanislav Fomichev, Andrii Nakryiko, Martin KaFai Lau,
	Eduard Zingerman, Song Liu, Yonghong Song, KP Singh, Hao Luo,
	Jiri Olsa
  Cc: netdev, linux-kernel, linux-api, Arnd Bergmann, linux-kselftest,
	mptcp, linux-security-module, bpf, libc-alpha,
	Carlos O'Donell, Adhemerval Zanella, Rich Felker, klibc,
	Florian Weimer, Thomas Weißschuh

Various UAPI headers reference 'struct sockaddr'. Currently the
definition of this struct is pulled in from the libc header
sys/socket.h. This is problematic as it introduces a dependency
on a full userspace toolchain.

Add a definition of 'struct sockaddr' to the UAPI headers.
Before that, reorder some problematic header inclusions in the selftests.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
---
Changes in v2:
- Fix compilation failures in BPF samples and selftests
- Link to v1: https://lore.kernel.org/r/20260105-uapi-sockaddr-v1-1-b7653aba12a5@linutronix.de

---
Thomas Weißschuh (4):
      selftests: net: Move some UAPI header inclusions after libc ones
      selftests/landlock: Move some UAPI header inclusions after libc ones
      samples/bpf: Move some UAPI header inclusions after libc ones
      net: uapi: Provide an UAPI definition of 'struct sockaddr'

 include/linux/socket.h                             | 10 ----------
 include/uapi/linux/if.h                            |  4 ----
 include/uapi/linux/libc-compat.h                   | 12 ++++++++++++
 include/uapi/linux/socket.h                        | 14 ++++++++++++++
 samples/bpf/xdp_adjust_tail_user.c                 |  6 ++++--
 samples/bpf/xdp_fwd_user.c                         |  7 ++++---
 samples/bpf/xdp_router_ipv4_user.c                 |  6 +++---
 samples/bpf/xdp_sample_user.c                      | 15 ++++++++-------
 samples/bpf/xdp_tx_iptunnel_user.c                 |  4 ++--
 tools/testing/selftests/landlock/audit.h           |  7 ++++---
 tools/testing/selftests/net/af_unix/diag_uid.c     |  9 +++++----
 tools/testing/selftests/net/busy_poller.c          |  3 ++-
 tools/testing/selftests/net/mptcp/mptcp_diag.c     | 11 ++++++-----
 tools/testing/selftests/net/nettest.c              |  4 ++--
 tools/testing/selftests/net/tcp_ao/icmps-discard.c |  6 +++---
 tools/testing/selftests/net/tcp_ao/lib/netlink.c   |  9 +++++----
 tools/testing/selftests/net/tun.c                  |  5 +++--
 17 files changed, 77 insertions(+), 55 deletions(-)
---
base-commit: 24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7
change-id: 20251222-uapi-sockaddr-cf10e7624729

Best regards,
-- 
Thomas Weißschuh <thomas.weissschuh@linutronix.de>


^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2026-02-09 13:34 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-20 14:10 [PATCH net-next v2 0/4] net: uapi: Provide an UAPI definition of 'struct sockaddr' Thomas Weißschuh
2026-01-20 14:10 ` [PATCH net-next v2 1/4] selftests: net: Move some UAPI header inclusions after libc ones Thomas Weißschuh
2026-01-26 18:13   ` Matthieu Baerts
2026-01-30 10:22     ` Thomas Weißschuh
2026-01-30 10:39       ` Matthieu Baerts
2026-01-20 14:10 ` [PATCH net-next v2 2/4] selftests/landlock: " Thomas Weißschuh
2026-01-20 21:46   ` Mickaël Salaün
2026-01-20 14:10 ` [PATCH net-next v2 3/4] samples/bpf: " Thomas Weißschuh
2026-01-20 14:10 ` [PATCH net-next v2 4/4] net: uapi: Provide an UAPI definition of 'struct sockaddr' Thomas Weißschuh
2026-01-22  3:27 ` [PATCH net-next v2 0/4] " Jakub Kicinski
2026-01-30 10:34   ` Thomas Weißschuh
2026-01-30 16:17     ` Jakub Kicinski
2026-01-31 10:26       ` Thomas Weißschuh
2026-01-31 17:25         ` Jakub Kicinski
2026-02-03 11:42           ` Thomas Weißschuh
2026-02-03 22:40             ` Jakub Kicinski
2026-02-04  5:51               ` Thomas Weißschuh
2026-02-05  1:55                 ` Jakub Kicinski
2026-02-09 13:34                   ` Thomas Weißschuh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox