aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-04-11 08:36:30 -0400
committerTakashi Iwai <tiwai@suse.de>2019-04-11 08:36:30 -0400
commit9b0dcd0e5a27958b57e3e390f63c098d63a055da (patch)
treede778d683f121d3062df316994e9c4cf195eb12c /include/uapi
parentd7a181da2dfa3190487c446042ba01e07d851c74 (diff)
parentac71317e6be01812cc0c54d8be6d3c1139c8380b (diff)
Merge tag 'asoc-fix-v5.1-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Fixes for v5.1 A few core fixes along with the driver specific ones, mainly fixing small issues that only affect x86 platforms for various reasons (their unusual machine enumeration mechanisms mainly, plus a fix for error handling in topology). There's some of the driver fixes that look larger than they are, like the hdmi-codec changes which resulted in an indentation change, and most of the other large changes are for new drivers like the STM32 changes.
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/asm-generic/Kbuild (renamed from include/uapi/asm-generic/Kbuild.asm)4
-rw-r--r--include/uapi/asm-generic/mman-common.h4
-rw-r--r--include/uapi/asm-generic/socket.h50
-rw-r--r--include/uapi/asm-generic/unistd.h158
-rw-r--r--include/uapi/drm/amdgpu_drm.h9
-rw-r--r--include/uapi/drm/drm_fourcc.h63
-rw-r--r--include/uapi/drm/i915_drm.h64
-rw-r--r--include/uapi/drm/nouveau_drm.h51
-rw-r--r--include/uapi/drm/v3d_drm.h8
-rw-r--r--include/uapi/linux/android/binder.h19
-rw-r--r--include/uapi/linux/auto_fs.h2
-rw-r--r--include/uapi/linux/batadv_packet.h4
-rw-r--r--include/uapi/linux/batman_adv.h192
-rw-r--r--include/uapi/linux/binfmts.h2
-rw-r--r--include/uapi/linux/bpf.h116
-rw-r--r--include/uapi/linux/btrfs.h2
-rw-r--r--include/uapi/linux/devlink.h47
-rw-r--r--include/uapi/linux/dm-ioctl.h4
-rw-r--r--include/uapi/linux/elf.h2
-rw-r--r--include/uapi/linux/errqueue.h5
-rw-r--r--include/uapi/linux/ethtool.h35
-rw-r--r--include/uapi/linux/fanotify.h29
-rw-r--r--include/uapi/linux/fcntl.h1
-rw-r--r--include/uapi/linux/fuse.h7
-rw-r--r--include/uapi/linux/icmpv6.h2
-rw-r--r--include/uapi/linux/if_bonding.h24
-rw-r--r--include/uapi/linux/if_link.h1
-rw-r--r--include/uapi/linux/igmp.h1
-rw-r--r--include/uapi/linux/iio/types.h7
-rw-r--r--include/uapi/linux/in.h9
-rw-r--r--include/uapi/linux/in6.h1
-rw-r--r--include/uapi/linux/io_uring.h137
-rw-r--r--include/uapi/linux/kernel-page-flags.h2
-rw-r--r--include/uapi/linux/limits.h4
-rw-r--r--include/uapi/linux/lirc.h6
-rw-r--r--include/uapi/linux/mdio.h19
-rw-r--r--include/uapi/linux/mman.h4
-rw-r--r--include/uapi/linux/mroute.h9
-rw-r--r--include/uapi/linux/mroute6.h9
-rw-r--r--include/uapi/linux/ndctl.h1
-rw-r--r--include/uapi/linux/netfilter/nf_tables.h19
-rw-r--r--include/uapi/linux/nl80211.h44
-rw-r--r--include/uapi/linux/nvme_ioctl.h9
-rw-r--r--include/uapi/linux/pci_regs.h2
-rw-r--r--include/uapi/linux/perf_event.h55
-rw-r--r--include/uapi/linux/pkt_cls.h58
-rw-r--r--include/uapi/linux/pkt_sched.h3
-rw-r--r--include/uapi/linux/pmu.h2
-rw-r--r--include/uapi/linux/prctl.h1
-rw-r--r--include/uapi/linux/rds.h11
-rw-r--r--include/uapi/linux/sctp.h4
-rw-r--r--include/uapi/linux/serial_core.h3
-rw-r--r--include/uapi/linux/tc_act/tc_bpf.h2
-rw-r--r--include/uapi/linux/tc_act/tc_connmark.h2
-rw-r--r--include/uapi/linux/tc_act/tc_csum.h2
-rw-r--r--include/uapi/linux/tc_act/tc_gact.h1
-rw-r--r--include/uapi/linux/tc_act/tc_ife.h1
-rw-r--r--include/uapi/linux/tc_act/tc_ipt.h3
-rw-r--r--include/uapi/linux/tc_act/tc_mirred.h1
-rw-r--r--include/uapi/linux/tc_act/tc_nat.h2
-rw-r--r--include/uapi/linux/tc_act/tc_pedit.h2
-rw-r--r--include/uapi/linux/tc_act/tc_sample.h2
-rw-r--r--include/uapi/linux/tc_act/tc_skbedit.h2
-rw-r--r--include/uapi/linux/tc_act/tc_skbmod.h2
-rw-r--r--include/uapi/linux/tc_act/tc_tunnel_key.h2
-rw-r--r--include/uapi/linux/tc_act/tc_vlan.h2
-rw-r--r--include/uapi/linux/time.h29
-rw-r--r--include/uapi/linux/time_types.h36
-rw-r--r--include/uapi/linux/timex.h39
-rw-r--r--include/uapi/linux/tls.h19
-rw-r--r--include/uapi/linux/v4l2-controls.h2
-rw-r--r--include/uapi/linux/videodev2.h26
-rw-r--r--include/uapi/linux/xdp_diag.h72
-rw-r--r--include/uapi/misc/fastrpc.h41
-rw-r--r--include/uapi/misc/habanalabs.h450
-rw-r--r--include/uapi/mtd/ubi-user.h5
-rw-r--r--include/uapi/rdma/bnxt_re-abi.h11
-rw-r--r--include/uapi/rdma/ib_user_verbs.h2
-rw-r--r--include/uapi/rdma/mlx5_user_ioctl_cmds.h18
-rw-r--r--include/uapi/rdma/mlx5_user_ioctl_verbs.h5
-rw-r--r--include/uapi/rdma/rdma_netlink.h74
-rw-r--r--include/uapi/rdma/rdma_user_cm.h4
-rw-r--r--include/uapi/rdma/rdma_user_rxe.h3
83 files changed, 2003 insertions, 184 deletions
diff --git a/include/uapi/asm-generic/Kbuild.asm b/include/uapi/asm-generic/Kbuild
index 355c4ac2c0b0..ebb180aac74e 100644
--- a/include/uapi/asm-generic/Kbuild.asm
+++ b/include/uapi/asm-generic/Kbuild
@@ -1,6 +1,8 @@
1# SPDX-License-Identifier: GPL-2.0
1# 2#
2# Headers that are mandatory in usr/include/asm/ 3# Headers that are mandatory in usr/include/asm/
3# 4# (This file is not included when SRCARCH=um since UML does not support UAPI.)
5
4mandatory-y += auxvec.h 6mandatory-y += auxvec.h
5mandatory-y += bitsperlong.h 7mandatory-y += bitsperlong.h
6mandatory-y += bpf_perf_event.h 8mandatory-y += bpf_perf_event.h
diff --git a/include/uapi/asm-generic/mman-common.h b/include/uapi/asm-generic/mman-common.h
index e7ee32861d51..abd238d0f7a4 100644
--- a/include/uapi/asm-generic/mman-common.h
+++ b/include/uapi/asm-generic/mman-common.h
@@ -15,9 +15,7 @@
15#define PROT_GROWSDOWN 0x01000000 /* mprotect flag: extend change to start of growsdown vma */ 15#define PROT_GROWSDOWN 0x01000000 /* mprotect flag: extend change to start of growsdown vma */
16#define PROT_GROWSUP 0x02000000 /* mprotect flag: extend change to end of growsup vma */ 16#define PROT_GROWSUP 0x02000000 /* mprotect flag: extend change to end of growsup vma */
17 17
18#define MAP_SHARED 0x01 /* Share changes */ 18/* 0x01 - 0x03 are defined in linux/mman.h */
19#define MAP_PRIVATE 0x02 /* Changes are private */
20#define MAP_SHARED_VALIDATE 0x03 /* share + validate extension flags */
21#define MAP_TYPE 0x0f /* Mask for type of mapping */ 19#define MAP_TYPE 0x0f /* Mask for type of mapping */
22#define MAP_FIXED 0x10 /* Interpret addr exactly */ 20#define MAP_FIXED 0x10 /* Interpret addr exactly */
23#define MAP_ANONYMOUS 0x20 /* don't use a file */ 21#define MAP_ANONYMOUS 0x20 /* don't use a file */
diff --git a/include/uapi/asm-generic/socket.h b/include/uapi/asm-generic/socket.h
index a12692e5f7a8..8c1391c89171 100644
--- a/include/uapi/asm-generic/socket.h
+++ b/include/uapi/asm-generic/socket.h
@@ -2,6 +2,7 @@
2#ifndef __ASM_GENERIC_SOCKET_H 2#ifndef __ASM_GENERIC_SOCKET_H
3#define __ASM_GENERIC_SOCKET_H 3#define __ASM_GENERIC_SOCKET_H
4 4
5#include <linux/posix_types.h>
5#include <asm/sockios.h> 6#include <asm/sockios.h>
6 7
7/* For setsockopt(2) */ 8/* For setsockopt(2) */
@@ -29,8 +30,8 @@
29#define SO_PEERCRED 17 30#define SO_PEERCRED 17
30#define SO_RCVLOWAT 18 31#define SO_RCVLOWAT 18
31#define SO_SNDLOWAT 19 32#define SO_SNDLOWAT 19
32#define SO_RCVTIMEO 20 33#define SO_RCVTIMEO_OLD 20
33#define SO_SNDTIMEO 21 34#define SO_SNDTIMEO_OLD 21
34#endif 35#endif
35 36
36/* Security levels - as per NRL IPv6 - don't actually do anything */ 37/* Security levels - as per NRL IPv6 - don't actually do anything */
@@ -46,21 +47,14 @@
46#define SO_GET_FILTER SO_ATTACH_FILTER 47#define SO_GET_FILTER SO_ATTACH_FILTER
47 48
48#define SO_PEERNAME 28 49#define SO_PEERNAME 28
49#define SO_TIMESTAMP 29
50#define SCM_TIMESTAMP SO_TIMESTAMP
51 50
52#define SO_ACCEPTCONN 30 51#define SO_ACCEPTCONN 30
53 52
54#define SO_PEERSEC 31 53#define SO_PEERSEC 31
55#define SO_PASSSEC 34 54#define SO_PASSSEC 34
56#define SO_TIMESTAMPNS 35
57#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
58 55
59#define SO_MARK 36 56#define SO_MARK 36
60 57
61#define SO_TIMESTAMPING 37
62#define SCM_TIMESTAMPING SO_TIMESTAMPING
63
64#define SO_PROTOCOL 38 58#define SO_PROTOCOL 38
65#define SO_DOMAIN 39 59#define SO_DOMAIN 39
66 60
@@ -110,4 +104,42 @@
110#define SO_TXTIME 61 104#define SO_TXTIME 61
111#define SCM_TXTIME SO_TXTIME 105#define SCM_TXTIME SO_TXTIME
112 106
107#define SO_BINDTOIFINDEX 62
108
109#define SO_TIMESTAMP_OLD 29
110#define SO_TIMESTAMPNS_OLD 35
111#define SO_TIMESTAMPING_OLD 37
112
113#define SO_TIMESTAMP_NEW 63
114#define SO_TIMESTAMPNS_NEW 64
115#define SO_TIMESTAMPING_NEW 65
116
117#define SO_RCVTIMEO_NEW 66
118#define SO_SNDTIMEO_NEW 67
119
120#if !defined(__KERNEL__)
121
122#if __BITS_PER_LONG == 64 || (defined(__x86_64__) && defined(__ILP32__))
123/* on 64-bit and x32, avoid the ?: operator */
124#define SO_TIMESTAMP SO_TIMESTAMP_OLD
125#define SO_TIMESTAMPNS SO_TIMESTAMPNS_OLD
126#define SO_TIMESTAMPING SO_TIMESTAMPING_OLD
127
128#define SO_RCVTIMEO SO_RCVTIMEO_OLD
129#define SO_SNDTIMEO SO_SNDTIMEO_OLD
130#else
131#define SO_TIMESTAMP (sizeof(time_t) == sizeof(__kernel_long_t) ? SO_TIMESTAMP_OLD : SO_TIMESTAMP_NEW)
132#define SO_TIMESTAMPNS (sizeof(time_t) == sizeof(__kernel_long_t) ? SO_TIMESTAMPNS_OLD : SO_TIMESTAMPNS_NEW)
133#define SO_TIMESTAMPING (sizeof(time_t) == sizeof(__kernel_long_t) ? SO_TIMESTAMPING_OLD : SO_TIMESTAMPING_NEW)
134
135#define SO_RCVTIMEO (sizeof(time_t) == sizeof(__kernel_long_t) ? SO_RCVTIMEO_OLD : SO_RCVTIMEO_NEW)
136#define SO_SNDTIMEO (sizeof(time_t) == sizeof(__kernel_long_t) ? SO_SNDTIMEO_OLD : SO_SNDTIMEO_NEW)
137#endif
138
139#define SCM_TIMESTAMP SO_TIMESTAMP
140#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
141#define SCM_TIMESTAMPING SO_TIMESTAMPING
142
143#endif
144
113#endif /* __ASM_GENERIC_SOCKET_H */ 145#endif /* __ASM_GENERIC_SOCKET_H */
diff --git a/include/uapi/asm-generic/unistd.h b/include/uapi/asm-generic/unistd.h
index d90127298f12..dee7292e1df6 100644
--- a/include/uapi/asm-generic/unistd.h
+++ b/include/uapi/asm-generic/unistd.h
@@ -38,8 +38,10 @@ __SYSCALL(__NR_io_destroy, sys_io_destroy)
38__SC_COMP(__NR_io_submit, sys_io_submit, compat_sys_io_submit) 38__SC_COMP(__NR_io_submit, sys_io_submit, compat_sys_io_submit)
39#define __NR_io_cancel 3 39#define __NR_io_cancel 3
40__SYSCALL(__NR_io_cancel, sys_io_cancel) 40__SYSCALL(__NR_io_cancel, sys_io_cancel)
41#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
41#define __NR_io_getevents 4 42#define __NR_io_getevents 4
42__SC_COMP(__NR_io_getevents, sys_io_getevents, compat_sys_io_getevents) 43__SC_3264(__NR_io_getevents, sys_io_getevents_time32, sys_io_getevents)
44#endif
43 45
44/* fs/xattr.c */ 46/* fs/xattr.c */
45#define __NR_setxattr 5 47#define __NR_setxattr 5
@@ -179,7 +181,7 @@ __SYSCALL(__NR_fchownat, sys_fchownat)
179#define __NR_fchown 55 181#define __NR_fchown 55
180__SYSCALL(__NR_fchown, sys_fchown) 182__SYSCALL(__NR_fchown, sys_fchown)
181#define __NR_openat 56 183#define __NR_openat 56
182__SC_COMP(__NR_openat, sys_openat, compat_sys_openat) 184__SYSCALL(__NR_openat, sys_openat)
183#define __NR_close 57 185#define __NR_close 57
184__SYSCALL(__NR_close, sys_close) 186__SYSCALL(__NR_close, sys_close)
185#define __NR_vhangup 58 187#define __NR_vhangup 58
@@ -222,10 +224,12 @@ __SC_COMP(__NR_pwritev, sys_pwritev, compat_sys_pwritev)
222__SYSCALL(__NR3264_sendfile, sys_sendfile64) 224__SYSCALL(__NR3264_sendfile, sys_sendfile64)
223 225
224/* fs/select.c */ 226/* fs/select.c */
227#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
225#define __NR_pselect6 72 228#define __NR_pselect6 72
226__SC_COMP(__NR_pselect6, sys_pselect6, compat_sys_pselect6) 229__SC_COMP_3264(__NR_pselect6, sys_pselect6_time32, sys_pselect6, compat_sys_pselect6_time32)
227#define __NR_ppoll 73 230#define __NR_ppoll 73
228__SC_COMP(__NR_ppoll, sys_ppoll, compat_sys_ppoll) 231__SC_COMP_3264(__NR_ppoll, sys_ppoll_time32, sys_ppoll, compat_sys_ppoll_time32)
232#endif
229 233
230/* fs/signalfd.c */ 234/* fs/signalfd.c */
231#define __NR_signalfd4 74 235#define __NR_signalfd4 74
@@ -269,16 +273,20 @@ __SC_COMP(__NR_sync_file_range, sys_sync_file_range, \
269/* fs/timerfd.c */ 273/* fs/timerfd.c */
270#define __NR_timerfd_create 85 274#define __NR_timerfd_create 85
271__SYSCALL(__NR_timerfd_create, sys_timerfd_create) 275__SYSCALL(__NR_timerfd_create, sys_timerfd_create)
276#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
272#define __NR_timerfd_settime 86 277#define __NR_timerfd_settime 86
273__SC_COMP(__NR_timerfd_settime, sys_timerfd_settime, \ 278__SC_3264(__NR_timerfd_settime, sys_timerfd_settime32, \
274 compat_sys_timerfd_settime) 279 sys_timerfd_settime)
275#define __NR_timerfd_gettime 87 280#define __NR_timerfd_gettime 87
276__SC_COMP(__NR_timerfd_gettime, sys_timerfd_gettime, \ 281__SC_3264(__NR_timerfd_gettime, sys_timerfd_gettime32, \
277 compat_sys_timerfd_gettime) 282 sys_timerfd_gettime)
283#endif
278 284
279/* fs/utimes.c */ 285/* fs/utimes.c */
286#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
280#define __NR_utimensat 88 287#define __NR_utimensat 88
281__SC_COMP(__NR_utimensat, sys_utimensat, compat_sys_utimensat) 288__SC_3264(__NR_utimensat, sys_utimensat_time32, sys_utimensat)
289#endif
282 290
283/* kernel/acct.c */ 291/* kernel/acct.c */
284#define __NR_acct 89 292#define __NR_acct 89
@@ -309,8 +317,10 @@ __SYSCALL(__NR_set_tid_address, sys_set_tid_address)
309__SYSCALL(__NR_unshare, sys_unshare) 317__SYSCALL(__NR_unshare, sys_unshare)
310 318
311/* kernel/futex.c */ 319/* kernel/futex.c */
320#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
312#define __NR_futex 98 321#define __NR_futex 98
313__SC_COMP(__NR_futex, sys_futex, compat_sys_futex) 322__SC_3264(__NR_futex, sys_futex_time32, sys_futex)
323#endif
314#define __NR_set_robust_list 99 324#define __NR_set_robust_list 99
315__SC_COMP(__NR_set_robust_list, sys_set_robust_list, \ 325__SC_COMP(__NR_set_robust_list, sys_set_robust_list, \
316 compat_sys_set_robust_list) 326 compat_sys_set_robust_list)
@@ -319,8 +329,10 @@ __SC_COMP(__NR_get_robust_list, sys_get_robust_list, \
319 compat_sys_get_robust_list) 329 compat_sys_get_robust_list)
320 330
321/* kernel/hrtimer.c */ 331/* kernel/hrtimer.c */
332#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
322#define __NR_nanosleep 101 333#define __NR_nanosleep 101
323__SC_COMP(__NR_nanosleep, sys_nanosleep, compat_sys_nanosleep) 334__SC_3264(__NR_nanosleep, sys_nanosleep_time32, sys_nanosleep)
335#endif
324 336
325/* kernel/itimer.c */ 337/* kernel/itimer.c */
326#define __NR_getitimer 102 338#define __NR_getitimer 102
@@ -341,23 +353,29 @@ __SYSCALL(__NR_delete_module, sys_delete_module)
341/* kernel/posix-timers.c */ 353/* kernel/posix-timers.c */
342#define __NR_timer_create 107 354#define __NR_timer_create 107
343__SC_COMP(__NR_timer_create, sys_timer_create, compat_sys_timer_create) 355__SC_COMP(__NR_timer_create, sys_timer_create, compat_sys_timer_create)
356#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
344#define __NR_timer_gettime 108 357#define __NR_timer_gettime 108
345__SC_COMP(__NR_timer_gettime, sys_timer_gettime, compat_sys_timer_gettime) 358__SC_3264(__NR_timer_gettime, sys_timer_gettime32, sys_timer_gettime)
359#endif
346#define __NR_timer_getoverrun 109 360#define __NR_timer_getoverrun 109
347__SYSCALL(__NR_timer_getoverrun, sys_timer_getoverrun) 361__SYSCALL(__NR_timer_getoverrun, sys_timer_getoverrun)
362#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
348#define __NR_timer_settime 110 363#define __NR_timer_settime 110
349__SC_COMP(__NR_timer_settime, sys_timer_settime, compat_sys_timer_settime) 364__SC_3264(__NR_timer_settime, sys_timer_settime32, sys_timer_settime)
365#endif
350#define __NR_timer_delete 111 366#define __NR_timer_delete 111
351__SYSCALL(__NR_timer_delete, sys_timer_delete) 367__SYSCALL(__NR_timer_delete, sys_timer_delete)
368#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
352#define __NR_clock_settime 112 369#define __NR_clock_settime 112
353__SC_COMP(__NR_clock_settime, sys_clock_settime, compat_sys_clock_settime) 370__SC_3264(__NR_clock_settime, sys_clock_settime32, sys_clock_settime)
354#define __NR_clock_gettime 113 371#define __NR_clock_gettime 113
355__SC_COMP(__NR_clock_gettime, sys_clock_gettime, compat_sys_clock_gettime) 372__SC_3264(__NR_clock_gettime, sys_clock_gettime32, sys_clock_gettime)
356#define __NR_clock_getres 114 373#define __NR_clock_getres 114
357__SC_COMP(__NR_clock_getres, sys_clock_getres, compat_sys_clock_getres) 374__SC_3264(__NR_clock_getres, sys_clock_getres_time32, sys_clock_getres)
358#define __NR_clock_nanosleep 115 375#define __NR_clock_nanosleep 115
359__SC_COMP(__NR_clock_nanosleep, sys_clock_nanosleep, \ 376__SC_3264(__NR_clock_nanosleep, sys_clock_nanosleep_time32, \
360 compat_sys_clock_nanosleep) 377 sys_clock_nanosleep)
378#endif
361 379
362/* kernel/printk.c */ 380/* kernel/printk.c */
363#define __NR_syslog 116 381#define __NR_syslog 116
@@ -388,9 +406,11 @@ __SYSCALL(__NR_sched_yield, sys_sched_yield)
388__SYSCALL(__NR_sched_get_priority_max, sys_sched_get_priority_max) 406__SYSCALL(__NR_sched_get_priority_max, sys_sched_get_priority_max)
389#define __NR_sched_get_priority_min 126 407#define __NR_sched_get_priority_min 126
390__SYSCALL(__NR_sched_get_priority_min, sys_sched_get_priority_min) 408__SYSCALL(__NR_sched_get_priority_min, sys_sched_get_priority_min)
409#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
391#define __NR_sched_rr_get_interval 127 410#define __NR_sched_rr_get_interval 127
392__SC_COMP(__NR_sched_rr_get_interval, sys_sched_rr_get_interval, \ 411__SC_3264(__NR_sched_rr_get_interval, sys_sched_rr_get_interval_time32, \
393 compat_sys_sched_rr_get_interval) 412 sys_sched_rr_get_interval)
413#endif
394 414
395/* kernel/signal.c */ 415/* kernel/signal.c */
396#define __NR_restart_syscall 128 416#define __NR_restart_syscall 128
@@ -411,9 +431,11 @@ __SC_COMP(__NR_rt_sigaction, sys_rt_sigaction, compat_sys_rt_sigaction)
411__SC_COMP(__NR_rt_sigprocmask, sys_rt_sigprocmask, compat_sys_rt_sigprocmask) 431__SC_COMP(__NR_rt_sigprocmask, sys_rt_sigprocmask, compat_sys_rt_sigprocmask)
412#define __NR_rt_sigpending 136 432#define __NR_rt_sigpending 136
413__SC_COMP(__NR_rt_sigpending, sys_rt_sigpending, compat_sys_rt_sigpending) 433__SC_COMP(__NR_rt_sigpending, sys_rt_sigpending, compat_sys_rt_sigpending)
434#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
414#define __NR_rt_sigtimedwait 137 435#define __NR_rt_sigtimedwait 137
415__SC_COMP(__NR_rt_sigtimedwait, sys_rt_sigtimedwait, \ 436__SC_COMP_3264(__NR_rt_sigtimedwait, sys_rt_sigtimedwait_time32, \
416 compat_sys_rt_sigtimedwait) 437 sys_rt_sigtimedwait, compat_sys_rt_sigtimedwait_time32)
438#endif
417#define __NR_rt_sigqueueinfo 138 439#define __NR_rt_sigqueueinfo 138
418__SC_COMP(__NR_rt_sigqueueinfo, sys_rt_sigqueueinfo, \ 440__SC_COMP(__NR_rt_sigqueueinfo, sys_rt_sigqueueinfo, \
419 compat_sys_rt_sigqueueinfo) 441 compat_sys_rt_sigqueueinfo)
@@ -467,10 +489,15 @@ __SYSCALL(__NR_uname, sys_newuname)
467__SYSCALL(__NR_sethostname, sys_sethostname) 489__SYSCALL(__NR_sethostname, sys_sethostname)
468#define __NR_setdomainname 162 490#define __NR_setdomainname 162
469__SYSCALL(__NR_setdomainname, sys_setdomainname) 491__SYSCALL(__NR_setdomainname, sys_setdomainname)
492
493#ifdef __ARCH_WANT_SET_GET_RLIMIT
494/* getrlimit and setrlimit are superseded with prlimit64 */
470#define __NR_getrlimit 163 495#define __NR_getrlimit 163
471__SC_COMP(__NR_getrlimit, sys_getrlimit, compat_sys_getrlimit) 496__SC_COMP(__NR_getrlimit, sys_getrlimit, compat_sys_getrlimit)
472#define __NR_setrlimit 164 497#define __NR_setrlimit 164
473__SC_COMP(__NR_setrlimit, sys_setrlimit, compat_sys_setrlimit) 498__SC_COMP(__NR_setrlimit, sys_setrlimit, compat_sys_setrlimit)
499#endif
500
474#define __NR_getrusage 165 501#define __NR_getrusage 165
475__SC_COMP(__NR_getrusage, sys_getrusage, compat_sys_getrusage) 502__SC_COMP(__NR_getrusage, sys_getrusage, compat_sys_getrusage)
476#define __NR_umask 166 503#define __NR_umask 166
@@ -481,12 +508,14 @@ __SYSCALL(__NR_prctl, sys_prctl)
481__SYSCALL(__NR_getcpu, sys_getcpu) 508__SYSCALL(__NR_getcpu, sys_getcpu)
482 509
483/* kernel/time.c */ 510/* kernel/time.c */
511#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
484#define __NR_gettimeofday 169 512#define __NR_gettimeofday 169
485__SC_COMP(__NR_gettimeofday, sys_gettimeofday, compat_sys_gettimeofday) 513__SC_COMP(__NR_gettimeofday, sys_gettimeofday, compat_sys_gettimeofday)
486#define __NR_settimeofday 170 514#define __NR_settimeofday 170
487__SC_COMP(__NR_settimeofday, sys_settimeofday, compat_sys_settimeofday) 515__SC_COMP(__NR_settimeofday, sys_settimeofday, compat_sys_settimeofday)
488#define __NR_adjtimex 171 516#define __NR_adjtimex 171
489__SC_COMP(__NR_adjtimex, sys_adjtimex, compat_sys_adjtimex) 517__SC_3264(__NR_adjtimex, sys_adjtimex_time32, sys_adjtimex)
518#endif
490 519
491/* kernel/timer.c */ 520/* kernel/timer.c */
492#define __NR_getpid 172 521#define __NR_getpid 172
@@ -511,11 +540,13 @@ __SC_COMP(__NR_sysinfo, sys_sysinfo, compat_sys_sysinfo)
511__SC_COMP(__NR_mq_open, sys_mq_open, compat_sys_mq_open) 540__SC_COMP(__NR_mq_open, sys_mq_open, compat_sys_mq_open)
512#define __NR_mq_unlink 181 541#define __NR_mq_unlink 181
513__SYSCALL(__NR_mq_unlink, sys_mq_unlink) 542__SYSCALL(__NR_mq_unlink, sys_mq_unlink)
543#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
514#define __NR_mq_timedsend 182 544#define __NR_mq_timedsend 182
515__SC_COMP(__NR_mq_timedsend, sys_mq_timedsend, compat_sys_mq_timedsend) 545__SC_3264(__NR_mq_timedsend, sys_mq_timedsend_time32, sys_mq_timedsend)
516#define __NR_mq_timedreceive 183 546#define __NR_mq_timedreceive 183
517__SC_COMP(__NR_mq_timedreceive, sys_mq_timedreceive, \ 547__SC_3264(__NR_mq_timedreceive, sys_mq_timedreceive_time32, \
518 compat_sys_mq_timedreceive) 548 sys_mq_timedreceive)
549#endif
519#define __NR_mq_notify 184 550#define __NR_mq_notify 184
520__SC_COMP(__NR_mq_notify, sys_mq_notify, compat_sys_mq_notify) 551__SC_COMP(__NR_mq_notify, sys_mq_notify, compat_sys_mq_notify)
521#define __NR_mq_getsetattr 185 552#define __NR_mq_getsetattr 185
@@ -536,8 +567,10 @@ __SC_COMP(__NR_msgsnd, sys_msgsnd, compat_sys_msgsnd)
536__SYSCALL(__NR_semget, sys_semget) 567__SYSCALL(__NR_semget, sys_semget)
537#define __NR_semctl 191 568#define __NR_semctl 191
538__SC_COMP(__NR_semctl, sys_semctl, compat_sys_semctl) 569__SC_COMP(__NR_semctl, sys_semctl, compat_sys_semctl)
570#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
539#define __NR_semtimedop 192 571#define __NR_semtimedop 192
540__SC_COMP(__NR_semtimedop, sys_semtimedop, compat_sys_semtimedop) 572__SC_COMP(__NR_semtimedop, sys_semtimedop, sys_semtimedop_time32)
573#endif
541#define __NR_semop 193 574#define __NR_semop 193
542__SYSCALL(__NR_semop, sys_semop) 575__SYSCALL(__NR_semop, sys_semop)
543 576
@@ -658,8 +691,10 @@ __SC_COMP(__NR_rt_tgsigqueueinfo, sys_rt_tgsigqueueinfo, \
658__SYSCALL(__NR_perf_event_open, sys_perf_event_open) 691__SYSCALL(__NR_perf_event_open, sys_perf_event_open)
659#define __NR_accept4 242 692#define __NR_accept4 242
660__SYSCALL(__NR_accept4, sys_accept4) 693__SYSCALL(__NR_accept4, sys_accept4)
694#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
661#define __NR_recvmmsg 243 695#define __NR_recvmmsg 243
662__SC_COMP(__NR_recvmmsg, sys_recvmmsg, compat_sys_recvmmsg) 696__SC_COMP_3264(__NR_recvmmsg, sys_recvmmsg_time32, sys_recvmmsg, compat_sys_recvmmsg_time32)
697#endif
663 698
664/* 699/*
665 * Architectures may provide up to 16 syscalls of their own 700 * Architectures may provide up to 16 syscalls of their own
@@ -667,8 +702,10 @@ __SC_COMP(__NR_recvmmsg, sys_recvmmsg, compat_sys_recvmmsg)
667 */ 702 */
668#define __NR_arch_specific_syscall 244 703#define __NR_arch_specific_syscall 244
669 704
705#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
670#define __NR_wait4 260 706#define __NR_wait4 260
671__SC_COMP(__NR_wait4, sys_wait4, compat_sys_wait4) 707__SC_COMP(__NR_wait4, sys_wait4, compat_sys_wait4)
708#endif
672#define __NR_prlimit64 261 709#define __NR_prlimit64 261
673__SYSCALL(__NR_prlimit64, sys_prlimit64) 710__SYSCALL(__NR_prlimit64, sys_prlimit64)
674#define __NR_fanotify_init 262 711#define __NR_fanotify_init 262
@@ -678,10 +715,11 @@ __SYSCALL(__NR_fanotify_mark, sys_fanotify_mark)
678#define __NR_name_to_handle_at 264 715#define __NR_name_to_handle_at 264
679__SYSCALL(__NR_name_to_handle_at, sys_name_to_handle_at) 716__SYSCALL(__NR_name_to_handle_at, sys_name_to_handle_at)
680#define __NR_open_by_handle_at 265 717#define __NR_open_by_handle_at 265
681__SC_COMP(__NR_open_by_handle_at, sys_open_by_handle_at, \ 718__SYSCALL(__NR_open_by_handle_at, sys_open_by_handle_at)
682 compat_sys_open_by_handle_at) 719#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
683#define __NR_clock_adjtime 266 720#define __NR_clock_adjtime 266
684__SC_COMP(__NR_clock_adjtime, sys_clock_adjtime, compat_sys_clock_adjtime) 721__SC_3264(__NR_clock_adjtime, sys_clock_adjtime32, sys_clock_adjtime)
722#endif
685#define __NR_syncfs 267 723#define __NR_syncfs 267
686__SYSCALL(__NR_syncfs, sys_syncfs) 724__SYSCALL(__NR_syncfs, sys_syncfs)
687#define __NR_setns 268 725#define __NR_setns 268
@@ -734,15 +772,69 @@ __SYSCALL(__NR_pkey_alloc, sys_pkey_alloc)
734__SYSCALL(__NR_pkey_free, sys_pkey_free) 772__SYSCALL(__NR_pkey_free, sys_pkey_free)
735#define __NR_statx 291 773#define __NR_statx 291
736__SYSCALL(__NR_statx, sys_statx) 774__SYSCALL(__NR_statx, sys_statx)
775#if defined(__ARCH_WANT_TIME32_SYSCALLS) || __BITS_PER_LONG != 32
737#define __NR_io_pgetevents 292 776#define __NR_io_pgetevents 292
738__SC_COMP(__NR_io_pgetevents, sys_io_pgetevents, compat_sys_io_pgetevents) 777__SC_COMP_3264(__NR_io_pgetevents, sys_io_pgetevents_time32, sys_io_pgetevents, compat_sys_io_pgetevents)
778#endif
739#define __NR_rseq 293 779#define __NR_rseq 293
740__SYSCALL(__NR_rseq, sys_rseq) 780__SYSCALL(__NR_rseq, sys_rseq)
741#define __NR_kexec_file_load 294 781#define __NR_kexec_file_load 294
742__SYSCALL(__NR_kexec_file_load, sys_kexec_file_load) 782__SYSCALL(__NR_kexec_file_load, sys_kexec_file_load)
783/* 295 through 402 are unassigned to sync up with generic numbers, don't use */
784#if __BITS_PER_LONG == 32
785#define __NR_clock_gettime64 403
786__SYSCALL(__NR_clock_gettime64, sys_clock_gettime)
787#define __NR_clock_settime64 404
788__SYSCALL(__NR_clock_settime64, sys_clock_settime)
789#define __NR_clock_adjtime64 405
790__SYSCALL(__NR_clock_adjtime64, sys_clock_adjtime)
791#define __NR_clock_getres_time64 406
792__SYSCALL(__NR_clock_getres_time64, sys_clock_getres)
793#define __NR_clock_nanosleep_time64 407
794__SYSCALL(__NR_clock_nanosleep_time64, sys_clock_nanosleep)
795#define __NR_timer_gettime64 408
796__SYSCALL(__NR_timer_gettime64, sys_timer_gettime)
797#define __NR_timer_settime64 409
798__SYSCALL(__NR_timer_settime64, sys_timer_settime)
799#define __NR_timerfd_gettime64 410
800__SYSCALL(__NR_timerfd_gettime64, sys_timerfd_gettime)
801#define __NR_timerfd_settime64 411
802__SYSCALL(__NR_timerfd_settime64, sys_timerfd_settime)
803#define __NR_utimensat_time64 412
804__SYSCALL(__NR_utimensat_time64, sys_utimensat)
805#define __NR_pselect6_time64 413
806__SC_COMP(__NR_pselect6_time64, sys_pselect6, compat_sys_pselect6_time64)
807#define __NR_ppoll_time64 414
808__SC_COMP(__NR_ppoll_time64, sys_ppoll, compat_sys_ppoll_time64)
809#define __NR_io_pgetevents_time64 416
810__SYSCALL(__NR_io_pgetevents_time64, sys_io_pgetevents)
811#define __NR_recvmmsg_time64 417
812__SC_COMP(__NR_recvmmsg_time64, sys_recvmmsg, compat_sys_recvmmsg_time64)
813#define __NR_mq_timedsend_time64 418
814__SYSCALL(__NR_mq_timedsend_time64, sys_mq_timedsend)
815#define __NR_mq_timedreceive_time64 419
816__SYSCALL(__NR_mq_timedreceive_time64, sys_mq_timedreceive)
817#define __NR_semtimedop_time64 420
818__SYSCALL(__NR_semtimedop_time64, sys_semtimedop)
819#define __NR_rt_sigtimedwait_time64 421
820__SC_COMP(__NR_rt_sigtimedwait_time64, sys_rt_sigtimedwait, compat_sys_rt_sigtimedwait_time64)
821#define __NR_futex_time64 422
822__SYSCALL(__NR_futex_time64, sys_futex)
823#define __NR_sched_rr_get_interval_time64 423
824__SYSCALL(__NR_sched_rr_get_interval_time64, sys_sched_rr_get_interval)
825#endif
826
827#define __NR_pidfd_send_signal 424
828__SYSCALL(__NR_pidfd_send_signal, sys_pidfd_send_signal)
829#define __NR_io_uring_setup 425
830__SYSCALL(__NR_io_uring_setup, sys_io_uring_setup)
831#define __NR_io_uring_enter 426
832__SYSCALL(__NR_io_uring_enter, sys_io_uring_enter)
833#define __NR_io_uring_register 427
834__SYSCALL(__NR_io_uring_register, sys_io_uring_register)
743 835
744#undef __NR_syscalls 836#undef __NR_syscalls
745#define __NR_syscalls 295 837#define __NR_syscalls 428
746 838
747/* 839/*
748 * 32 bit systems traditionally used different 840 * 32 bit systems traditionally used different
diff --git a/include/uapi/drm/amdgpu_drm.h b/include/uapi/drm/amdgpu_drm.h
index be84e43c1e19..4a53f6cfa034 100644
--- a/include/uapi/drm/amdgpu_drm.h
+++ b/include/uapi/drm/amdgpu_drm.h
@@ -272,13 +272,14 @@ union drm_amdgpu_vm {
272 272
273/* sched ioctl */ 273/* sched ioctl */
274#define AMDGPU_SCHED_OP_PROCESS_PRIORITY_OVERRIDE 1 274#define AMDGPU_SCHED_OP_PROCESS_PRIORITY_OVERRIDE 1
275#define AMDGPU_SCHED_OP_CONTEXT_PRIORITY_OVERRIDE 2
275 276
276struct drm_amdgpu_sched_in { 277struct drm_amdgpu_sched_in {
277 /* AMDGPU_SCHED_OP_* */ 278 /* AMDGPU_SCHED_OP_* */
278 __u32 op; 279 __u32 op;
279 __u32 fd; 280 __u32 fd;
280 __s32 priority; 281 __s32 priority;
281 __u32 flags; 282 __u32 ctx_id;
282}; 283};
283 284
284union drm_amdgpu_sched { 285union drm_amdgpu_sched {
@@ -523,6 +524,7 @@ struct drm_amdgpu_gem_va {
523#define AMDGPU_CHUNK_ID_SYNCOBJ_IN 0x04 524#define AMDGPU_CHUNK_ID_SYNCOBJ_IN 0x04
524#define AMDGPU_CHUNK_ID_SYNCOBJ_OUT 0x05 525#define AMDGPU_CHUNK_ID_SYNCOBJ_OUT 0x05
525#define AMDGPU_CHUNK_ID_BO_HANDLES 0x06 526#define AMDGPU_CHUNK_ID_BO_HANDLES 0x06
527#define AMDGPU_CHUNK_ID_SCHEDULED_DEPENDENCIES 0x07
526 528
527struct drm_amdgpu_cs_chunk { 529struct drm_amdgpu_cs_chunk {
528 __u32 chunk_id; 530 __u32 chunk_id;
@@ -565,6 +567,11 @@ union drm_amdgpu_cs {
565 * caches (L2/vL1/sL1/I$). */ 567 * caches (L2/vL1/sL1/I$). */
566#define AMDGPU_IB_FLAG_TC_WB_NOT_INVALIDATE (1 << 3) 568#define AMDGPU_IB_FLAG_TC_WB_NOT_INVALIDATE (1 << 3)
567 569
570/* Set GDS_COMPUTE_MAX_WAVE_ID = DEFAULT before PACKET3_INDIRECT_BUFFER.
571 * This will reset wave ID counters for the IB.
572 */
573#define AMDGPU_IB_FLAG_RESET_GDS_MAX_WAVE_ID (1 << 4)
574
568struct drm_amdgpu_cs_chunk_ib { 575struct drm_amdgpu_cs_chunk_ib {
569 __u32 _pad; 576 __u32 _pad;
570 /** AMDGPU_IB_FLAG_* */ 577 /** AMDGPU_IB_FLAG_* */
diff --git a/include/uapi/drm/drm_fourcc.h b/include/uapi/drm/drm_fourcc.h
index 0b44260a5ee9..bab20298f422 100644
--- a/include/uapi/drm/drm_fourcc.h
+++ b/include/uapi/drm/drm_fourcc.h
@@ -196,6 +196,27 @@ extern "C" {
196#define DRM_FORMAT_NV42 fourcc_code('N', 'V', '4', '2') /* non-subsampled Cb:Cr plane */ 196#define DRM_FORMAT_NV42 fourcc_code('N', 'V', '4', '2') /* non-subsampled Cb:Cr plane */
197 197
198/* 198/*
199 * 2 plane YCbCr MSB aligned
200 * index 0 = Y plane, [15:0] Y:x [10:6] little endian
201 * index 1 = Cr:Cb plane, [31:0] Cr:x:Cb:x [10:6:10:6] little endian
202 */
203#define DRM_FORMAT_P010 fourcc_code('P', '0', '1', '0') /* 2x2 subsampled Cr:Cb plane 10 bits per channel */
204
205/*
206 * 2 plane YCbCr MSB aligned
207 * index 0 = Y plane, [15:0] Y:x [12:4] little endian
208 * index 1 = Cr:Cb plane, [31:0] Cr:x:Cb:x [12:4:12:4] little endian
209 */
210#define DRM_FORMAT_P012 fourcc_code('P', '0', '1', '2') /* 2x2 subsampled Cr:Cb plane 12 bits per channel */
211
212/*
213 * 2 plane YCbCr MSB aligned
214 * index 0 = Y plane, [15:0] Y little endian
215 * index 1 = Cr:Cb plane, [31:0] Cr:Cb [16:16] little endian
216 */
217#define DRM_FORMAT_P016 fourcc_code('P', '0', '1', '6') /* 2x2 subsampled Cr:Cb plane 16 bits per channel */
218
219/*
199 * 3 plane YCbCr 220 * 3 plane YCbCr
200 * index 0: Y plane, [7:0] Y 221 * index 0: Y plane, [7:0] Y
201 * index 1: Cb plane, [7:0] Cb 222 * index 1: Cb plane, [7:0] Cb
@@ -238,6 +259,8 @@ extern "C" {
238#define DRM_FORMAT_MOD_VENDOR_VIVANTE 0x06 259#define DRM_FORMAT_MOD_VENDOR_VIVANTE 0x06
239#define DRM_FORMAT_MOD_VENDOR_BROADCOM 0x07 260#define DRM_FORMAT_MOD_VENDOR_BROADCOM 0x07
240#define DRM_FORMAT_MOD_VENDOR_ARM 0x08 261#define DRM_FORMAT_MOD_VENDOR_ARM 0x08
262#define DRM_FORMAT_MOD_VENDOR_ALLWINNER 0x09
263
241/* add more to the end as needed */ 264/* add more to the end as needed */
242 265
243#define DRM_FORMAT_RESERVED ((1ULL << 56) - 1) 266#define DRM_FORMAT_RESERVED ((1ULL << 56) - 1)
@@ -572,6 +595,9 @@ extern "C" {
572 * AFBC has several features which may be supported and/or used, which are 595 * AFBC has several features which may be supported and/or used, which are
573 * represented using bits in the modifier. Not all combinations are valid, 596 * represented using bits in the modifier. Not all combinations are valid,
574 * and different devices or use-cases may support different combinations. 597 * and different devices or use-cases may support different combinations.
598 *
599 * Further information on the use of AFBC modifiers can be found in
600 * Documentation/gpu/afbc.rst
575 */ 601 */
576#define DRM_FORMAT_MOD_ARM_AFBC(__afbc_mode) fourcc_mod_code(ARM, __afbc_mode) 602#define DRM_FORMAT_MOD_ARM_AFBC(__afbc_mode) fourcc_mod_code(ARM, __afbc_mode)
577 603
@@ -581,10 +607,18 @@ extern "C" {
581 * Indicates the superblock size(s) used for the AFBC buffer. The buffer 607 * Indicates the superblock size(s) used for the AFBC buffer. The buffer
582 * size (in pixels) must be aligned to a multiple of the superblock size. 608 * size (in pixels) must be aligned to a multiple of the superblock size.
583 * Four lowest significant bits(LSBs) are reserved for block size. 609 * Four lowest significant bits(LSBs) are reserved for block size.
610 *
611 * Where one superblock size is specified, it applies to all planes of the
612 * buffer (e.g. 16x16, 32x8). When multiple superblock sizes are specified,
613 * the first applies to the Luma plane and the second applies to the Chroma
614 * plane(s). e.g. (32x8_64x4 means 32x8 Luma, with 64x4 Chroma).
615 * Multiple superblock sizes are only valid for multi-plane YCbCr formats.
584 */ 616 */
585#define AFBC_FORMAT_MOD_BLOCK_SIZE_MASK 0xf 617#define AFBC_FORMAT_MOD_BLOCK_SIZE_MASK 0xf
586#define AFBC_FORMAT_MOD_BLOCK_SIZE_16x16 (1ULL) 618#define AFBC_FORMAT_MOD_BLOCK_SIZE_16x16 (1ULL)
587#define AFBC_FORMAT_MOD_BLOCK_SIZE_32x8 (2ULL) 619#define AFBC_FORMAT_MOD_BLOCK_SIZE_32x8 (2ULL)
620#define AFBC_FORMAT_MOD_BLOCK_SIZE_64x4 (3ULL)
621#define AFBC_FORMAT_MOD_BLOCK_SIZE_32x8_64x4 (4ULL)
588 622
589/* 623/*
590 * AFBC lossless colorspace transform 624 * AFBC lossless colorspace transform
@@ -644,6 +678,35 @@ extern "C" {
644 */ 678 */
645#define AFBC_FORMAT_MOD_SC (1ULL << 9) 679#define AFBC_FORMAT_MOD_SC (1ULL << 9)
646 680
681/*
682 * AFBC double-buffer
683 *
684 * Indicates that the buffer is allocated in a layout safe for front-buffer
685 * rendering.
686 */
687#define AFBC_FORMAT_MOD_DB (1ULL << 10)
688
689/*
690 * AFBC buffer content hints
691 *
692 * Indicates that the buffer includes per-superblock content hints.
693 */
694#define AFBC_FORMAT_MOD_BCH (1ULL << 11)
695
696/*
697 * Allwinner tiled modifier
698 *
699 * This tiling mode is implemented by the VPU found on all Allwinner platforms,
700 * codenamed sunxi. It is associated with a YUV format that uses either 2 or 3
701 * planes.
702 *
703 * With this tiling, the luminance samples are disposed in tiles representing
704 * 32x32 pixels and the chrominance samples in tiles representing 32x64 pixels.
705 * The pixel order in each tile is linear and the tiles are disposed linearly,
706 * both in row-major order.
707 */
708#define DRM_FORMAT_MOD_ALLWINNER_TILED fourcc_mod_code(ALLWINNER, 1)
709
647#if defined(__cplusplus) 710#if defined(__cplusplus)
648} 711}
649#endif 712#endif
diff --git a/include/uapi/drm/i915_drm.h b/include/uapi/drm/i915_drm.h
index 298b2e197744..397810fa2d33 100644
--- a/include/uapi/drm/i915_drm.h
+++ b/include/uapi/drm/i915_drm.h
@@ -1486,9 +1486,73 @@ struct drm_i915_gem_context_param {
1486#define I915_CONTEXT_MAX_USER_PRIORITY 1023 /* inclusive */ 1486#define I915_CONTEXT_MAX_USER_PRIORITY 1023 /* inclusive */
1487#define I915_CONTEXT_DEFAULT_PRIORITY 0 1487#define I915_CONTEXT_DEFAULT_PRIORITY 0
1488#define I915_CONTEXT_MIN_USER_PRIORITY -1023 /* inclusive */ 1488#define I915_CONTEXT_MIN_USER_PRIORITY -1023 /* inclusive */
1489 /*
1490 * When using the following param, value should be a pointer to
1491 * drm_i915_gem_context_param_sseu.
1492 */
1493#define I915_CONTEXT_PARAM_SSEU 0x7
1489 __u64 value; 1494 __u64 value;
1490}; 1495};
1491 1496
1497/**
1498 * Context SSEU programming
1499 *
1500 * It may be necessary for either functional or performance reason to configure
1501 * a context to run with a reduced number of SSEU (where SSEU stands for Slice/
1502 * Sub-slice/EU).
1503 *
1504 * This is done by configuring SSEU configuration using the below
1505 * @struct drm_i915_gem_context_param_sseu for every supported engine which
1506 * userspace intends to use.
1507 *
1508 * Not all GPUs or engines support this functionality in which case an error
1509 * code -ENODEV will be returned.
1510 *
1511 * Also, flexibility of possible SSEU configuration permutations varies between
1512 * GPU generations and software imposed limitations. Requesting such a
1513 * combination will return an error code of -EINVAL.
1514 *
1515 * NOTE: When perf/OA is active the context's SSEU configuration is ignored in
1516 * favour of a single global setting.
1517 */
1518struct drm_i915_gem_context_param_sseu {
1519 /*
1520 * Engine class & instance to be configured or queried.
1521 */
1522 __u16 engine_class;
1523 __u16 engine_instance;
1524
1525 /*
1526 * Unused for now. Must be cleared to zero.
1527 */
1528 __u32 flags;
1529
1530 /*
1531 * Mask of slices to enable for the context. Valid values are a subset
1532 * of the bitmask value returned for I915_PARAM_SLICE_MASK.
1533 */
1534 __u64 slice_mask;
1535
1536 /*
1537 * Mask of subslices to enable for the context. Valid values are a
1538 * subset of the bitmask value return by I915_PARAM_SUBSLICE_MASK.
1539 */
1540 __u64 subslice_mask;
1541
1542 /*
1543 * Minimum/Maximum number of EUs to enable per subslice for the
1544 * context. min_eus_per_subslice must be inferior or equal to
1545 * max_eus_per_subslice.
1546 */
1547 __u16 min_eus_per_subslice;
1548 __u16 max_eus_per_subslice;
1549
1550 /*
1551 * Unused for now. Must be cleared to zero.
1552 */
1553 __u32 rsvd;
1554};
1555
1492enum drm_i915_oa_format { 1556enum drm_i915_oa_format {
1493 I915_OA_FORMAT_A13 = 1, /* HSW only */ 1557 I915_OA_FORMAT_A13 = 1, /* HSW only */
1494 I915_OA_FORMAT_A29, /* HSW only */ 1558 I915_OA_FORMAT_A29, /* HSW only */
diff --git a/include/uapi/drm/nouveau_drm.h b/include/uapi/drm/nouveau_drm.h
index 259588a4b61b..9459a6e3bc1f 100644
--- a/include/uapi/drm/nouveau_drm.h
+++ b/include/uapi/drm/nouveau_drm.h
@@ -133,12 +133,63 @@ struct drm_nouveau_gem_cpu_fini {
133#define DRM_NOUVEAU_NOTIFIEROBJ_ALLOC 0x05 /* deprecated */ 133#define DRM_NOUVEAU_NOTIFIEROBJ_ALLOC 0x05 /* deprecated */
134#define DRM_NOUVEAU_GPUOBJ_FREE 0x06 /* deprecated */ 134#define DRM_NOUVEAU_GPUOBJ_FREE 0x06 /* deprecated */
135#define DRM_NOUVEAU_NVIF 0x07 135#define DRM_NOUVEAU_NVIF 0x07
136#define DRM_NOUVEAU_SVM_INIT 0x08
137#define DRM_NOUVEAU_SVM_BIND 0x09
136#define DRM_NOUVEAU_GEM_NEW 0x40 138#define DRM_NOUVEAU_GEM_NEW 0x40
137#define DRM_NOUVEAU_GEM_PUSHBUF 0x41 139#define DRM_NOUVEAU_GEM_PUSHBUF 0x41
138#define DRM_NOUVEAU_GEM_CPU_PREP 0x42 140#define DRM_NOUVEAU_GEM_CPU_PREP 0x42
139#define DRM_NOUVEAU_GEM_CPU_FINI 0x43 141#define DRM_NOUVEAU_GEM_CPU_FINI 0x43
140#define DRM_NOUVEAU_GEM_INFO 0x44 142#define DRM_NOUVEAU_GEM_INFO 0x44
141 143
144struct drm_nouveau_svm_init {
145 __u64 unmanaged_addr;
146 __u64 unmanaged_size;
147};
148
149struct drm_nouveau_svm_bind {
150 __u64 header;
151 __u64 va_start;
152 __u64 va_end;
153 __u64 npages;
154 __u64 stride;
155 __u64 result;
156 __u64 reserved0;
157 __u64 reserved1;
158};
159
160#define NOUVEAU_SVM_BIND_COMMAND_SHIFT 0
161#define NOUVEAU_SVM_BIND_COMMAND_BITS 8
162#define NOUVEAU_SVM_BIND_COMMAND_MASK ((1 << 8) - 1)
163#define NOUVEAU_SVM_BIND_PRIORITY_SHIFT 8
164#define NOUVEAU_SVM_BIND_PRIORITY_BITS 8
165#define NOUVEAU_SVM_BIND_PRIORITY_MASK ((1 << 8) - 1)
166#define NOUVEAU_SVM_BIND_TARGET_SHIFT 16
167#define NOUVEAU_SVM_BIND_TARGET_BITS 32
168#define NOUVEAU_SVM_BIND_TARGET_MASK 0xffffffff
169
170/*
171 * Below is use to validate ioctl argument, userspace can also use it to make
172 * sure that no bit are set beyond known fields for a given kernel version.
173 */
174#define NOUVEAU_SVM_BIND_VALID_BITS 48
175#define NOUVEAU_SVM_BIND_VALID_MASK ((1ULL << NOUVEAU_SVM_BIND_VALID_BITS) - 1)
176
177
178/*
179 * NOUVEAU_BIND_COMMAND__MIGRATE: synchronous migrate to target memory.
180 * result: number of page successfuly migrate to the target memory.
181 */
182#define NOUVEAU_SVM_BIND_COMMAND__MIGRATE 0
183
184/*
185 * NOUVEAU_SVM_BIND_HEADER_TARGET__GPU_VRAM: target the GPU VRAM memory.
186 */
187#define NOUVEAU_SVM_BIND_TARGET__GPU_VRAM (1UL << 31)
188
189
190#define DRM_IOCTL_NOUVEAU_SVM_INIT DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_SVM_INIT, struct drm_nouveau_svm_init)
191#define DRM_IOCTL_NOUVEAU_SVM_BIND DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_SVM_BIND, struct drm_nouveau_svm_bind)
192
142#define DRM_IOCTL_NOUVEAU_GEM_NEW DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_NEW, struct drm_nouveau_gem_new) 193#define DRM_IOCTL_NOUVEAU_GEM_NEW DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_NEW, struct drm_nouveau_gem_new)
143#define DRM_IOCTL_NOUVEAU_GEM_PUSHBUF DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_PUSHBUF, struct drm_nouveau_gem_pushbuf) 194#define DRM_IOCTL_NOUVEAU_GEM_PUSHBUF DRM_IOWR(DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_PUSHBUF, struct drm_nouveau_gem_pushbuf)
144#define DRM_IOCTL_NOUVEAU_GEM_CPU_PREP DRM_IOW (DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_CPU_PREP, struct drm_nouveau_gem_cpu_prep) 195#define DRM_IOCTL_NOUVEAU_GEM_CPU_PREP DRM_IOW (DRM_COMMAND_BASE + DRM_NOUVEAU_GEM_CPU_PREP, struct drm_nouveau_gem_cpu_prep)
diff --git a/include/uapi/drm/v3d_drm.h b/include/uapi/drm/v3d_drm.h
index 35c7d813c66e..ea70669d2138 100644
--- a/include/uapi/drm/v3d_drm.h
+++ b/include/uapi/drm/v3d_drm.h
@@ -52,6 +52,14 @@ extern "C" {
52 * 52 *
53 * This asks the kernel to have the GPU execute an optional binner 53 * This asks the kernel to have the GPU execute an optional binner
54 * command list, and a render command list. 54 * command list, and a render command list.
55 *
56 * The L1T, slice, L2C, L2T, and GCA caches will be flushed before
57 * each CL executes. The VCD cache should be flushed (if necessary)
58 * by the submitted CLs. The TLB writes are guaranteed to have been
59 * flushed by the time the render done IRQ happens, which is the
60 * trigger for out_sync. Any dirtying of cachelines by the job (only
61 * possible using TMU writes) must be flushed by the caller using the
62 * CL's cache flush commands.
55 */ 63 */
56struct drm_v3d_submit_cl { 64struct drm_v3d_submit_cl {
57 /* Pointer to the binner command list. 65 /* Pointer to the binner command list.
diff --git a/include/uapi/linux/android/binder.h b/include/uapi/linux/android/binder.h
index b9ba520f7e4b..2832134e5397 100644
--- a/include/uapi/linux/android/binder.h
+++ b/include/uapi/linux/android/binder.h
@@ -41,6 +41,14 @@ enum {
41enum { 41enum {
42 FLAT_BINDER_FLAG_PRIORITY_MASK = 0xff, 42 FLAT_BINDER_FLAG_PRIORITY_MASK = 0xff,
43 FLAT_BINDER_FLAG_ACCEPTS_FDS = 0x100, 43 FLAT_BINDER_FLAG_ACCEPTS_FDS = 0x100,
44
45 /**
46 * @FLAT_BINDER_FLAG_TXN_SECURITY_CTX: request security contexts
47 *
48 * Only when set, causes senders to include their security
49 * context
50 */
51 FLAT_BINDER_FLAG_TXN_SECURITY_CTX = 0x1000,
44}; 52};
45 53
46#ifdef BINDER_IPC_32BIT 54#ifdef BINDER_IPC_32BIT
@@ -218,6 +226,7 @@ struct binder_node_info_for_ref {
218#define BINDER_VERSION _IOWR('b', 9, struct binder_version) 226#define BINDER_VERSION _IOWR('b', 9, struct binder_version)
219#define BINDER_GET_NODE_DEBUG_INFO _IOWR('b', 11, struct binder_node_debug_info) 227#define BINDER_GET_NODE_DEBUG_INFO _IOWR('b', 11, struct binder_node_debug_info)
220#define BINDER_GET_NODE_INFO_FOR_REF _IOWR('b', 12, struct binder_node_info_for_ref) 228#define BINDER_GET_NODE_INFO_FOR_REF _IOWR('b', 12, struct binder_node_info_for_ref)
229#define BINDER_SET_CONTEXT_MGR_EXT _IOW('b', 13, struct flat_binder_object)
221 230
222/* 231/*
223 * NOTE: Two special error codes you should check for when calling 232 * NOTE: Two special error codes you should check for when calling
@@ -276,6 +285,11 @@ struct binder_transaction_data {
276 } data; 285 } data;
277}; 286};
278 287
288struct binder_transaction_data_secctx {
289 struct binder_transaction_data transaction_data;
290 binder_uintptr_t secctx;
291};
292
279struct binder_transaction_data_sg { 293struct binder_transaction_data_sg {
280 struct binder_transaction_data transaction_data; 294 struct binder_transaction_data transaction_data;
281 binder_size_t buffers_size; 295 binder_size_t buffers_size;
@@ -311,6 +325,11 @@ enum binder_driver_return_protocol {
311 BR_OK = _IO('r', 1), 325 BR_OK = _IO('r', 1),
312 /* No parameters! */ 326 /* No parameters! */
313 327
328 BR_TRANSACTION_SEC_CTX = _IOR('r', 2,
329 struct binder_transaction_data_secctx),
330 /*
331 * binder_transaction_data_secctx: the received command.
332 */
314 BR_TRANSACTION = _IOR('r', 2, struct binder_transaction_data), 333 BR_TRANSACTION = _IOR('r', 2, struct binder_transaction_data),
315 BR_REPLY = _IOR('r', 3, struct binder_transaction_data), 334 BR_REPLY = _IOR('r', 3, struct binder_transaction_data),
316 /* 335 /*
diff --git a/include/uapi/linux/auto_fs.h b/include/uapi/linux/auto_fs.h
index 082119630b49..1f7925afad2d 100644
--- a/include/uapi/linux/auto_fs.h
+++ b/include/uapi/linux/auto_fs.h
@@ -23,7 +23,7 @@
23#define AUTOFS_MIN_PROTO_VERSION 3 23#define AUTOFS_MIN_PROTO_VERSION 3
24#define AUTOFS_MAX_PROTO_VERSION 5 24#define AUTOFS_MAX_PROTO_VERSION 5
25 25
26#define AUTOFS_PROTO_SUBVERSION 4 26#define AUTOFS_PROTO_SUBVERSION 5
27 27
28/* 28/*
29 * The wait_queue_token (autofs_wqt_t) is part of a structure which is passed 29 * The wait_queue_token (autofs_wqt_t) is part of a structure which is passed
diff --git a/include/uapi/linux/batadv_packet.h b/include/uapi/linux/batadv_packet.h
index 894d8d2f713d..c99336f4eefe 100644
--- a/include/uapi/linux/batadv_packet.h
+++ b/include/uapi/linux/batadv_packet.h
@@ -1,5 +1,5 @@
1/* SPDX-License-Identifier: (GPL-2.0 WITH Linux-syscall-note) */ 1/* SPDX-License-Identifier: (GPL-2.0 WITH Linux-syscall-note) */
2/* Copyright (C) 2007-2018 B.A.T.M.A.N. contributors: 2/* Copyright (C) 2007-2019 B.A.T.M.A.N. contributors:
3 * 3 *
4 * Marek Lindner, Simon Wunderlich 4 * Marek Lindner, Simon Wunderlich
5 * 5 *
@@ -229,7 +229,7 @@ struct batadv_ogm_packet {
229 * @packet_type: batman-adv packet type, part of the general header 229 * @packet_type: batman-adv packet type, part of the general header
230 * @version: batman-adv protocol version, part of the general header 230 * @version: batman-adv protocol version, part of the general header
231 * @ttl: time to live for this packet, part of the general header 231 * @ttl: time to live for this packet, part of the general header
232 * @flags: reseved for routing relevant flags - currently always 0 232 * @flags: reserved for routing relevant flags - currently always 0
233 * @seqno: sequence number 233 * @seqno: sequence number
234 * @orig: originator mac address 234 * @orig: originator mac address
235 * @tvlv_len: length of the appended tvlv buffer (in bytes) 235 * @tvlv_len: length of the appended tvlv buffer (in bytes)
diff --git a/include/uapi/linux/batman_adv.h b/include/uapi/linux/batman_adv.h
index 324a0e1143e7..305bf316dd03 100644
--- a/include/uapi/linux/batman_adv.h
+++ b/include/uapi/linux/batman_adv.h
@@ -1,5 +1,5 @@
1/* SPDX-License-Identifier: MIT */ 1/* SPDX-License-Identifier: MIT */
2/* Copyright (C) 2016-2018 B.A.T.M.A.N. contributors: 2/* Copyright (C) 2016-2019 B.A.T.M.A.N. contributors:
3 * 3 *
4 * Matthias Schiffer 4 * Matthias Schiffer
5 * 5 *
@@ -27,6 +27,7 @@
27 27
28#define BATADV_NL_NAME "batadv" 28#define BATADV_NL_NAME "batadv"
29 29
30#define BATADV_NL_MCAST_GROUP_CONFIG "config"
30#define BATADV_NL_MCAST_GROUP_TPMETER "tpmeter" 31#define BATADV_NL_MCAST_GROUP_TPMETER "tpmeter"
31 32
32/** 33/**
@@ -139,6 +140,20 @@ enum batadv_mcast_flags_priv {
139}; 140};
140 141
141/** 142/**
143 * enum batadv_gw_modes - gateway mode of node
144 */
145enum batadv_gw_modes {
146 /** @BATADV_GW_MODE_OFF: gw mode disabled */
147 BATADV_GW_MODE_OFF,
148
149 /** @BATADV_GW_MODE_CLIENT: send DHCP requests to gw servers */
150 BATADV_GW_MODE_CLIENT,
151
152 /** @BATADV_GW_MODE_SERVER: announce itself as gatway server */
153 BATADV_GW_MODE_SERVER,
154};
155
156/**
142 * enum batadv_nl_attrs - batman-adv netlink attributes 157 * enum batadv_nl_attrs - batman-adv netlink attributes
143 */ 158 */
144enum batadv_nl_attrs { 159enum batadv_nl_attrs {
@@ -344,6 +359,138 @@ enum batadv_nl_attrs {
344 */ 359 */
345 BATADV_ATTR_MCAST_FLAGS_PRIV, 360 BATADV_ATTR_MCAST_FLAGS_PRIV,
346 361
362 /**
363 * @BATADV_ATTR_VLANID: VLAN id on top of soft interface
364 */
365 BATADV_ATTR_VLANID,
366
367 /**
368 * @BATADV_ATTR_AGGREGATED_OGMS_ENABLED: whether the batman protocol
369 * messages of the mesh interface shall be aggregated or not.
370 */
371 BATADV_ATTR_AGGREGATED_OGMS_ENABLED,
372
373 /**
374 * @BATADV_ATTR_AP_ISOLATION_ENABLED: whether the data traffic going
375 * from a wireless client to another wireless client will be silently
376 * dropped.
377 */
378 BATADV_ATTR_AP_ISOLATION_ENABLED,
379
380 /**
381 * @BATADV_ATTR_ISOLATION_MARK: the isolation mark which is used to
382 * classify clients as "isolated" by the Extended Isolation feature.
383 */
384 BATADV_ATTR_ISOLATION_MARK,
385
386 /**
387 * @BATADV_ATTR_ISOLATION_MASK: the isolation (bit)mask which is used to
388 * classify clients as "isolated" by the Extended Isolation feature.
389 */
390 BATADV_ATTR_ISOLATION_MASK,
391
392 /**
393 * @BATADV_ATTR_BONDING_ENABLED: whether the data traffic going through
394 * the mesh will be sent using multiple interfaces at the same time.
395 */
396 BATADV_ATTR_BONDING_ENABLED,
397
398 /**
399 * @BATADV_ATTR_BRIDGE_LOOP_AVOIDANCE_ENABLED: whether the bridge loop
400 * avoidance feature is enabled. This feature detects and avoids loops
401 * between the mesh and devices bridged with the soft interface
402 */
403 BATADV_ATTR_BRIDGE_LOOP_AVOIDANCE_ENABLED,
404
405 /**
406 * @BATADV_ATTR_DISTRIBUTED_ARP_TABLE_ENABLED: whether the distributed
407 * arp table feature is enabled. This feature uses a distributed hash
408 * table to answer ARP requests without flooding the request through
409 * the whole mesh.
410 */
411 BATADV_ATTR_DISTRIBUTED_ARP_TABLE_ENABLED,
412
413 /**
414 * @BATADV_ATTR_FRAGMENTATION_ENABLED: whether the data traffic going
415 * through the mesh will be fragmented or silently discarded if the
416 * packet size exceeds the outgoing interface MTU.
417 */
418 BATADV_ATTR_FRAGMENTATION_ENABLED,
419
420 /**
421 * @BATADV_ATTR_GW_BANDWIDTH_DOWN: defines the download bandwidth which
422 * is propagated by this node if %BATADV_ATTR_GW_BANDWIDTH_MODE was set
423 * to 'server'.
424 */
425 BATADV_ATTR_GW_BANDWIDTH_DOWN,
426
427 /**
428 * @BATADV_ATTR_GW_BANDWIDTH_UP: defines the upload bandwidth which
429 * is propagated by this node if %BATADV_ATTR_GW_BANDWIDTH_MODE was set
430 * to 'server'.
431 */
432 BATADV_ATTR_GW_BANDWIDTH_UP,
433
434 /**
435 * @BATADV_ATTR_GW_MODE: defines the state of the gateway features.
436 * Possible values are specified in enum batadv_gw_modes
437 */
438 BATADV_ATTR_GW_MODE,
439
440 /**
441 * @BATADV_ATTR_GW_SEL_CLASS: defines the selection criteria this node
442 * will use to choose a gateway if gw_mode was set to 'client'.
443 */
444 BATADV_ATTR_GW_SEL_CLASS,
445
446 /**
447 * @BATADV_ATTR_HOP_PENALTY: defines the penalty which will be applied
448 * to an originator message's tq-field on every hop.
449 */
450 BATADV_ATTR_HOP_PENALTY,
451
452 /**
453 * @BATADV_ATTR_LOG_LEVEL: bitmask with to define which debug messages
454 * should be send to the debug log/trace ring buffer
455 */
456 BATADV_ATTR_LOG_LEVEL,
457
458 /**
459 * @BATADV_ATTR_MULTICAST_FORCEFLOOD_ENABLED: whether multicast
460 * optimizations should be replaced by simple broadcast-like flooding
461 * of multicast packets. If set to non-zero then all nodes in the mesh
462 * are going to use classic flooding for any multicast packet with no
463 * optimizations.
464 */
465 BATADV_ATTR_MULTICAST_FORCEFLOOD_ENABLED,
466
467 /**
468 * @BATADV_ATTR_NETWORK_CODING_ENABLED: whether Network Coding (using
469 * some magic to send fewer wifi packets but still the same content) is
470 * enabled or not.
471 */
472 BATADV_ATTR_NETWORK_CODING_ENABLED,
473
474 /**
475 * @BATADV_ATTR_ORIG_INTERVAL: defines the interval in milliseconds in
476 * which batman sends its protocol messages.
477 */
478 BATADV_ATTR_ORIG_INTERVAL,
479
480 /**
481 * @BATADV_ATTR_ELP_INTERVAL: defines the interval in milliseconds in
482 * which batman emits probing packets for neighbor sensing (ELP).
483 */
484 BATADV_ATTR_ELP_INTERVAL,
485
486 /**
487 * @BATADV_ATTR_THROUGHPUT_OVERRIDE: defines the throughput value to be
488 * used by B.A.T.M.A.N. V when estimating the link throughput using
489 * this interface. If the value is set to 0 then batman-adv will try to
490 * estimate the throughput by itself.
491 */
492 BATADV_ATTR_THROUGHPUT_OVERRIDE,
493
347 /* add attributes above here, update the policy in netlink.c */ 494 /* add attributes above here, update the policy in netlink.c */
348 495
349 /** 496 /**
@@ -372,10 +519,14 @@ enum batadv_nl_commands {
372 BATADV_CMD_UNSPEC, 519 BATADV_CMD_UNSPEC,
373 520
374 /** 521 /**
375 * @BATADV_CMD_GET_MESH_INFO: Query basic information about batman-adv 522 * @BATADV_CMD_GET_MESH: Get attributes from softif/mesh
376 * device 523 */
524 BATADV_CMD_GET_MESH,
525
526 /**
527 * @BATADV_CMD_GET_MESH_INFO: Alias for @BATADV_CMD_GET_MESH
377 */ 528 */
378 BATADV_CMD_GET_MESH_INFO, 529 BATADV_CMD_GET_MESH_INFO = BATADV_CMD_GET_MESH,
379 530
380 /** 531 /**
381 * @BATADV_CMD_TP_METER: Start a tp meter session 532 * @BATADV_CMD_TP_METER: Start a tp meter session
@@ -393,9 +544,15 @@ enum batadv_nl_commands {
393 BATADV_CMD_GET_ROUTING_ALGOS, 544 BATADV_CMD_GET_ROUTING_ALGOS,
394 545
395 /** 546 /**
396 * @BATADV_CMD_GET_HARDIFS: Query list of hard interfaces 547 * @BATADV_CMD_GET_HARDIF: Get attributes from a hardif of the
548 * current softif
397 */ 549 */
398 BATADV_CMD_GET_HARDIFS, 550 BATADV_CMD_GET_HARDIF,
551
552 /**
553 * @BATADV_CMD_GET_HARDIFS: Alias for @BATADV_CMD_GET_HARDIF
554 */
555 BATADV_CMD_GET_HARDIFS = BATADV_CMD_GET_HARDIF,
399 556
400 /** 557 /**
401 * @BATADV_CMD_GET_TRANSTABLE_LOCAL: Query list of local translations 558 * @BATADV_CMD_GET_TRANSTABLE_LOCAL: Query list of local translations
@@ -443,6 +600,29 @@ enum batadv_nl_commands {
443 */ 600 */
444 BATADV_CMD_GET_MCAST_FLAGS, 601 BATADV_CMD_GET_MCAST_FLAGS,
445 602
603 /**
604 * @BATADV_CMD_SET_MESH: Set attributes for softif/mesh
605 */
606 BATADV_CMD_SET_MESH,
607
608 /**
609 * @BATADV_CMD_SET_HARDIF: Set attributes for hardif of the
610 * current softif
611 */
612 BATADV_CMD_SET_HARDIF,
613
614 /**
615 * @BATADV_CMD_GET_VLAN: Get attributes from a VLAN of the
616 * current softif
617 */
618 BATADV_CMD_GET_VLAN,
619
620 /**
621 * @BATADV_CMD_SET_VLAN: Set attributes for VLAN of the
622 * current softif
623 */
624 BATADV_CMD_SET_VLAN,
625
446 /* add new commands above here */ 626 /* add new commands above here */
447 627
448 /** 628 /**
diff --git a/include/uapi/linux/binfmts.h b/include/uapi/linux/binfmts.h
index 4abad03a8853..689025d9c185 100644
--- a/include/uapi/linux/binfmts.h
+++ b/include/uapi/linux/binfmts.h
@@ -16,6 +16,6 @@ struct pt_regs;
16#define MAX_ARG_STRINGS 0x7FFFFFFF 16#define MAX_ARG_STRINGS 0x7FFFFFFF
17 17
18/* sizeof(linux_binprm->buf) */ 18/* sizeof(linux_binprm->buf) */
19#define BINPRM_BUF_SIZE 128 19#define BINPRM_BUF_SIZE 256
20 20
21#endif /* _UAPI_LINUX_BINFMTS_H */ 21#endif /* _UAPI_LINUX_BINFMTS_H */
diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h
index 91c43884f295..3c38ac9a92a7 100644
--- a/include/uapi/linux/bpf.h
+++ b/include/uapi/linux/bpf.h
@@ -14,6 +14,7 @@
14/* Extended instruction set based on top of classic BPF */ 14/* Extended instruction set based on top of classic BPF */
15 15
16/* instruction classes */ 16/* instruction classes */
17#define BPF_JMP32 0x06 /* jmp mode in word width */
17#define BPF_ALU64 0x07 /* alu mode in double word width */ 18#define BPF_ALU64 0x07 /* alu mode in double word width */
18 19
19/* ld/ldx fields */ 20/* ld/ldx fields */
@@ -266,6 +267,7 @@ enum bpf_attach_type {
266#define BPF_ANY 0 /* create new element or update existing */ 267#define BPF_ANY 0 /* create new element or update existing */
267#define BPF_NOEXIST 1 /* create new element if it didn't exist */ 268#define BPF_NOEXIST 1 /* create new element if it didn't exist */
268#define BPF_EXIST 2 /* update existing element */ 269#define BPF_EXIST 2 /* update existing element */
270#define BPF_F_LOCK 4 /* spin_lock-ed map_lookup/map_update */
269 271
270/* flags for BPF_MAP_CREATE command */ 272/* flags for BPF_MAP_CREATE command */
271#define BPF_F_NO_PREALLOC (1U << 0) 273#define BPF_F_NO_PREALLOC (1U << 0)
@@ -2014,6 +2016,19 @@ union bpf_attr {
2014 * Only works if *skb* contains an IPv6 packet. Insert a 2016 * Only works if *skb* contains an IPv6 packet. Insert a
2015 * Segment Routing Header (**struct ipv6_sr_hdr**) inside 2017 * Segment Routing Header (**struct ipv6_sr_hdr**) inside
2016 * the IPv6 header. 2018 * the IPv6 header.
2019 * **BPF_LWT_ENCAP_IP**
2020 * IP encapsulation (GRE/GUE/IPIP/etc). The outer header
2021 * must be IPv4 or IPv6, followed by zero or more
2022 * additional headers, up to LWT_BPF_MAX_HEADROOM total
2023 * bytes in all prepended headers. Please note that
2024 * if skb_is_gso(skb) is true, no more than two headers
2025 * can be prepended, and the inner header, if present,
2026 * should be either GRE or UDP/GUE.
2027 *
2028 * BPF_LWT_ENCAP_SEG6*** types can be called by bpf programs of
2029 * type BPF_PROG_TYPE_LWT_IN; BPF_LWT_ENCAP_IP type can be called
2030 * by bpf programs of types BPF_PROG_TYPE_LWT_IN and
2031 * BPF_PROG_TYPE_LWT_XMIT.
2017 * 2032 *
2018 * A call to this helper is susceptible to change the underlaying 2033 * A call to this helper is susceptible to change the underlaying
2019 * packet buffer. Therefore, at load time, all checks on pointers 2034 * packet buffer. Therefore, at load time, all checks on pointers
@@ -2327,6 +2342,30 @@ union bpf_attr {
2327 * "**y**". 2342 * "**y**".
2328 * Return 2343 * Return
2329 * 0 2344 * 0
2345 *
2346 * struct bpf_sock *bpf_sk_fullsock(struct bpf_sock *sk)
2347 * Description
2348 * This helper gets a **struct bpf_sock** pointer such
2349 * that all the fields in bpf_sock can be accessed.
2350 * Return
2351 * A **struct bpf_sock** pointer on success, or NULL in
2352 * case of failure.
2353 *
2354 * struct bpf_tcp_sock *bpf_tcp_sock(struct bpf_sock *sk)
2355 * Description
2356 * This helper gets a **struct bpf_tcp_sock** pointer from a
2357 * **struct bpf_sock** pointer.
2358 *
2359 * Return
2360 * A **struct bpf_tcp_sock** pointer on success, or NULL in
2361 * case of failure.
2362 *
2363 * int bpf_skb_ecn_set_ce(struct sk_buf *skb)
2364 * Description
2365 * Sets ECN of IP header to ce (congestion encountered) if
2366 * current value is ect (ECN capable). Works with IPv6 and IPv4.
2367 * Return
2368 * 1 if set, 0 if not set.
2330 */ 2369 */
2331#define __BPF_FUNC_MAPPER(FN) \ 2370#define __BPF_FUNC_MAPPER(FN) \
2332 FN(unspec), \ 2371 FN(unspec), \
@@ -2421,7 +2460,12 @@ union bpf_attr {
2421 FN(map_peek_elem), \ 2460 FN(map_peek_elem), \
2422 FN(msg_push_data), \ 2461 FN(msg_push_data), \
2423 FN(msg_pop_data), \ 2462 FN(msg_pop_data), \
2424 FN(rc_pointer_rel), 2463 FN(rc_pointer_rel), \
2464 FN(spin_lock), \
2465 FN(spin_unlock), \
2466 FN(sk_fullsock), \
2467 FN(tcp_sock), \
2468 FN(skb_ecn_set_ce),
2425 2469
2426/* integer value in 'imm' field of BPF_CALL instruction selects which helper 2470/* integer value in 'imm' field of BPF_CALL instruction selects which helper
2427 * function eBPF program intends to call 2471 * function eBPF program intends to call
@@ -2494,7 +2538,8 @@ enum bpf_hdr_start_off {
2494/* Encapsulation type for BPF_FUNC_lwt_push_encap helper. */ 2538/* Encapsulation type for BPF_FUNC_lwt_push_encap helper. */
2495enum bpf_lwt_encap_mode { 2539enum bpf_lwt_encap_mode {
2496 BPF_LWT_ENCAP_SEG6, 2540 BPF_LWT_ENCAP_SEG6,
2497 BPF_LWT_ENCAP_SEG6_INLINE 2541 BPF_LWT_ENCAP_SEG6_INLINE,
2542 BPF_LWT_ENCAP_IP,
2498}; 2543};
2499 2544
2500#define __bpf_md_ptr(type, name) \ 2545#define __bpf_md_ptr(type, name) \
@@ -2540,6 +2585,8 @@ struct __sk_buff {
2540 __bpf_md_ptr(struct bpf_flow_keys *, flow_keys); 2585 __bpf_md_ptr(struct bpf_flow_keys *, flow_keys);
2541 __u64 tstamp; 2586 __u64 tstamp;
2542 __u32 wire_len; 2587 __u32 wire_len;
2588 __u32 gso_segs;
2589 __bpf_md_ptr(struct bpf_sock *, sk);
2543}; 2590};
2544 2591
2545struct bpf_tunnel_key { 2592struct bpf_tunnel_key {
@@ -2581,7 +2628,15 @@ enum bpf_ret_code {
2581 BPF_DROP = 2, 2628 BPF_DROP = 2,
2582 /* 3-6 reserved */ 2629 /* 3-6 reserved */
2583 BPF_REDIRECT = 7, 2630 BPF_REDIRECT = 7,
2584 /* >127 are reserved for prog type specific return codes */ 2631 /* >127 are reserved for prog type specific return codes.
2632 *
2633 * BPF_LWT_REROUTE: used by BPF_PROG_TYPE_LWT_IN and
2634 * BPF_PROG_TYPE_LWT_XMIT to indicate that skb had been
2635 * changed and should be routed based on its new L3 header.
2636 * (This is an L3 redirect, as opposed to L2 redirect
2637 * represented by BPF_REDIRECT above).
2638 */
2639 BPF_LWT_REROUTE = 128,
2585}; 2640};
2586 2641
2587struct bpf_sock { 2642struct bpf_sock {
@@ -2591,14 +2646,52 @@ struct bpf_sock {
2591 __u32 protocol; 2646 __u32 protocol;
2592 __u32 mark; 2647 __u32 mark;
2593 __u32 priority; 2648 __u32 priority;
2594 __u32 src_ip4; /* Allows 1,2,4-byte read. 2649 /* IP address also allows 1 and 2 bytes access */
2595 * Stored in network byte order. 2650 __u32 src_ip4;
2651 __u32 src_ip6[4];
2652 __u32 src_port; /* host byte order */
2653 __u32 dst_port; /* network byte order */
2654 __u32 dst_ip4;
2655 __u32 dst_ip6[4];
2656 __u32 state;
2657};
2658
2659struct bpf_tcp_sock {
2660 __u32 snd_cwnd; /* Sending congestion window */
2661 __u32 srtt_us; /* smoothed round trip time << 3 in usecs */
2662 __u32 rtt_min;
2663 __u32 snd_ssthresh; /* Slow start size threshold */
2664 __u32 rcv_nxt; /* What we want to receive next */
2665 __u32 snd_nxt; /* Next sequence we send */
2666 __u32 snd_una; /* First byte we want an ack for */
2667 __u32 mss_cache; /* Cached effective mss, not including SACKS */
2668 __u32 ecn_flags; /* ECN status bits. */
2669 __u32 rate_delivered; /* saved rate sample: packets delivered */
2670 __u32 rate_interval_us; /* saved rate sample: time elapsed */
2671 __u32 packets_out; /* Packets which are "in flight" */
2672 __u32 retrans_out; /* Retransmitted packets out */
2673 __u32 total_retrans; /* Total retransmits for entire connection */
2674 __u32 segs_in; /* RFC4898 tcpEStatsPerfSegsIn
2675 * total number of segments in.
2596 */ 2676 */
2597 __u32 src_ip6[4]; /* Allows 1,2,4-byte read. 2677 __u32 data_segs_in; /* RFC4898 tcpEStatsPerfDataSegsIn
2598 * Stored in network byte order. 2678 * total number of data segments in.
2599 */ 2679 */
2600 __u32 src_port; /* Allows 4-byte read. 2680 __u32 segs_out; /* RFC4898 tcpEStatsPerfSegsOut
2601 * Stored in host byte order 2681 * The total number of segments sent.
2682 */
2683 __u32 data_segs_out; /* RFC4898 tcpEStatsPerfDataSegsOut
2684 * total number of data segments sent.
2685 */
2686 __u32 lost_out; /* Lost packets */
2687 __u32 sacked_out; /* SACK'd packets */
2688 __u64 bytes_received; /* RFC4898 tcpEStatsAppHCThruOctetsReceived
2689 * sum(delta(rcv_nxt)), or how many bytes
2690 * were acked.
2691 */
2692 __u64 bytes_acked; /* RFC4898 tcpEStatsAppHCThruOctetsAcked
2693 * sum(delta(snd_una)), or how many bytes
2694 * were acked.
2602 */ 2695 */
2603}; 2696};
2604 2697
@@ -2728,6 +2821,8 @@ struct bpf_prog_info {
2728 __u32 jited_line_info_rec_size; 2821 __u32 jited_line_info_rec_size;
2729 __u32 nr_prog_tags; 2822 __u32 nr_prog_tags;
2730 __aligned_u64 prog_tags; 2823 __aligned_u64 prog_tags;
2824 __u64 run_time_ns;
2825 __u64 run_cnt;
2731} __attribute__((aligned(8))); 2826} __attribute__((aligned(8)));
2732 2827
2733struct bpf_map_info { 2828struct bpf_map_info {
@@ -3054,4 +3149,7 @@ struct bpf_line_info {
3054 __u32 line_col; 3149 __u32 line_col;
3055}; 3150};
3056 3151
3152struct bpf_spin_lock {
3153 __u32 val;
3154};
3057#endif /* _UAPI__LINUX_BPF_H__ */ 3155#endif /* _UAPI__LINUX_BPF_H__ */
diff --git a/include/uapi/linux/btrfs.h b/include/uapi/linux/btrfs.h
index e0763bc4158e..c195896d478f 100644
--- a/include/uapi/linux/btrfs.h
+++ b/include/uapi/linux/btrfs.h
@@ -837,6 +837,8 @@ enum btrfs_err_code {
837 struct btrfs_ioctl_vol_args) 837 struct btrfs_ioctl_vol_args)
838#define BTRFS_IOC_SCAN_DEV _IOW(BTRFS_IOCTL_MAGIC, 4, \ 838#define BTRFS_IOC_SCAN_DEV _IOW(BTRFS_IOCTL_MAGIC, 4, \
839 struct btrfs_ioctl_vol_args) 839 struct btrfs_ioctl_vol_args)
840#define BTRFS_IOC_FORGET_DEV _IOW(BTRFS_IOCTL_MAGIC, 5, \
841 struct btrfs_ioctl_vol_args)
840/* trans start and trans end are dangerous, and only for 842/* trans start and trans end are dangerous, and only for
841 * use by applications that know how to avoid the 843 * use by applications that know how to avoid the
842 * resulting deadlocks 844 * resulting deadlocks
diff --git a/include/uapi/linux/devlink.h b/include/uapi/linux/devlink.h
index 6e52d3660654..5bb4ea67d84f 100644
--- a/include/uapi/linux/devlink.h
+++ b/include/uapi/linux/devlink.h
@@ -89,6 +89,22 @@ enum devlink_command {
89 DEVLINK_CMD_REGION_DEL, 89 DEVLINK_CMD_REGION_DEL,
90 DEVLINK_CMD_REGION_READ, 90 DEVLINK_CMD_REGION_READ,
91 91
92 DEVLINK_CMD_PORT_PARAM_GET, /* can dump */
93 DEVLINK_CMD_PORT_PARAM_SET,
94 DEVLINK_CMD_PORT_PARAM_NEW,
95 DEVLINK_CMD_PORT_PARAM_DEL,
96
97 DEVLINK_CMD_INFO_GET, /* can dump */
98
99 DEVLINK_CMD_HEALTH_REPORTER_GET,
100 DEVLINK_CMD_HEALTH_REPORTER_SET,
101 DEVLINK_CMD_HEALTH_REPORTER_RECOVER,
102 DEVLINK_CMD_HEALTH_REPORTER_DIAGNOSE,
103 DEVLINK_CMD_HEALTH_REPORTER_DUMP_GET,
104 DEVLINK_CMD_HEALTH_REPORTER_DUMP_CLEAR,
105
106 DEVLINK_CMD_FLASH_UPDATE,
107
92 /* add new commands above here */ 108 /* add new commands above here */
93 __DEVLINK_CMD_MAX, 109 __DEVLINK_CMD_MAX,
94 DEVLINK_CMD_MAX = __DEVLINK_CMD_MAX - 1 110 DEVLINK_CMD_MAX = __DEVLINK_CMD_MAX - 1
@@ -285,6 +301,37 @@ enum devlink_attr {
285 DEVLINK_ATTR_REGION_CHUNK_ADDR, /* u64 */ 301 DEVLINK_ATTR_REGION_CHUNK_ADDR, /* u64 */
286 DEVLINK_ATTR_REGION_CHUNK_LEN, /* u64 */ 302 DEVLINK_ATTR_REGION_CHUNK_LEN, /* u64 */
287 303
304 DEVLINK_ATTR_INFO_DRIVER_NAME, /* string */
305 DEVLINK_ATTR_INFO_SERIAL_NUMBER, /* string */
306 DEVLINK_ATTR_INFO_VERSION_FIXED, /* nested */
307 DEVLINK_ATTR_INFO_VERSION_RUNNING, /* nested */
308 DEVLINK_ATTR_INFO_VERSION_STORED, /* nested */
309 DEVLINK_ATTR_INFO_VERSION_NAME, /* string */
310 DEVLINK_ATTR_INFO_VERSION_VALUE, /* string */
311
312 DEVLINK_ATTR_SB_POOL_CELL_SIZE, /* u32 */
313
314 DEVLINK_ATTR_FMSG, /* nested */
315 DEVLINK_ATTR_FMSG_OBJ_NEST_START, /* flag */
316 DEVLINK_ATTR_FMSG_PAIR_NEST_START, /* flag */
317 DEVLINK_ATTR_FMSG_ARR_NEST_START, /* flag */
318 DEVLINK_ATTR_FMSG_NEST_END, /* flag */
319 DEVLINK_ATTR_FMSG_OBJ_NAME, /* string */
320 DEVLINK_ATTR_FMSG_OBJ_VALUE_TYPE, /* u8 */
321 DEVLINK_ATTR_FMSG_OBJ_VALUE_DATA, /* dynamic */
322
323 DEVLINK_ATTR_HEALTH_REPORTER, /* nested */
324 DEVLINK_ATTR_HEALTH_REPORTER_NAME, /* string */
325 DEVLINK_ATTR_HEALTH_REPORTER_STATE, /* u8 */
326 DEVLINK_ATTR_HEALTH_REPORTER_ERR_COUNT, /* u64 */
327 DEVLINK_ATTR_HEALTH_REPORTER_RECOVER_COUNT, /* u64 */
328 DEVLINK_ATTR_HEALTH_REPORTER_DUMP_TS, /* u64 */
329 DEVLINK_ATTR_HEALTH_REPORTER_GRACEFUL_PERIOD, /* u64 */
330 DEVLINK_ATTR_HEALTH_REPORTER_AUTO_RECOVER, /* u8 */
331
332 DEVLINK_ATTR_FLASH_UPDATE_FILE_NAME, /* string */
333 DEVLINK_ATTR_FLASH_UPDATE_COMPONENT, /* string */
334
288 /* add new attributes above here, update the policy in devlink.c */ 335 /* add new attributes above here, update the policy in devlink.c */
289 336
290 __DEVLINK_ATTR_MAX, 337 __DEVLINK_ATTR_MAX,
diff --git a/include/uapi/linux/dm-ioctl.h b/include/uapi/linux/dm-ioctl.h
index d1e49514977b..f396a82dfd3e 100644
--- a/include/uapi/linux/dm-ioctl.h
+++ b/include/uapi/linux/dm-ioctl.h
@@ -270,9 +270,9 @@ enum {
270#define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl) 270#define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl)
271 271
272#define DM_VERSION_MAJOR 4 272#define DM_VERSION_MAJOR 4
273#define DM_VERSION_MINOR 39 273#define DM_VERSION_MINOR 40
274#define DM_VERSION_PATCHLEVEL 0 274#define DM_VERSION_PATCHLEVEL 0
275#define DM_VERSION_EXTRA "-ioctl (2018-04-03)" 275#define DM_VERSION_EXTRA "-ioctl (2019-01-18)"
276 276
277/* Status bits */ 277/* Status bits */
278#define DM_READONLY_FLAG (1 << 0) /* In/Out */ 278#define DM_READONLY_FLAG (1 << 0) /* In/Out */
diff --git a/include/uapi/linux/elf.h b/include/uapi/linux/elf.h
index e4d6ddd93567..34c02e4290fe 100644
--- a/include/uapi/linux/elf.h
+++ b/include/uapi/linux/elf.h
@@ -421,6 +421,8 @@ typedef struct elf64_shdr {
421#define NT_ARM_SYSTEM_CALL 0x404 /* ARM system call number */ 421#define NT_ARM_SYSTEM_CALL 0x404 /* ARM system call number */
422#define NT_ARM_SVE 0x405 /* ARM Scalable Vector Extension registers */ 422#define NT_ARM_SVE 0x405 /* ARM Scalable Vector Extension registers */
423#define NT_ARM_PAC_MASK 0x406 /* ARM pointer authentication code masks */ 423#define NT_ARM_PAC_MASK 0x406 /* ARM pointer authentication code masks */
424#define NT_ARM_PACA_KEYS 0x407 /* ARM pointer authentication address keys */
425#define NT_ARM_PACG_KEYS 0x408 /* ARM pointer authentication generic key */
424#define NT_ARC_V2 0x600 /* ARCv2 accumulator/extra registers */ 426#define NT_ARC_V2 0x600 /* ARCv2 accumulator/extra registers */
425#define NT_VMCOREDD 0x700 /* Vmcore Device Dump Note */ 427#define NT_VMCOREDD 0x700 /* Vmcore Device Dump Note */
426#define NT_MIPS_DSP 0x800 /* MIPS DSP ASE registers */ 428#define NT_MIPS_DSP 0x800 /* MIPS DSP ASE registers */
diff --git a/include/uapi/linux/errqueue.h b/include/uapi/linux/errqueue.h
index c0151200f7d1..28491dac074b 100644
--- a/include/uapi/linux/errqueue.h
+++ b/include/uapi/linux/errqueue.h
@@ -3,6 +3,7 @@
3#define _UAPI_LINUX_ERRQUEUE_H 3#define _UAPI_LINUX_ERRQUEUE_H
4 4
5#include <linux/types.h> 5#include <linux/types.h>
6#include <linux/time_types.h>
6 7
7struct sock_extended_err { 8struct sock_extended_err {
8 __u32 ee_errno; 9 __u32 ee_errno;
@@ -41,6 +42,10 @@ struct scm_timestamping {
41 struct timespec ts[3]; 42 struct timespec ts[3];
42}; 43};
43 44
45struct scm_timestamping64 {
46 struct __kernel_timespec ts[3];
47};
48
44/* The type of scm_timestamping, passed in sock_extended_err ee_info. 49/* The type of scm_timestamping, passed in sock_extended_err ee_info.
45 * This defines the type of ts[0]. For SCM_TSTAMP_SND only, if ts[0] 50 * This defines the type of ts[0]. For SCM_TSTAMP_SND only, if ts[0]
46 * is zero, then this is a hardware timestamp and recorded in ts[2]. 51 * is zero, then this is a hardware timestamp and recorded in ts[2].
diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h
index 17be76aeb468..3652b239dad1 100644
--- a/include/uapi/linux/ethtool.h
+++ b/include/uapi/linux/ethtool.h
@@ -1432,6 +1432,13 @@ enum ethtool_link_mode_bit_indices {
1432 ETHTOOL_LINK_MODE_56000baseSR4_Full_BIT = 29, 1432 ETHTOOL_LINK_MODE_56000baseSR4_Full_BIT = 29,
1433 ETHTOOL_LINK_MODE_56000baseLR4_Full_BIT = 30, 1433 ETHTOOL_LINK_MODE_56000baseLR4_Full_BIT = 30,
1434 ETHTOOL_LINK_MODE_25000baseCR_Full_BIT = 31, 1434 ETHTOOL_LINK_MODE_25000baseCR_Full_BIT = 31,
1435
1436 /* Last allowed bit for __ETHTOOL_LINK_MODE_LEGACY_MASK is bit
1437 * 31. Please do NOT define any SUPPORTED_* or ADVERTISED_*
1438 * macro for bits > 31. The only way to use indices > 31 is to
1439 * use the new ETHTOOL_GLINKSETTINGS/ETHTOOL_SLINKSETTINGS API.
1440 */
1441
1435 ETHTOOL_LINK_MODE_25000baseKR_Full_BIT = 32, 1442 ETHTOOL_LINK_MODE_25000baseKR_Full_BIT = 32,
1436 ETHTOOL_LINK_MODE_25000baseSR_Full_BIT = 33, 1443 ETHTOOL_LINK_MODE_25000baseSR_Full_BIT = 33,
1437 ETHTOOL_LINK_MODE_50000baseCR2_Full_BIT = 34, 1444 ETHTOOL_LINK_MODE_50000baseCR2_Full_BIT = 34,
@@ -1453,15 +1460,24 @@ enum ethtool_link_mode_bit_indices {
1453 ETHTOOL_LINK_MODE_FEC_NONE_BIT = 49, 1460 ETHTOOL_LINK_MODE_FEC_NONE_BIT = 49,
1454 ETHTOOL_LINK_MODE_FEC_RS_BIT = 50, 1461 ETHTOOL_LINK_MODE_FEC_RS_BIT = 50,
1455 ETHTOOL_LINK_MODE_FEC_BASER_BIT = 51, 1462 ETHTOOL_LINK_MODE_FEC_BASER_BIT = 51,
1456 1463 ETHTOOL_LINK_MODE_50000baseKR_Full_BIT = 52,
1457 /* Last allowed bit for __ETHTOOL_LINK_MODE_LEGACY_MASK is bit 1464 ETHTOOL_LINK_MODE_50000baseSR_Full_BIT = 53,
1458 * 31. Please do NOT define any SUPPORTED_* or ADVERTISED_* 1465 ETHTOOL_LINK_MODE_50000baseCR_Full_BIT = 54,
1459 * macro for bits > 31. The only way to use indices > 31 is to 1466 ETHTOOL_LINK_MODE_50000baseLR_ER_FR_Full_BIT = 55,
1460 * use the new ETHTOOL_GLINKSETTINGS/ETHTOOL_SLINKSETTINGS API. 1467 ETHTOOL_LINK_MODE_50000baseDR_Full_BIT = 56,
1461 */ 1468 ETHTOOL_LINK_MODE_100000baseKR2_Full_BIT = 57,
1462 1469 ETHTOOL_LINK_MODE_100000baseSR2_Full_BIT = 58,
1463 __ETHTOOL_LINK_MODE_LAST 1470 ETHTOOL_LINK_MODE_100000baseCR2_Full_BIT = 59,
1464 = ETHTOOL_LINK_MODE_FEC_BASER_BIT, 1471 ETHTOOL_LINK_MODE_100000baseLR2_ER2_FR2_Full_BIT = 60,
1472 ETHTOOL_LINK_MODE_100000baseDR2_Full_BIT = 61,
1473 ETHTOOL_LINK_MODE_200000baseKR4_Full_BIT = 62,
1474 ETHTOOL_LINK_MODE_200000baseSR4_Full_BIT = 63,
1475 ETHTOOL_LINK_MODE_200000baseLR4_ER4_FR4_Full_BIT = 64,
1476 ETHTOOL_LINK_MODE_200000baseDR4_Full_BIT = 65,
1477 ETHTOOL_LINK_MODE_200000baseCR4_Full_BIT = 66,
1478
1479 /* must be last entry */
1480 __ETHTOOL_LINK_MODE_MASK_NBITS
1465}; 1481};
1466 1482
1467#define __ETHTOOL_LINK_MODE_LEGACY_MASK(base_name) \ 1483#define __ETHTOOL_LINK_MODE_LEGACY_MASK(base_name) \
@@ -1569,6 +1585,7 @@ enum ethtool_link_mode_bit_indices {
1569#define SPEED_50000 50000 1585#define SPEED_50000 50000
1570#define SPEED_56000 56000 1586#define SPEED_56000 56000
1571#define SPEED_100000 100000 1587#define SPEED_100000 100000
1588#define SPEED_200000 200000
1572 1589
1573#define SPEED_UNKNOWN -1 1590#define SPEED_UNKNOWN -1
1574 1591
diff --git a/include/uapi/linux/fanotify.h b/include/uapi/linux/fanotify.h
index 909c98fcace2..b9effa6f8503 100644
--- a/include/uapi/linux/fanotify.h
+++ b/include/uapi/linux/fanotify.h
@@ -7,9 +7,16 @@
7/* the following events that user-space can register for */ 7/* the following events that user-space can register for */
8#define FAN_ACCESS 0x00000001 /* File was accessed */ 8#define FAN_ACCESS 0x00000001 /* File was accessed */
9#define FAN_MODIFY 0x00000002 /* File was modified */ 9#define FAN_MODIFY 0x00000002 /* File was modified */
10#define FAN_ATTRIB 0x00000004 /* Metadata changed */
10#define FAN_CLOSE_WRITE 0x00000008 /* Writtable file closed */ 11#define FAN_CLOSE_WRITE 0x00000008 /* Writtable file closed */
11#define FAN_CLOSE_NOWRITE 0x00000010 /* Unwrittable file closed */ 12#define FAN_CLOSE_NOWRITE 0x00000010 /* Unwrittable file closed */
12#define FAN_OPEN 0x00000020 /* File was opened */ 13#define FAN_OPEN 0x00000020 /* File was opened */
14#define FAN_MOVED_FROM 0x00000040 /* File was moved from X */
15#define FAN_MOVED_TO 0x00000080 /* File was moved to Y */
16#define FAN_CREATE 0x00000100 /* Subfile was created */
17#define FAN_DELETE 0x00000200 /* Subfile was deleted */
18#define FAN_DELETE_SELF 0x00000400 /* Self was deleted */
19#define FAN_MOVE_SELF 0x00000800 /* Self was moved */
13#define FAN_OPEN_EXEC 0x00001000 /* File was opened for exec */ 20#define FAN_OPEN_EXEC 0x00001000 /* File was opened for exec */
14 21
15#define FAN_Q_OVERFLOW 0x00004000 /* Event queued overflowed */ 22#define FAN_Q_OVERFLOW 0x00004000 /* Event queued overflowed */
@@ -24,6 +31,7 @@
24 31
25/* helper events */ 32/* helper events */
26#define FAN_CLOSE (FAN_CLOSE_WRITE | FAN_CLOSE_NOWRITE) /* close */ 33#define FAN_CLOSE (FAN_CLOSE_WRITE | FAN_CLOSE_NOWRITE) /* close */
34#define FAN_MOVE (FAN_MOVED_FROM | FAN_MOVED_TO) /* moves */
27 35
28/* flags used for fanotify_init() */ 36/* flags used for fanotify_init() */
29#define FAN_CLOEXEC 0x00000001 37#define FAN_CLOEXEC 0x00000001
@@ -44,6 +52,7 @@
44 52
45/* Flags to determine fanotify event format */ 53/* Flags to determine fanotify event format */
46#define FAN_REPORT_TID 0x00000100 /* event->pid is thread id */ 54#define FAN_REPORT_TID 0x00000100 /* event->pid is thread id */
55#define FAN_REPORT_FID 0x00000200 /* Report unique file id */
47 56
48/* Deprecated - do not use this in programs and do not add new flags here! */ 57/* Deprecated - do not use this in programs and do not add new flags here! */
49#define FAN_ALL_INIT_FLAGS (FAN_CLOEXEC | FAN_NONBLOCK | \ 58#define FAN_ALL_INIT_FLAGS (FAN_CLOEXEC | FAN_NONBLOCK | \
@@ -106,6 +115,26 @@ struct fanotify_event_metadata {
106 __s32 pid; 115 __s32 pid;
107}; 116};
108 117
118#define FAN_EVENT_INFO_TYPE_FID 1
119
120/* Variable length info record following event metadata */
121struct fanotify_event_info_header {
122 __u8 info_type;
123 __u8 pad;
124 __u16 len;
125};
126
127/* Unique file identifier info record */
128struct fanotify_event_info_fid {
129 struct fanotify_event_info_header hdr;
130 __kernel_fsid_t fsid;
131 /*
132 * Following is an opaque struct file_handle that can be passed as
133 * an argument to open_by_handle_at(2).
134 */
135 unsigned char handle[0];
136};
137
109struct fanotify_response { 138struct fanotify_response {
110 __s32 fd; 139 __s32 fd;
111 __u32 response; 140 __u32 response;
diff --git a/include/uapi/linux/fcntl.h b/include/uapi/linux/fcntl.h
index 6448cdd9a350..a2f8658f1c55 100644
--- a/include/uapi/linux/fcntl.h
+++ b/include/uapi/linux/fcntl.h
@@ -41,6 +41,7 @@
41#define F_SEAL_SHRINK 0x0002 /* prevent file from shrinking */ 41#define F_SEAL_SHRINK 0x0002 /* prevent file from shrinking */
42#define F_SEAL_GROW 0x0004 /* prevent file from growing */ 42#define F_SEAL_GROW 0x0004 /* prevent file from growing */
43#define F_SEAL_WRITE 0x0008 /* prevent writes */ 43#define F_SEAL_WRITE 0x0008 /* prevent writes */
44#define F_SEAL_FUTURE_WRITE 0x0010 /* prevent future writes while mapped */
44/* (1U << 31) is reserved for signed error codes */ 45/* (1U << 31) is reserved for signed error codes */
45 46
46/* 47/*
diff --git a/include/uapi/linux/fuse.h b/include/uapi/linux/fuse.h
index b4967d48bfda..2ac598614a8f 100644
--- a/include/uapi/linux/fuse.h
+++ b/include/uapi/linux/fuse.h
@@ -122,6 +122,9 @@
122 * - add FOPEN_CACHE_DIR 122 * - add FOPEN_CACHE_DIR
123 * - add FUSE_MAX_PAGES, add max_pages to init_out 123 * - add FUSE_MAX_PAGES, add max_pages to init_out
124 * - add FUSE_CACHE_SYMLINKS 124 * - add FUSE_CACHE_SYMLINKS
125 *
126 * 7.29
127 * - add FUSE_NO_OPENDIR_SUPPORT flag
125 */ 128 */
126 129
127#ifndef _LINUX_FUSE_H 130#ifndef _LINUX_FUSE_H
@@ -157,7 +160,7 @@
157#define FUSE_KERNEL_VERSION 7 160#define FUSE_KERNEL_VERSION 7
158 161
159/** Minor version number of this interface */ 162/** Minor version number of this interface */
160#define FUSE_KERNEL_MINOR_VERSION 28 163#define FUSE_KERNEL_MINOR_VERSION 29
161 164
162/** The node ID of the root inode */ 165/** The node ID of the root inode */
163#define FUSE_ROOT_ID 1 166#define FUSE_ROOT_ID 1
@@ -259,6 +262,7 @@ struct fuse_file_lock {
259 * FUSE_ABORT_ERROR: reading the device after abort returns ECONNABORTED 262 * FUSE_ABORT_ERROR: reading the device after abort returns ECONNABORTED
260 * FUSE_MAX_PAGES: init_out.max_pages contains the max number of req pages 263 * FUSE_MAX_PAGES: init_out.max_pages contains the max number of req pages
261 * FUSE_CACHE_SYMLINKS: cache READLINK responses 264 * FUSE_CACHE_SYMLINKS: cache READLINK responses
265 * FUSE_NO_OPENDIR_SUPPORT: kernel supports zero-message opendir
262 */ 266 */
263#define FUSE_ASYNC_READ (1 << 0) 267#define FUSE_ASYNC_READ (1 << 0)
264#define FUSE_POSIX_LOCKS (1 << 1) 268#define FUSE_POSIX_LOCKS (1 << 1)
@@ -284,6 +288,7 @@ struct fuse_file_lock {
284#define FUSE_ABORT_ERROR (1 << 21) 288#define FUSE_ABORT_ERROR (1 << 21)
285#define FUSE_MAX_PAGES (1 << 22) 289#define FUSE_MAX_PAGES (1 << 22)
286#define FUSE_CACHE_SYMLINKS (1 << 23) 290#define FUSE_CACHE_SYMLINKS (1 << 23)
291#define FUSE_NO_OPENDIR_SUPPORT (1 << 24)
287 292
288/** 293/**
289 * CUSE INIT request/reply flags 294 * CUSE INIT request/reply flags
diff --git a/include/uapi/linux/icmpv6.h b/include/uapi/linux/icmpv6.h
index caf8dc019250..325395f56bfa 100644
--- a/include/uapi/linux/icmpv6.h
+++ b/include/uapi/linux/icmpv6.h
@@ -108,6 +108,8 @@ struct icmp6hdr {
108#define ICMPV6_MOBILE_PREFIX_SOL 146 108#define ICMPV6_MOBILE_PREFIX_SOL 146
109#define ICMPV6_MOBILE_PREFIX_ADV 147 109#define ICMPV6_MOBILE_PREFIX_ADV 147
110 110
111#define ICMPV6_MRDISC_ADV 151
112
111/* 113/*
112 * Codes for Destination Unreachable 114 * Codes for Destination Unreachable
113 */ 115 */
diff --git a/include/uapi/linux/if_bonding.h b/include/uapi/linux/if_bonding.h
index 61a1bf6e865e..790585f0e61b 100644
--- a/include/uapi/linux/if_bonding.h
+++ b/include/uapi/linux/if_bonding.h
@@ -117,6 +117,30 @@ struct ad_info {
117 __u8 partner_system[ETH_ALEN]; 117 __u8 partner_system[ETH_ALEN];
118}; 118};
119 119
120/* Embedded inside LINK_XSTATS_TYPE_BOND */
121enum {
122 BOND_XSTATS_UNSPEC,
123 BOND_XSTATS_3AD,
124 __BOND_XSTATS_MAX
125};
126#define BOND_XSTATS_MAX (__BOND_XSTATS_MAX - 1)
127
128/* Embedded inside BOND_XSTATS_3AD */
129enum {
130 BOND_3AD_STAT_LACPDU_RX,
131 BOND_3AD_STAT_LACPDU_TX,
132 BOND_3AD_STAT_LACPDU_UNKNOWN_RX,
133 BOND_3AD_STAT_LACPDU_ILLEGAL_RX,
134 BOND_3AD_STAT_MARKER_RX,
135 BOND_3AD_STAT_MARKER_TX,
136 BOND_3AD_STAT_MARKER_RESP_RX,
137 BOND_3AD_STAT_MARKER_RESP_TX,
138 BOND_3AD_STAT_MARKER_UNKNOWN_RX,
139 BOND_3AD_STAT_PAD,
140 __BOND_3AD_STAT_MAX
141};
142#define BOND_3AD_STAT_MAX (__BOND_3AD_STAT_MAX - 1)
143
120#endif /* _LINUX_IF_BONDING_H */ 144#endif /* _LINUX_IF_BONDING_H */
121 145
122/* 146/*
diff --git a/include/uapi/linux/if_link.h b/include/uapi/linux/if_link.h
index d6533828123a..5b225ff63b48 100644
--- a/include/uapi/linux/if_link.h
+++ b/include/uapi/linux/if_link.h
@@ -925,6 +925,7 @@ enum {
925enum { 925enum {
926 LINK_XSTATS_TYPE_UNSPEC, 926 LINK_XSTATS_TYPE_UNSPEC,
927 LINK_XSTATS_TYPE_BRIDGE, 927 LINK_XSTATS_TYPE_BRIDGE,
928 LINK_XSTATS_TYPE_BOND,
928 __LINK_XSTATS_TYPE_MAX 929 __LINK_XSTATS_TYPE_MAX
929}; 930};
930#define LINK_XSTATS_TYPE_MAX (__LINK_XSTATS_TYPE_MAX - 1) 931#define LINK_XSTATS_TYPE_MAX (__LINK_XSTATS_TYPE_MAX - 1)
diff --git a/include/uapi/linux/igmp.h b/include/uapi/linux/igmp.h
index 7e44ac02ca18..90c28bc466c6 100644
--- a/include/uapi/linux/igmp.h
+++ b/include/uapi/linux/igmp.h
@@ -93,6 +93,7 @@ struct igmpv3_query {
93#define IGMP_MTRACE_RESP 0x1e 93#define IGMP_MTRACE_RESP 0x1e
94#define IGMP_MTRACE 0x1f 94#define IGMP_MTRACE 0x1f
95 95
96#define IGMP_MRDISC_ADV 0x30 /* From RFC4286 */
96 97
97/* 98/*
98 * Use the BSD names for these for compatibility 99 * Use the BSD names for these for compatibility
diff --git a/include/uapi/linux/iio/types.h b/include/uapi/linux/iio/types.h
index 92baabc103ac..fdd81affca4b 100644
--- a/include/uapi/linux/iio/types.h
+++ b/include/uapi/linux/iio/types.h
@@ -46,6 +46,7 @@ enum iio_chan_type {
46 IIO_GRAVITY, 46 IIO_GRAVITY,
47 IIO_POSITIONRELATIVE, 47 IIO_POSITIONRELATIVE,
48 IIO_PHASE, 48 IIO_PHASE,
49 IIO_MASSCONCENTRATION,
49}; 50};
50 51
51enum iio_modifier { 52enum iio_modifier {
@@ -87,6 +88,12 @@ enum iio_modifier {
87 IIO_MOD_VOC, 88 IIO_MOD_VOC,
88 IIO_MOD_LIGHT_UV, 89 IIO_MOD_LIGHT_UV,
89 IIO_MOD_LIGHT_DUV, 90 IIO_MOD_LIGHT_DUV,
91 IIO_MOD_PM1,
92 IIO_MOD_PM2P5,
93 IIO_MOD_PM4,
94 IIO_MOD_PM10,
95 IIO_MOD_ETHANOL,
96 IIO_MOD_H2,
90}; 97};
91 98
92enum iio_event_type { 99enum iio_event_type {
diff --git a/include/uapi/linux/in.h b/include/uapi/linux/in.h
index a55cb8b10165..e7ad9d350a28 100644
--- a/include/uapi/linux/in.h
+++ b/include/uapi/linux/in.h
@@ -292,10 +292,11 @@ struct sockaddr_in {
292#define IN_LOOPBACK(a) ((((long int) (a)) & 0xff000000) == 0x7f000000) 292#define IN_LOOPBACK(a) ((((long int) (a)) & 0xff000000) == 0x7f000000)
293 293
294/* Defines for Multicast INADDR */ 294/* Defines for Multicast INADDR */
295#define INADDR_UNSPEC_GROUP 0xe0000000U /* 224.0.0.0 */ 295#define INADDR_UNSPEC_GROUP 0xe0000000U /* 224.0.0.0 */
296#define INADDR_ALLHOSTS_GROUP 0xe0000001U /* 224.0.0.1 */ 296#define INADDR_ALLHOSTS_GROUP 0xe0000001U /* 224.0.0.1 */
297#define INADDR_ALLRTRS_GROUP 0xe0000002U /* 224.0.0.2 */ 297#define INADDR_ALLRTRS_GROUP 0xe0000002U /* 224.0.0.2 */
298#define INADDR_MAX_LOCAL_GROUP 0xe00000ffU /* 224.0.0.255 */ 298#define INADDR_ALLSNOOPERS_GROUP 0xe000006aU /* 224.0.0.106 */
299#define INADDR_MAX_LOCAL_GROUP 0xe00000ffU /* 224.0.0.255 */
299#endif 300#endif
300 301
301/* <asm/byteorder.h> contains the htonl type stuff.. */ 302/* <asm/byteorder.h> contains the htonl type stuff.. */
diff --git a/include/uapi/linux/in6.h b/include/uapi/linux/in6.h
index 71d82fe15b03..9f2273a08356 100644
--- a/include/uapi/linux/in6.h
+++ b/include/uapi/linux/in6.h
@@ -178,6 +178,7 @@ struct in6_flowlabel_req {
178#define IPV6_JOIN_ANYCAST 27 178#define IPV6_JOIN_ANYCAST 27
179#define IPV6_LEAVE_ANYCAST 28 179#define IPV6_LEAVE_ANYCAST 28
180#define IPV6_MULTICAST_ALL 29 180#define IPV6_MULTICAST_ALL 29
181#define IPV6_ROUTER_ALERT_ISOLATE 30
181 182
182/* IPV6_MTU_DISCOVER values */ 183/* IPV6_MTU_DISCOVER values */
183#define IPV6_PMTUDISC_DONT 0 184#define IPV6_PMTUDISC_DONT 0
diff --git a/include/uapi/linux/io_uring.h b/include/uapi/linux/io_uring.h
new file mode 100644
index 000000000000..e23408692118
--- /dev/null
+++ b/include/uapi/linux/io_uring.h
@@ -0,0 +1,137 @@
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2/*
3 * Header file for the io_uring interface.
4 *
5 * Copyright (C) 2019 Jens Axboe
6 * Copyright (C) 2019 Christoph Hellwig
7 */
8#ifndef LINUX_IO_URING_H
9#define LINUX_IO_URING_H
10
11#include <linux/fs.h>
12#include <linux/types.h>
13
14/*
15 * IO submission data structure (Submission Queue Entry)
16 */
17struct io_uring_sqe {
18 __u8 opcode; /* type of operation for this sqe */
19 __u8 flags; /* IOSQE_ flags */
20 __u16 ioprio; /* ioprio for the request */
21 __s32 fd; /* file descriptor to do IO on */
22 __u64 off; /* offset into file */
23 __u64 addr; /* pointer to buffer or iovecs */
24 __u32 len; /* buffer size or number of iovecs */
25 union {
26 __kernel_rwf_t rw_flags;
27 __u32 fsync_flags;
28 __u16 poll_events;
29 };
30 __u64 user_data; /* data to be passed back at completion time */
31 union {
32 __u16 buf_index; /* index into fixed buffers, if used */
33 __u64 __pad2[3];
34 };
35};
36
37/*
38 * sqe->flags
39 */
40#define IOSQE_FIXED_FILE (1U << 0) /* use fixed fileset */
41
42/*
43 * io_uring_setup() flags
44 */
45#define IORING_SETUP_IOPOLL (1U << 0) /* io_context is polled */
46#define IORING_SETUP_SQPOLL (1U << 1) /* SQ poll thread */
47#define IORING_SETUP_SQ_AFF (1U << 2) /* sq_thread_cpu is valid */
48
49#define IORING_OP_NOP 0
50#define IORING_OP_READV 1
51#define IORING_OP_WRITEV 2
52#define IORING_OP_FSYNC 3
53#define IORING_OP_READ_FIXED 4
54#define IORING_OP_WRITE_FIXED 5
55#define IORING_OP_POLL_ADD 6
56#define IORING_OP_POLL_REMOVE 7
57
58/*
59 * sqe->fsync_flags
60 */
61#define IORING_FSYNC_DATASYNC (1U << 0)
62
63/*
64 * IO completion data structure (Completion Queue Entry)
65 */
66struct io_uring_cqe {
67 __u64 user_data; /* sqe->data submission passed back */
68 __s32 res; /* result code for this event */
69 __u32 flags;
70};
71
72/*
73 * Magic offsets for the application to mmap the data it needs
74 */
75#define IORING_OFF_SQ_RING 0ULL
76#define IORING_OFF_CQ_RING 0x8000000ULL
77#define IORING_OFF_SQES 0x10000000ULL
78
79/*
80 * Filled with the offset for mmap(2)
81 */
82struct io_sqring_offsets {
83 __u32 head;
84 __u32 tail;
85 __u32 ring_mask;
86 __u32 ring_entries;
87 __u32 flags;
88 __u32 dropped;
89 __u32 array;
90 __u32 resv1;
91 __u64 resv2;
92};
93
94/*
95 * sq_ring->flags
96 */
97#define IORING_SQ_NEED_WAKEUP (1U << 0) /* needs io_uring_enter wakeup */
98
99struct io_cqring_offsets {
100 __u32 head;
101 __u32 tail;
102 __u32 ring_mask;
103 __u32 ring_entries;
104 __u32 overflow;
105 __u32 cqes;
106 __u64 resv[2];
107};
108
109/*
110 * io_uring_enter(2) flags
111 */
112#define IORING_ENTER_GETEVENTS (1U << 0)
113#define IORING_ENTER_SQ_WAKEUP (1U << 1)
114
115/*
116 * Passed in for io_uring_setup(2). Copied back with updated info on success
117 */
118struct io_uring_params {
119 __u32 sq_entries;
120 __u32 cq_entries;
121 __u32 flags;
122 __u32 sq_thread_cpu;
123 __u32 sq_thread_idle;
124 __u32 resv[5];
125 struct io_sqring_offsets sq_off;
126 struct io_cqring_offsets cq_off;
127};
128
129/*
130 * io_uring_register(2) opcodes and arguments
131 */
132#define IORING_REGISTER_BUFFERS 0
133#define IORING_UNREGISTER_BUFFERS 1
134#define IORING_REGISTER_FILES 2
135#define IORING_UNREGISTER_FILES 3
136
137#endif
diff --git a/include/uapi/linux/kernel-page-flags.h b/include/uapi/linux/kernel-page-flags.h
index 21b9113c69da..6f2f2720f3ac 100644
--- a/include/uapi/linux/kernel-page-flags.h
+++ b/include/uapi/linux/kernel-page-flags.h
@@ -32,7 +32,7 @@
32 32
33#define KPF_KSM 21 33#define KPF_KSM 21
34#define KPF_THP 22 34#define KPF_THP 22
35#define KPF_BALLOON 23 35#define KPF_OFFLINE 23
36#define KPF_ZERO_PAGE 24 36#define KPF_ZERO_PAGE 24
37#define KPF_IDLE 25 37#define KPF_IDLE 25
38#define KPF_PGTABLE 26 38#define KPF_PGTABLE 26
diff --git a/include/uapi/linux/limits.h b/include/uapi/linux/limits.h
index c3547f07605c..6bcbe3068761 100644
--- a/include/uapi/linux/limits.h
+++ b/include/uapi/linux/limits.h
@@ -1,6 +1,6 @@
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ 1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2#ifndef _LINUX_LIMITS_H 2#ifndef _UAPI_LINUX_LIMITS_H
3#define _LINUX_LIMITS_H 3#define _UAPI_LINUX_LIMITS_H
4 4
5#define NR_OPEN 1024 5#define NR_OPEN 1024
6 6
diff --git a/include/uapi/linux/lirc.h b/include/uapi/linux/lirc.h
index 6b319581882f..45fcbf99d72e 100644
--- a/include/uapi/linux/lirc.h
+++ b/include/uapi/linux/lirc.h
@@ -192,6 +192,9 @@ struct lirc_scancode {
192 * @RC_PROTO_XMP: XMP protocol 192 * @RC_PROTO_XMP: XMP protocol
193 * @RC_PROTO_CEC: CEC protocol 193 * @RC_PROTO_CEC: CEC protocol
194 * @RC_PROTO_IMON: iMon Pad protocol 194 * @RC_PROTO_IMON: iMon Pad protocol
195 * @RC_PROTO_RCMM12: RC-MM protocol 12 bits
196 * @RC_PROTO_RCMM24: RC-MM protocol 24 bits
197 * @RC_PROTO_RCMM32: RC-MM protocol 32 bits
195 */ 198 */
196enum rc_proto { 199enum rc_proto {
197 RC_PROTO_UNKNOWN = 0, 200 RC_PROTO_UNKNOWN = 0,
@@ -218,6 +221,9 @@ enum rc_proto {
218 RC_PROTO_XMP = 21, 221 RC_PROTO_XMP = 21,
219 RC_PROTO_CEC = 22, 222 RC_PROTO_CEC = 22,
220 RC_PROTO_IMON = 23, 223 RC_PROTO_IMON = 23,
224 RC_PROTO_RCMM12 = 24,
225 RC_PROTO_RCMM24 = 25,
226 RC_PROTO_RCMM32 = 26,
221}; 227};
222 228
223#endif 229#endif
diff --git a/include/uapi/linux/mdio.h b/include/uapi/linux/mdio.h
index d435b00d64ad..0a552061ff1c 100644
--- a/include/uapi/linux/mdio.h
+++ b/include/uapi/linux/mdio.h
@@ -45,6 +45,7 @@
45#define MDIO_AN_ADVERTISE 16 /* AN advertising (base page) */ 45#define MDIO_AN_ADVERTISE 16 /* AN advertising (base page) */
46#define MDIO_AN_LPA 19 /* AN LP abilities (base page) */ 46#define MDIO_AN_LPA 19 /* AN LP abilities (base page) */
47#define MDIO_PCS_EEE_ABLE 20 /* EEE Capability register */ 47#define MDIO_PCS_EEE_ABLE 20 /* EEE Capability register */
48#define MDIO_PMA_NG_EXTABLE 21 /* 2.5G/5G PMA/PMD extended ability */
48#define MDIO_PCS_EEE_WK_ERR 22 /* EEE wake error counter */ 49#define MDIO_PCS_EEE_WK_ERR 22 /* EEE wake error counter */
49#define MDIO_PHYXS_LNSTAT 24 /* PHY XGXS lane state */ 50#define MDIO_PHYXS_LNSTAT 24 /* PHY XGXS lane state */
50#define MDIO_AN_EEE_ADV 60 /* EEE advertisement */ 51#define MDIO_AN_EEE_ADV 60 /* EEE advertisement */
@@ -92,6 +93,10 @@
92#define MDIO_CTRL1_SPEED10G (MDIO_CTRL1_SPEEDSELEXT | 0x00) 93#define MDIO_CTRL1_SPEED10G (MDIO_CTRL1_SPEEDSELEXT | 0x00)
93/* 10PASS-TS/2BASE-TL */ 94/* 10PASS-TS/2BASE-TL */
94#define MDIO_CTRL1_SPEED10P2B (MDIO_CTRL1_SPEEDSELEXT | 0x04) 95#define MDIO_CTRL1_SPEED10P2B (MDIO_CTRL1_SPEEDSELEXT | 0x04)
96/* 2.5 Gb/s */
97#define MDIO_CTRL1_SPEED2_5G (MDIO_CTRL1_SPEEDSELEXT | 0x18)
98/* 5 Gb/s */
99#define MDIO_CTRL1_SPEED5G (MDIO_CTRL1_SPEEDSELEXT | 0x1c)
95 100
96/* Status register 1. */ 101/* Status register 1. */
97#define MDIO_STAT1_LPOWERABLE 0x0002 /* Low-power ability */ 102#define MDIO_STAT1_LPOWERABLE 0x0002 /* Low-power ability */
@@ -115,6 +120,7 @@
115 120
116/* Device present registers. */ 121/* Device present registers. */
117#define MDIO_DEVS_PRESENT(devad) (1 << (devad)) 122#define MDIO_DEVS_PRESENT(devad) (1 << (devad))
123#define MDIO_DEVS_C22PRESENT MDIO_DEVS_PRESENT(0)
118#define MDIO_DEVS_PMAPMD MDIO_DEVS_PRESENT(MDIO_MMD_PMAPMD) 124#define MDIO_DEVS_PMAPMD MDIO_DEVS_PRESENT(MDIO_MMD_PMAPMD)
119#define MDIO_DEVS_WIS MDIO_DEVS_PRESENT(MDIO_MMD_WIS) 125#define MDIO_DEVS_WIS MDIO_DEVS_PRESENT(MDIO_MMD_WIS)
120#define MDIO_DEVS_PCS MDIO_DEVS_PRESENT(MDIO_MMD_PCS) 126#define MDIO_DEVS_PCS MDIO_DEVS_PRESENT(MDIO_MMD_PCS)
@@ -123,6 +129,8 @@
123#define MDIO_DEVS_TC MDIO_DEVS_PRESENT(MDIO_MMD_TC) 129#define MDIO_DEVS_TC MDIO_DEVS_PRESENT(MDIO_MMD_TC)
124#define MDIO_DEVS_AN MDIO_DEVS_PRESENT(MDIO_MMD_AN) 130#define MDIO_DEVS_AN MDIO_DEVS_PRESENT(MDIO_MMD_AN)
125#define MDIO_DEVS_C22EXT MDIO_DEVS_PRESENT(MDIO_MMD_C22EXT) 131#define MDIO_DEVS_C22EXT MDIO_DEVS_PRESENT(MDIO_MMD_C22EXT)
132#define MDIO_DEVS_VEND1 MDIO_DEVS_PRESENT(MDIO_MMD_VEND1)
133#define MDIO_DEVS_VEND2 MDIO_DEVS_PRESENT(MDIO_MMD_VEND2)
126 134
127/* Control register 2. */ 135/* Control register 2. */
128#define MDIO_PMA_CTRL2_TYPE 0x000f /* PMA/PMD type selection */ 136#define MDIO_PMA_CTRL2_TYPE 0x000f /* PMA/PMD type selection */
@@ -142,6 +150,8 @@
142#define MDIO_PMA_CTRL2_1000BKX 0x000d /* 1000BASE-KX type */ 150#define MDIO_PMA_CTRL2_1000BKX 0x000d /* 1000BASE-KX type */
143#define MDIO_PMA_CTRL2_100BTX 0x000e /* 100BASE-TX type */ 151#define MDIO_PMA_CTRL2_100BTX 0x000e /* 100BASE-TX type */
144#define MDIO_PMA_CTRL2_10BT 0x000f /* 10BASE-T type */ 152#define MDIO_PMA_CTRL2_10BT 0x000f /* 10BASE-T type */
153#define MDIO_PMA_CTRL2_2_5GBT 0x0030 /* 2.5GBaseT type */
154#define MDIO_PMA_CTRL2_5GBT 0x0031 /* 5GBaseT type */
145#define MDIO_PCS_CTRL2_TYPE 0x0003 /* PCS type selection */ 155#define MDIO_PCS_CTRL2_TYPE 0x0003 /* PCS type selection */
146#define MDIO_PCS_CTRL2_10GBR 0x0000 /* 10GBASE-R type */ 156#define MDIO_PCS_CTRL2_10GBR 0x0000 /* 10GBASE-R type */
147#define MDIO_PCS_CTRL2_10GBX 0x0001 /* 10GBASE-X type */ 157#define MDIO_PCS_CTRL2_10GBX 0x0001 /* 10GBASE-X type */
@@ -195,6 +205,7 @@
195#define MDIO_PMA_EXTABLE_1000BKX 0x0040 /* 1000BASE-KX ability */ 205#define MDIO_PMA_EXTABLE_1000BKX 0x0040 /* 1000BASE-KX ability */
196#define MDIO_PMA_EXTABLE_100BTX 0x0080 /* 100BASE-TX ability */ 206#define MDIO_PMA_EXTABLE_100BTX 0x0080 /* 100BASE-TX ability */
197#define MDIO_PMA_EXTABLE_10BT 0x0100 /* 10BASE-T ability */ 207#define MDIO_PMA_EXTABLE_10BT 0x0100 /* 10BASE-T ability */
208#define MDIO_PMA_EXTABLE_NBT 0x4000 /* 2.5/5GBASE-T ability */
198 209
199/* PHY XGXS lane state register. */ 210/* PHY XGXS lane state register. */
200#define MDIO_PHYXS_LNSTAT_SYNC0 0x0001 211#define MDIO_PHYXS_LNSTAT_SYNC0 0x0001
@@ -231,9 +242,13 @@
231#define MDIO_PCS_10GBRT_STAT2_BER 0x3f00 242#define MDIO_PCS_10GBRT_STAT2_BER 0x3f00
232 243
233/* AN 10GBASE-T control register. */ 244/* AN 10GBASE-T control register. */
245#define MDIO_AN_10GBT_CTRL_ADV2_5G 0x0080 /* Advertise 2.5GBASE-T */
246#define MDIO_AN_10GBT_CTRL_ADV5G 0x0100 /* Advertise 5GBASE-T */
234#define MDIO_AN_10GBT_CTRL_ADV10G 0x1000 /* Advertise 10GBASE-T */ 247#define MDIO_AN_10GBT_CTRL_ADV10G 0x1000 /* Advertise 10GBASE-T */
235 248
236/* AN 10GBASE-T status register. */ 249/* AN 10GBASE-T status register. */
250#define MDIO_AN_10GBT_STAT_LP2_5G 0x0020 /* LP is 2.5GBT capable */
251#define MDIO_AN_10GBT_STAT_LP5G 0x0040 /* LP is 5GBT capable */
237#define MDIO_AN_10GBT_STAT_LPTRR 0x0200 /* LP training reset req. */ 252#define MDIO_AN_10GBT_STAT_LPTRR 0x0200 /* LP training reset req. */
238#define MDIO_AN_10GBT_STAT_LPLTABLE 0x0400 /* LP loop timing ability */ 253#define MDIO_AN_10GBT_STAT_LPLTABLE 0x0400 /* LP loop timing ability */
239#define MDIO_AN_10GBT_STAT_LP10G 0x0800 /* LP is 10GBT capable */ 254#define MDIO_AN_10GBT_STAT_LP10G 0x0800 /* LP is 10GBT capable */
@@ -262,6 +277,10 @@
262#define MDIO_EEE_10GKX4 0x0020 /* 10G KX4 EEE cap */ 277#define MDIO_EEE_10GKX4 0x0020 /* 10G KX4 EEE cap */
263#define MDIO_EEE_10GKR 0x0040 /* 10G KR EEE cap */ 278#define MDIO_EEE_10GKR 0x0040 /* 10G KR EEE cap */
264 279
280/* 2.5G/5G Extended abilities register. */
281#define MDIO_PMA_NG_EXTABLE_2_5GBT 0x0001 /* 2.5GBASET ability */
282#define MDIO_PMA_NG_EXTABLE_5GBT 0x0002 /* 5GBASET ability */
283
265/* LASI RX_ALARM control/status registers. */ 284/* LASI RX_ALARM control/status registers. */
266#define MDIO_PMA_LASI_RX_PHYXSLFLT 0x0001 /* PHY XS RX local fault */ 285#define MDIO_PMA_LASI_RX_PHYXSLFLT 0x0001 /* PHY XS RX local fault */
267#define MDIO_PMA_LASI_RX_PCSLFLT 0x0008 /* PCS RX local fault */ 286#define MDIO_PMA_LASI_RX_PCSLFLT 0x0008 /* PCS RX local fault */
diff --git a/include/uapi/linux/mman.h b/include/uapi/linux/mman.h
index d0f515d53299..fc1a64c3447b 100644
--- a/include/uapi/linux/mman.h
+++ b/include/uapi/linux/mman.h
@@ -12,6 +12,10 @@
12#define OVERCOMMIT_ALWAYS 1 12#define OVERCOMMIT_ALWAYS 1
13#define OVERCOMMIT_NEVER 2 13#define OVERCOMMIT_NEVER 2
14 14
15#define MAP_SHARED 0x01 /* Share changes */
16#define MAP_PRIVATE 0x02 /* Changes are private */
17#define MAP_SHARED_VALIDATE 0x03 /* share + validate extension flags */
18
15/* 19/*
16 * Huge page size encoding when MAP_HUGETLB is specified, and a huge page 20 * Huge page size encoding when MAP_HUGETLB is specified, and a huge page
17 * size other than the default is desired. See hugetlb_encode.h. 21 * size other than the default is desired. See hugetlb_encode.h.
diff --git a/include/uapi/linux/mroute.h b/include/uapi/linux/mroute.h
index 5d37a9ccce63..11c8c1fc1124 100644
--- a/include/uapi/linux/mroute.h
+++ b/include/uapi/linux/mroute.h
@@ -28,12 +28,19 @@
28#define MRT_TABLE (MRT_BASE+9) /* Specify mroute table ID */ 28#define MRT_TABLE (MRT_BASE+9) /* Specify mroute table ID */
29#define MRT_ADD_MFC_PROXY (MRT_BASE+10) /* Add a (*,*|G) mfc entry */ 29#define MRT_ADD_MFC_PROXY (MRT_BASE+10) /* Add a (*,*|G) mfc entry */
30#define MRT_DEL_MFC_PROXY (MRT_BASE+11) /* Del a (*,*|G) mfc entry */ 30#define MRT_DEL_MFC_PROXY (MRT_BASE+11) /* Del a (*,*|G) mfc entry */
31#define MRT_MAX (MRT_BASE+11) 31#define MRT_FLUSH (MRT_BASE+12) /* Flush all mfc entries and/or vifs */
32#define MRT_MAX (MRT_BASE+12)
32 33
33#define SIOCGETVIFCNT SIOCPROTOPRIVATE /* IP protocol privates */ 34#define SIOCGETVIFCNT SIOCPROTOPRIVATE /* IP protocol privates */
34#define SIOCGETSGCNT (SIOCPROTOPRIVATE+1) 35#define SIOCGETSGCNT (SIOCPROTOPRIVATE+1)
35#define SIOCGETRPF (SIOCPROTOPRIVATE+2) 36#define SIOCGETRPF (SIOCPROTOPRIVATE+2)
36 37
38/* MRT_FLUSH optional flags */
39#define MRT_FLUSH_MFC 1 /* Flush multicast entries */
40#define MRT_FLUSH_MFC_STATIC 2 /* Flush static multicast entries */
41#define MRT_FLUSH_VIFS 4 /* Flush multicast vifs */
42#define MRT_FLUSH_VIFS_STATIC 8 /* Flush static multicast vifs */
43
37#define MAXVIFS 32 44#define MAXVIFS 32
38typedef unsigned long vifbitmap_t; /* User mode code depends on this lot */ 45typedef unsigned long vifbitmap_t; /* User mode code depends on this lot */
39typedef unsigned short vifi_t; 46typedef unsigned short vifi_t;
diff --git a/include/uapi/linux/mroute6.h b/include/uapi/linux/mroute6.h
index 9999cc006390..c36177a86516 100644
--- a/include/uapi/linux/mroute6.h
+++ b/include/uapi/linux/mroute6.h
@@ -31,12 +31,19 @@
31#define MRT6_TABLE (MRT6_BASE+9) /* Specify mroute table ID */ 31#define MRT6_TABLE (MRT6_BASE+9) /* Specify mroute table ID */
32#define MRT6_ADD_MFC_PROXY (MRT6_BASE+10) /* Add a (*,*|G) mfc entry */ 32#define MRT6_ADD_MFC_PROXY (MRT6_BASE+10) /* Add a (*,*|G) mfc entry */
33#define MRT6_DEL_MFC_PROXY (MRT6_BASE+11) /* Del a (*,*|G) mfc entry */ 33#define MRT6_DEL_MFC_PROXY (MRT6_BASE+11) /* Del a (*,*|G) mfc entry */
34#define MRT6_MAX (MRT6_BASE+11) 34#define MRT6_FLUSH (MRT6_BASE+12) /* Flush all mfc entries and/or vifs */
35#define MRT6_MAX (MRT6_BASE+12)
35 36
36#define SIOCGETMIFCNT_IN6 SIOCPROTOPRIVATE /* IP protocol privates */ 37#define SIOCGETMIFCNT_IN6 SIOCPROTOPRIVATE /* IP protocol privates */
37#define SIOCGETSGCNT_IN6 (SIOCPROTOPRIVATE+1) 38#define SIOCGETSGCNT_IN6 (SIOCPROTOPRIVATE+1)
38#define SIOCGETRPF (SIOCPROTOPRIVATE+2) 39#define SIOCGETRPF (SIOCPROTOPRIVATE+2)
39 40
41/* MRT6_FLUSH optional flags */
42#define MRT6_FLUSH_MFC 1 /* Flush multicast entries */
43#define MRT6_FLUSH_MFC_STATIC 2 /* Flush static multicast entries */
44#define MRT6_FLUSH_MIFS 4 /* Flushing multicast vifs */
45#define MRT6_FLUSH_MIFS_STATIC 8 /* Flush static multicast vifs */
46
40#define MAXMIFS 32 47#define MAXMIFS 32
41typedef unsigned long mifbitmap_t; /* User mode code depends on this lot */ 48typedef unsigned long mifbitmap_t; /* User mode code depends on this lot */
42typedef unsigned short mifi_t; 49typedef unsigned short mifi_t;
diff --git a/include/uapi/linux/ndctl.h b/include/uapi/linux/ndctl.h
index f57c9e434d2d..de5d90212409 100644
--- a/include/uapi/linux/ndctl.h
+++ b/include/uapi/linux/ndctl.h
@@ -243,6 +243,7 @@ struct nd_cmd_pkg {
243#define NVDIMM_FAMILY_HPE1 1 243#define NVDIMM_FAMILY_HPE1 1
244#define NVDIMM_FAMILY_HPE2 2 244#define NVDIMM_FAMILY_HPE2 2
245#define NVDIMM_FAMILY_MSFT 3 245#define NVDIMM_FAMILY_MSFT 3
246#define NVDIMM_FAMILY_HYPERV 4
246 247
247#define ND_IOCTL_CALL _IOWR(ND_IOCTL, ND_CMD_CALL,\ 248#define ND_IOCTL_CALL _IOWR(ND_IOCTL, ND_CMD_CALL,\
248 struct nd_cmd_pkg) 249 struct nd_cmd_pkg)
diff --git a/include/uapi/linux/netfilter/nf_tables.h b/include/uapi/linux/netfilter/nf_tables.h
index 7de4f1bdaf06..a66c8de006cc 100644
--- a/include/uapi/linux/netfilter/nf_tables.h
+++ b/include/uapi/linux/netfilter/nf_tables.h
@@ -219,6 +219,7 @@ enum nft_chain_attributes {
219 * @NFTA_RULE_POSITION: numeric handle of the previous rule (NLA_U64) 219 * @NFTA_RULE_POSITION: numeric handle of the previous rule (NLA_U64)
220 * @NFTA_RULE_USERDATA: user data (NLA_BINARY, NFT_USERDATA_MAXLEN) 220 * @NFTA_RULE_USERDATA: user data (NLA_BINARY, NFT_USERDATA_MAXLEN)
221 * @NFTA_RULE_ID: uniquely identifies a rule in a transaction (NLA_U32) 221 * @NFTA_RULE_ID: uniquely identifies a rule in a transaction (NLA_U32)
222 * @NFTA_RULE_POSITION_ID: transaction unique identifier of the previous rule (NLA_U32)
222 */ 223 */
223enum nft_rule_attributes { 224enum nft_rule_attributes {
224 NFTA_RULE_UNSPEC, 225 NFTA_RULE_UNSPEC,
@@ -231,6 +232,7 @@ enum nft_rule_attributes {
231 NFTA_RULE_USERDATA, 232 NFTA_RULE_USERDATA,
232 NFTA_RULE_PAD, 233 NFTA_RULE_PAD,
233 NFTA_RULE_ID, 234 NFTA_RULE_ID,
235 NFTA_RULE_POSITION_ID,
234 __NFTA_RULE_MAX 236 __NFTA_RULE_MAX
235}; 237};
236#define NFTA_RULE_MAX (__NFTA_RULE_MAX - 1) 238#define NFTA_RULE_MAX (__NFTA_RULE_MAX - 1)
@@ -789,6 +791,8 @@ enum nft_exthdr_attributes {
789 * @NFT_META_CGROUP: socket control group (skb->sk->sk_classid) 791 * @NFT_META_CGROUP: socket control group (skb->sk->sk_classid)
790 * @NFT_META_PRANDOM: a 32bit pseudo-random number 792 * @NFT_META_PRANDOM: a 32bit pseudo-random number
791 * @NFT_META_SECPATH: boolean, secpath_exists (!!skb->sp) 793 * @NFT_META_SECPATH: boolean, secpath_exists (!!skb->sp)
794 * @NFT_META_IIFKIND: packet input interface kind name (dev->rtnl_link_ops->kind)
795 * @NFT_META_OIFKIND: packet output interface kind name (dev->rtnl_link_ops->kind)
792 */ 796 */
793enum nft_meta_keys { 797enum nft_meta_keys {
794 NFT_META_LEN, 798 NFT_META_LEN,
@@ -817,6 +821,8 @@ enum nft_meta_keys {
817 NFT_META_CGROUP, 821 NFT_META_CGROUP,
818 NFT_META_PRANDOM, 822 NFT_META_PRANDOM,
819 NFT_META_SECPATH, 823 NFT_META_SECPATH,
824 NFT_META_IIFKIND,
825 NFT_META_OIFKIND,
820}; 826};
821 827
822/** 828/**
@@ -871,8 +877,8 @@ enum nft_hash_attributes {
871 NFTA_HASH_SEED, 877 NFTA_HASH_SEED,
872 NFTA_HASH_OFFSET, 878 NFTA_HASH_OFFSET,
873 NFTA_HASH_TYPE, 879 NFTA_HASH_TYPE,
874 NFTA_HASH_SET_NAME, 880 NFTA_HASH_SET_NAME, /* deprecated */
875 NFTA_HASH_SET_ID, 881 NFTA_HASH_SET_ID, /* deprecated */
876 __NFTA_HASH_MAX, 882 __NFTA_HASH_MAX,
877}; 883};
878#define NFTA_HASH_MAX (__NFTA_HASH_MAX - 1) 884#define NFTA_HASH_MAX (__NFTA_HASH_MAX - 1)
@@ -1721,10 +1727,19 @@ enum nft_tunnel_keys {
1721}; 1727};
1722#define NFT_TUNNEL_MAX (__NFT_TUNNEL_MAX - 1) 1728#define NFT_TUNNEL_MAX (__NFT_TUNNEL_MAX - 1)
1723 1729
1730enum nft_tunnel_mode {
1731 NFT_TUNNEL_MODE_NONE,
1732 NFT_TUNNEL_MODE_RX,
1733 NFT_TUNNEL_MODE_TX,
1734 __NFT_TUNNEL_MODE_MAX
1735};
1736#define NFT_TUNNEL_MODE_MAX (__NFT_TUNNEL_MODE_MAX - 1)
1737
1724enum nft_tunnel_attributes { 1738enum nft_tunnel_attributes {
1725 NFTA_TUNNEL_UNSPEC, 1739 NFTA_TUNNEL_UNSPEC,
1726 NFTA_TUNNEL_KEY, 1740 NFTA_TUNNEL_KEY,
1727 NFTA_TUNNEL_DREG, 1741 NFTA_TUNNEL_DREG,
1742 NFTA_TUNNEL_MODE,
1728 __NFTA_TUNNEL_MAX 1743 __NFTA_TUNNEL_MAX
1729}; 1744};
1730#define NFTA_TUNNEL_MAX (__NFTA_TUNNEL_MAX - 1) 1745#define NFTA_TUNNEL_MAX (__NFTA_TUNNEL_MAX - 1)
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 31ae5c7f10e3..dd4f86ee286e 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -1565,6 +1565,12 @@ enum nl80211_commands {
1565 * (a u32 with flags from &enum nl80211_wpa_versions). 1565 * (a u32 with flags from &enum nl80211_wpa_versions).
1566 * @NL80211_ATTR_AKM_SUITES: Used with CONNECT, ASSOCIATE, and NEW_BEACON to 1566 * @NL80211_ATTR_AKM_SUITES: Used with CONNECT, ASSOCIATE, and NEW_BEACON to
1567 * indicate which key management algorithm(s) to use (an array of u32). 1567 * indicate which key management algorithm(s) to use (an array of u32).
1568 * This attribute is also sent in response to @NL80211_CMD_GET_WIPHY,
1569 * indicating the supported AKM suites, intended for specific drivers which
1570 * implement SME and have constraints on which AKMs are supported and also
1571 * the cases where an AKM support is offloaded to the driver/firmware.
1572 * If there is no such notification from the driver, user space should
1573 * assume the driver supports all the AKM suites.
1568 * 1574 *
1569 * @NL80211_ATTR_REQ_IE: (Re)association request information elements as 1575 * @NL80211_ATTR_REQ_IE: (Re)association request information elements as
1570 * sent out by the card, for ROAM and successful CONNECT events. 1576 * sent out by the card, for ROAM and successful CONNECT events.
@@ -2260,10 +2266,10 @@ enum nl80211_commands {
2260 * &enum nl80211_external_auth_action value). This is used with the 2266 * &enum nl80211_external_auth_action value). This is used with the
2261 * %NL80211_CMD_EXTERNAL_AUTH request event. 2267 * %NL80211_CMD_EXTERNAL_AUTH request event.
2262 * @NL80211_ATTR_EXTERNAL_AUTH_SUPPORT: Flag attribute indicating that the user 2268 * @NL80211_ATTR_EXTERNAL_AUTH_SUPPORT: Flag attribute indicating that the user
2263 * space supports external authentication. This attribute shall be used 2269 * space supports external authentication. This attribute shall be used
2264 * only with %NL80211_CMD_CONNECT request. The driver may offload 2270 * with %NL80211_CMD_CONNECT and %NL80211_CMD_START_AP request. The driver
2265 * authentication processing to user space if this capability is indicated 2271 * may offload authentication processing to user space if this capability
2266 * in NL80211_CMD_CONNECT requests from the user space. 2272 * is indicated in the respective requests from the user space.
2267 * 2273 *
2268 * @NL80211_ATTR_NSS: Station's New/updated RX_NSS value notified using this 2274 * @NL80211_ATTR_NSS: Station's New/updated RX_NSS value notified using this
2269 * u8 attribute. This is used with %NL80211_CMD_STA_OPMODE_CHANGED. 2275 * u8 attribute. This is used with %NL80211_CMD_STA_OPMODE_CHANGED.
@@ -2299,6 +2305,9 @@ enum nl80211_commands {
2299 * This is also used for capability advertisement in the wiphy information, 2305 * This is also used for capability advertisement in the wiphy information,
2300 * with the appropriate sub-attributes. 2306 * with the appropriate sub-attributes.
2301 * 2307 *
2308 * @NL80211_ATTR_AIRTIME_WEIGHT: Station's weight when scheduled by the airtime
2309 * scheduler.
2310 *
2302 * @NUM_NL80211_ATTR: total number of nl80211_attrs available 2311 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
2303 * @NL80211_ATTR_MAX: highest attribute number currently defined 2312 * @NL80211_ATTR_MAX: highest attribute number currently defined
2304 * @__NL80211_ATTR_AFTER_LAST: internal use 2313 * @__NL80211_ATTR_AFTER_LAST: internal use
@@ -2748,6 +2757,8 @@ enum nl80211_attrs {
2748 2757
2749 NL80211_ATTR_PEER_MEASUREMENTS, 2758 NL80211_ATTR_PEER_MEASUREMENTS,
2750 2759
2760 NL80211_ATTR_AIRTIME_WEIGHT,
2761
2751 /* add attributes here, update the policy in nl80211.c */ 2762 /* add attributes here, update the policy in nl80211.c */
2752 2763
2753 __NL80211_ATTR_AFTER_LAST, 2764 __NL80211_ATTR_AFTER_LAST,
@@ -3125,6 +3136,9 @@ enum nl80211_sta_bss_param {
3125 * might not be fully accurate. 3136 * might not be fully accurate.
3126 * @NL80211_STA_INFO_CONNECTED_TO_GATE: set to true if STA has a path to a 3137 * @NL80211_STA_INFO_CONNECTED_TO_GATE: set to true if STA has a path to a
3127 * mesh gate (u8, 0 or 1) 3138 * mesh gate (u8, 0 or 1)
3139 * @NL80211_STA_INFO_TX_DURATION: aggregate PPDU duration for all frames
3140 * sent to the station (u64, usec)
3141 * @NL80211_STA_INFO_AIRTIME_WEIGHT: current airtime weight for station (u16)
3128 * @__NL80211_STA_INFO_AFTER_LAST: internal 3142 * @__NL80211_STA_INFO_AFTER_LAST: internal
3129 * @NL80211_STA_INFO_MAX: highest possible station info attribute 3143 * @NL80211_STA_INFO_MAX: highest possible station info attribute
3130 */ 3144 */
@@ -3168,6 +3182,8 @@ enum nl80211_sta_info {
3168 NL80211_STA_INFO_RX_MPDUS, 3182 NL80211_STA_INFO_RX_MPDUS,
3169 NL80211_STA_INFO_FCS_ERROR_COUNT, 3183 NL80211_STA_INFO_FCS_ERROR_COUNT,
3170 NL80211_STA_INFO_CONNECTED_TO_GATE, 3184 NL80211_STA_INFO_CONNECTED_TO_GATE,
3185 NL80211_STA_INFO_TX_DURATION,
3186 NL80211_STA_INFO_AIRTIME_WEIGHT,
3171 3187
3172 /* keep last */ 3188 /* keep last */
3173 __NL80211_STA_INFO_AFTER_LAST, 3189 __NL80211_STA_INFO_AFTER_LAST,
@@ -3277,8 +3293,10 @@ enum nl80211_mpath_flags {
3277 * &enum nl80211_mpath_flags; 3293 * &enum nl80211_mpath_flags;
3278 * @NL80211_MPATH_INFO_DISCOVERY_TIMEOUT: total path discovery timeout, in msec 3294 * @NL80211_MPATH_INFO_DISCOVERY_TIMEOUT: total path discovery timeout, in msec
3279 * @NL80211_MPATH_INFO_DISCOVERY_RETRIES: mesh path discovery retries 3295 * @NL80211_MPATH_INFO_DISCOVERY_RETRIES: mesh path discovery retries
3296 * @NL80211_MPATH_INFO_HOP_COUNT: hop count to destination
3297 * @NL80211_MPATH_INFO_PATH_CHANGE: total number of path changes to destination
3280 * @NL80211_MPATH_INFO_MAX: highest mesh path information attribute number 3298 * @NL80211_MPATH_INFO_MAX: highest mesh path information attribute number
3281 * currently defind 3299 * currently defined
3282 * @__NL80211_MPATH_INFO_AFTER_LAST: internal use 3300 * @__NL80211_MPATH_INFO_AFTER_LAST: internal use
3283 */ 3301 */
3284enum nl80211_mpath_info { 3302enum nl80211_mpath_info {
@@ -3290,6 +3308,8 @@ enum nl80211_mpath_info {
3290 NL80211_MPATH_INFO_FLAGS, 3308 NL80211_MPATH_INFO_FLAGS,
3291 NL80211_MPATH_INFO_DISCOVERY_TIMEOUT, 3309 NL80211_MPATH_INFO_DISCOVERY_TIMEOUT,
3292 NL80211_MPATH_INFO_DISCOVERY_RETRIES, 3310 NL80211_MPATH_INFO_DISCOVERY_RETRIES,
3311 NL80211_MPATH_INFO_HOP_COUNT,
3312 NL80211_MPATH_INFO_PATH_CHANGE,
3293 3313
3294 /* keep last */ 3314 /* keep last */
3295 __NL80211_MPATH_INFO_AFTER_LAST, 3315 __NL80211_MPATH_INFO_AFTER_LAST,
@@ -5316,6 +5336,13 @@ enum nl80211_feature_flags {
5316 * if this flag is not set. Ignoring this can leak clear text packets and/or 5336 * if this flag is not set. Ignoring this can leak clear text packets and/or
5317 * freeze the connection. 5337 * freeze the connection.
5318 * 5338 *
5339 * @NL80211_EXT_FEATURE_AIRTIME_FAIRNESS: Driver supports getting airtime
5340 * fairness for transmitted packets and has enabled airtime fairness
5341 * scheduling.
5342 *
5343 * @NL80211_EXT_FEATURE_AP_PMKSA_CACHING: Driver/device supports PMKSA caching
5344 * (set/del PMKSA operations) in AP mode.
5345 *
5319 * @NUM_NL80211_EXT_FEATURES: number of extended features. 5346 * @NUM_NL80211_EXT_FEATURES: number of extended features.
5320 * @MAX_NL80211_EXT_FEATURES: highest extended feature index. 5347 * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
5321 */ 5348 */
@@ -5355,6 +5382,8 @@ enum nl80211_ext_feature_index {
5355 NL80211_EXT_FEATURE_SCAN_MIN_PREQ_CONTENT, 5382 NL80211_EXT_FEATURE_SCAN_MIN_PREQ_CONTENT,
5356 NL80211_EXT_FEATURE_CAN_REPLACE_PTK0, 5383 NL80211_EXT_FEATURE_CAN_REPLACE_PTK0,
5357 NL80211_EXT_FEATURE_ENABLE_FTM_RESPONDER, 5384 NL80211_EXT_FEATURE_ENABLE_FTM_RESPONDER,
5385 NL80211_EXT_FEATURE_AIRTIME_FAIRNESS,
5386 NL80211_EXT_FEATURE_AP_PMKSA_CACHING,
5358 5387
5359 /* add new features before the definition below */ 5388 /* add new features before the definition below */
5360 NUM_NL80211_EXT_FEATURES, 5389 NUM_NL80211_EXT_FEATURES,
@@ -5606,9 +5635,14 @@ enum nl80211_crit_proto_id {
5606 * Used by cfg80211_rx_mgmt() 5635 * Used by cfg80211_rx_mgmt()
5607 * 5636 *
5608 * @NL80211_RXMGMT_FLAG_ANSWERED: frame was answered by device/driver. 5637 * @NL80211_RXMGMT_FLAG_ANSWERED: frame was answered by device/driver.
5638 * @NL80211_RXMGMT_FLAG_EXTERNAL_AUTH: Host driver intends to offload
5639 * the authentication. Exclusively defined for host drivers that
5640 * advertises the SME functionality but would like the userspace
5641 * to handle certain authentication algorithms (e.g. SAE).
5609 */ 5642 */
5610enum nl80211_rxmgmt_flags { 5643enum nl80211_rxmgmt_flags {
5611 NL80211_RXMGMT_FLAG_ANSWERED = 1 << 0, 5644 NL80211_RXMGMT_FLAG_ANSWERED = 1 << 0,
5645 NL80211_RXMGMT_FLAG_EXTERNAL_AUTH = 1 << 1,
5612}; 5646};
5613 5647
5614/* 5648/*
diff --git a/include/uapi/linux/nvme_ioctl.h b/include/uapi/linux/nvme_ioctl.h
index 6e74b1eaf541..1c215ea1798e 100644
--- a/include/uapi/linux/nvme_ioctl.h
+++ b/include/uapi/linux/nvme_ioctl.h
@@ -2,15 +2,6 @@
2/* 2/*
3 * Definitions for the NVM Express ioctl interface 3 * Definitions for the NVM Express ioctl interface
4 * Copyright (c) 2011-2014, Intel Corporation. 4 * Copyright (c) 2011-2014, Intel Corporation.
5 *
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms and conditions of the GNU General Public License,
8 * version 2, as published by the Free Software Foundation.
9 *
10 * This program is distributed in the hope it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13 * more details.
14 */ 5 */
15 6
16#ifndef _UAPI_LINUX_NVME_IOCTL_H 7#ifndef _UAPI_LINUX_NVME_IOCTL_H
diff --git a/include/uapi/linux/pci_regs.h b/include/uapi/linux/pci_regs.h
index e1e9888c85e6..5c98133f2c94 100644
--- a/include/uapi/linux/pci_regs.h
+++ b/include/uapi/linux/pci_regs.h
@@ -866,6 +866,7 @@
866#define PCI_ATS_CAP 0x04 /* ATS Capability Register */ 866#define PCI_ATS_CAP 0x04 /* ATS Capability Register */
867#define PCI_ATS_CAP_QDEP(x) ((x) & 0x1f) /* Invalidate Queue Depth */ 867#define PCI_ATS_CAP_QDEP(x) ((x) & 0x1f) /* Invalidate Queue Depth */
868#define PCI_ATS_MAX_QDEP 32 /* Max Invalidate Queue Depth */ 868#define PCI_ATS_MAX_QDEP 32 /* Max Invalidate Queue Depth */
869#define PCI_ATS_CAP_PAGE_ALIGNED 0x0020 /* Page Aligned Request */
869#define PCI_ATS_CTRL 0x06 /* ATS Control Register */ 870#define PCI_ATS_CTRL 0x06 /* ATS Control Register */
870#define PCI_ATS_CTRL_ENABLE 0x8000 /* ATS Enable */ 871#define PCI_ATS_CTRL_ENABLE 0x8000 /* ATS Enable */
871#define PCI_ATS_CTRL_STU(x) ((x) & 0x1f) /* Smallest Translation Unit */ 872#define PCI_ATS_CTRL_STU(x) ((x) & 0x1f) /* Smallest Translation Unit */
@@ -880,6 +881,7 @@
880#define PCI_PRI_STATUS_RF 0x001 /* Response Failure */ 881#define PCI_PRI_STATUS_RF 0x001 /* Response Failure */
881#define PCI_PRI_STATUS_UPRGI 0x002 /* Unexpected PRG index */ 882#define PCI_PRI_STATUS_UPRGI 0x002 /* Unexpected PRG index */
882#define PCI_PRI_STATUS_STOPPED 0x100 /* PRI Stopped */ 883#define PCI_PRI_STATUS_STOPPED 0x100 /* PRI Stopped */
884#define PCI_PRI_STATUS_PASID 0x8000 /* PRG Response PASID Required */
883#define PCI_PRI_MAX_REQ 0x08 /* PRI max reqs supported */ 885#define PCI_PRI_MAX_REQ 0x08 /* PRI max reqs supported */
884#define PCI_PRI_ALLOC_REQ 0x0c /* PRI max reqs allowed */ 886#define PCI_PRI_ALLOC_REQ 0x0c /* PRI max reqs allowed */
885#define PCI_EXT_CAP_PRI_SIZEOF 16 887#define PCI_EXT_CAP_PRI_SIZEOF 16
diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h
index 9de8780ac8d9..7198ddd0c6b1 100644
--- a/include/uapi/linux/perf_event.h
+++ b/include/uapi/linux/perf_event.h
@@ -372,7 +372,9 @@ struct perf_event_attr {
372 context_switch : 1, /* context switch data */ 372 context_switch : 1, /* context switch data */
373 write_backward : 1, /* Write ring buffer from end to beginning */ 373 write_backward : 1, /* Write ring buffer from end to beginning */
374 namespaces : 1, /* include namespaces data */ 374 namespaces : 1, /* include namespaces data */
375 __reserved_1 : 35; 375 ksymbol : 1, /* include ksymbol events */
376 bpf_event : 1, /* include bpf events */
377 __reserved_1 : 33;
376 378
377 union { 379 union {
378 __u32 wakeup_events; /* wakeup every n events */ 380 __u32 wakeup_events; /* wakeup every n events */
@@ -445,8 +447,6 @@ struct perf_event_query_bpf {
445 __u32 ids[0]; 447 __u32 ids[0];
446}; 448};
447 449
448#define perf_flags(attr) (*(&(attr)->read_format + 1))
449
450/* 450/*
451 * Ioctls that can be done on a perf event fd: 451 * Ioctls that can be done on a perf event fd:
452 */ 452 */
@@ -965,9 +965,58 @@ enum perf_event_type {
965 */ 965 */
966 PERF_RECORD_NAMESPACES = 16, 966 PERF_RECORD_NAMESPACES = 16,
967 967
968 /*
969 * Record ksymbol register/unregister events:
970 *
971 * struct {
972 * struct perf_event_header header;
973 * u64 addr;
974 * u32 len;
975 * u16 ksym_type;
976 * u16 flags;
977 * char name[];
978 * struct sample_id sample_id;
979 * };
980 */
981 PERF_RECORD_KSYMBOL = 17,
982
983 /*
984 * Record bpf events:
985 * enum perf_bpf_event_type {
986 * PERF_BPF_EVENT_UNKNOWN = 0,
987 * PERF_BPF_EVENT_PROG_LOAD = 1,
988 * PERF_BPF_EVENT_PROG_UNLOAD = 2,
989 * };
990 *
991 * struct {
992 * struct perf_event_header header;
993 * u16 type;
994 * u16 flags;
995 * u32 id;
996 * u8 tag[BPF_TAG_SIZE];
997 * struct sample_id sample_id;
998 * };
999 */
1000 PERF_RECORD_BPF_EVENT = 18,
1001
968 PERF_RECORD_MAX, /* non-ABI */ 1002 PERF_RECORD_MAX, /* non-ABI */
969}; 1003};
970 1004
1005enum perf_record_ksymbol_type {
1006 PERF_RECORD_KSYMBOL_TYPE_UNKNOWN = 0,
1007 PERF_RECORD_KSYMBOL_TYPE_BPF = 1,
1008 PERF_RECORD_KSYMBOL_TYPE_MAX /* non-ABI */
1009};
1010
1011#define PERF_RECORD_KSYMBOL_FLAGS_UNREGISTER (1 << 0)
1012
1013enum perf_bpf_event_type {
1014 PERF_BPF_EVENT_UNKNOWN = 0,
1015 PERF_BPF_EVENT_PROG_LOAD = 1,
1016 PERF_BPF_EVENT_PROG_UNLOAD = 2,
1017 PERF_BPF_EVENT_MAX, /* non-ABI */
1018};
1019
971#define PERF_MAX_STACK_DEPTH 127 1020#define PERF_MAX_STACK_DEPTH 127
972#define PERF_MAX_CONTEXTS_PER_STACK 8 1021#define PERF_MAX_CONTEXTS_PER_STACK 8
973 1022
diff --git a/include/uapi/linux/pkt_cls.h b/include/uapi/linux/pkt_cls.h
index 95d0db2a8350..51a0496f78ea 100644
--- a/include/uapi/linux/pkt_cls.h
+++ b/include/uapi/linux/pkt_cls.h
@@ -63,12 +63,49 @@ enum {
63#define TC_ACT_GOTO_CHAIN __TC_ACT_EXT(2) 63#define TC_ACT_GOTO_CHAIN __TC_ACT_EXT(2)
64#define TC_ACT_EXT_OPCODE_MAX TC_ACT_GOTO_CHAIN 64#define TC_ACT_EXT_OPCODE_MAX TC_ACT_GOTO_CHAIN
65 65
66/* These macros are put here for binary compatibility with userspace apps that
67 * make use of them. For kernel code and new userspace apps, use the TCA_ID_*
68 * versions.
69 */
70#define TCA_ACT_GACT 5
71#define TCA_ACT_IPT 6
72#define TCA_ACT_PEDIT 7
73#define TCA_ACT_MIRRED 8
74#define TCA_ACT_NAT 9
75#define TCA_ACT_XT 10
76#define TCA_ACT_SKBEDIT 11
77#define TCA_ACT_VLAN 12
78#define TCA_ACT_BPF 13
79#define TCA_ACT_CONNMARK 14
80#define TCA_ACT_SKBMOD 15
81#define TCA_ACT_CSUM 16
82#define TCA_ACT_TUNNEL_KEY 17
83#define TCA_ACT_SIMP 22
84#define TCA_ACT_IFE 25
85#define TCA_ACT_SAMPLE 26
86
66/* Action type identifiers*/ 87/* Action type identifiers*/
67enum { 88enum tca_id {
68 TCA_ID_UNSPEC=0, 89 TCA_ID_UNSPEC = 0,
69 TCA_ID_POLICE=1, 90 TCA_ID_POLICE = 1,
91 TCA_ID_GACT = TCA_ACT_GACT,
92 TCA_ID_IPT = TCA_ACT_IPT,
93 TCA_ID_PEDIT = TCA_ACT_PEDIT,
94 TCA_ID_MIRRED = TCA_ACT_MIRRED,
95 TCA_ID_NAT = TCA_ACT_NAT,
96 TCA_ID_XT = TCA_ACT_XT,
97 TCA_ID_SKBEDIT = TCA_ACT_SKBEDIT,
98 TCA_ID_VLAN = TCA_ACT_VLAN,
99 TCA_ID_BPF = TCA_ACT_BPF,
100 TCA_ID_CONNMARK = TCA_ACT_CONNMARK,
101 TCA_ID_SKBMOD = TCA_ACT_SKBMOD,
102 TCA_ID_CSUM = TCA_ACT_CSUM,
103 TCA_ID_TUNNEL_KEY = TCA_ACT_TUNNEL_KEY,
104 TCA_ID_SIMP = TCA_ACT_SIMP,
105 TCA_ID_IFE = TCA_ACT_IFE,
106 TCA_ID_SAMPLE = TCA_ACT_SAMPLE,
70 /* other actions go here */ 107 /* other actions go here */
71 __TCA_ID_MAX=255 108 __TCA_ID_MAX = 255
72}; 109};
73 110
74#define TCA_ID_MAX __TCA_ID_MAX 111#define TCA_ID_MAX __TCA_ID_MAX
@@ -333,12 +370,19 @@ enum {
333 370
334/* Basic filter */ 371/* Basic filter */
335 372
373struct tc_basic_pcnt {
374 __u64 rcnt;
375 __u64 rhit;
376};
377
336enum { 378enum {
337 TCA_BASIC_UNSPEC, 379 TCA_BASIC_UNSPEC,
338 TCA_BASIC_CLASSID, 380 TCA_BASIC_CLASSID,
339 TCA_BASIC_EMATCHES, 381 TCA_BASIC_EMATCHES,
340 TCA_BASIC_ACT, 382 TCA_BASIC_ACT,
341 TCA_BASIC_POLICE, 383 TCA_BASIC_POLICE,
384 TCA_BASIC_PCNT,
385 TCA_BASIC_PAD,
342 __TCA_BASIC_MAX 386 __TCA_BASIC_MAX
343}; 387};
344 388
@@ -527,11 +571,17 @@ enum {
527 571
528/* Match-all classifier */ 572/* Match-all classifier */
529 573
574struct tc_matchall_pcnt {
575 __u64 rhit;
576};
577
530enum { 578enum {
531 TCA_MATCHALL_UNSPEC, 579 TCA_MATCHALL_UNSPEC,
532 TCA_MATCHALL_CLASSID, 580 TCA_MATCHALL_CLASSID,
533 TCA_MATCHALL_ACT, 581 TCA_MATCHALL_ACT,
534 TCA_MATCHALL_FLAGS, 582 TCA_MATCHALL_FLAGS,
583 TCA_MATCHALL_PCNT,
584 TCA_MATCHALL_PAD,
535 __TCA_MATCHALL_MAX, 585 __TCA_MATCHALL_MAX,
536}; 586};
537 587
diff --git a/include/uapi/linux/pkt_sched.h b/include/uapi/linux/pkt_sched.h
index 0d18b1d1fbbc..7ee74c3474bf 100644
--- a/include/uapi/linux/pkt_sched.h
+++ b/include/uapi/linux/pkt_sched.h
@@ -954,7 +954,7 @@ enum {
954#define TCA_PIE_MAX (__TCA_PIE_MAX - 1) 954#define TCA_PIE_MAX (__TCA_PIE_MAX - 1)
955 955
956struct tc_pie_xstats { 956struct tc_pie_xstats {
957 __u32 prob; /* current probability */ 957 __u64 prob; /* current probability */
958 __u32 delay; /* current delay in ms */ 958 __u32 delay; /* current delay in ms */
959 __u32 avg_dq_rate; /* current average dq_rate in bits/pie_time */ 959 __u32 avg_dq_rate; /* current average dq_rate in bits/pie_time */
960 __u32 packets_in; /* total number of packets enqueued */ 960 __u32 packets_in; /* total number of packets enqueued */
@@ -1021,6 +1021,7 @@ enum {
1021 TCA_CAKE_INGRESS, 1021 TCA_CAKE_INGRESS,
1022 TCA_CAKE_ACK_FILTER, 1022 TCA_CAKE_ACK_FILTER,
1023 TCA_CAKE_SPLIT_GSO, 1023 TCA_CAKE_SPLIT_GSO,
1024 TCA_CAKE_FWMARK,
1024 __TCA_CAKE_MAX 1025 __TCA_CAKE_MAX
1025}; 1026};
1026#define TCA_CAKE_MAX (__TCA_CAKE_MAX - 1) 1027#define TCA_CAKE_MAX (__TCA_CAKE_MAX - 1)
diff --git a/include/uapi/linux/pmu.h b/include/uapi/linux/pmu.h
index 97256f90e6df..f2fc1bd80017 100644
--- a/include/uapi/linux/pmu.h
+++ b/include/uapi/linux/pmu.h
@@ -19,7 +19,9 @@
19#define PMU_POWER_CTRL 0x11 /* control power of some devices */ 19#define PMU_POWER_CTRL 0x11 /* control power of some devices */
20#define PMU_ADB_CMD 0x20 /* send ADB packet */ 20#define PMU_ADB_CMD 0x20 /* send ADB packet */
21#define PMU_ADB_POLL_OFF 0x21 /* disable ADB auto-poll */ 21#define PMU_ADB_POLL_OFF 0x21 /* disable ADB auto-poll */
22#define PMU_WRITE_XPRAM 0x32 /* write eXtended Parameter RAM */
22#define PMU_WRITE_NVRAM 0x33 /* write non-volatile RAM */ 23#define PMU_WRITE_NVRAM 0x33 /* write non-volatile RAM */
24#define PMU_READ_XPRAM 0x3a /* read eXtended Parameter RAM */
23#define PMU_READ_NVRAM 0x3b /* read non-volatile RAM */ 25#define PMU_READ_NVRAM 0x3b /* read non-volatile RAM */
24#define PMU_SET_RTC 0x30 /* set real-time clock */ 26#define PMU_SET_RTC 0x30 /* set real-time clock */
25#define PMU_READ_RTC 0x38 /* read real-time clock */ 27#define PMU_READ_RTC 0x38 /* read real-time clock */
diff --git a/include/uapi/linux/prctl.h b/include/uapi/linux/prctl.h
index b4875a93363a..094bb03b9cc2 100644
--- a/include/uapi/linux/prctl.h
+++ b/include/uapi/linux/prctl.h
@@ -219,6 +219,7 @@ struct prctl_mm_map {
219# define PR_SPEC_ENABLE (1UL << 1) 219# define PR_SPEC_ENABLE (1UL << 1)
220# define PR_SPEC_DISABLE (1UL << 2) 220# define PR_SPEC_DISABLE (1UL << 2)
221# define PR_SPEC_FORCE_DISABLE (1UL << 3) 221# define PR_SPEC_FORCE_DISABLE (1UL << 3)
222# define PR_SPEC_DISABLE_NOEXEC (1UL << 4)
222 223
223/* Reset arm64 pointer authentication keys */ 224/* Reset arm64 pointer authentication keys */
224#define PR_PAC_RESET_KEYS 54 225#define PR_PAC_RESET_KEYS 54
diff --git a/include/uapi/linux/rds.h b/include/uapi/linux/rds.h
index 8b73cb603c5f..5d0f76c780e5 100644
--- a/include/uapi/linux/rds.h
+++ b/include/uapi/linux/rds.h
@@ -69,6 +69,12 @@
69#define RDS_TRANS_COUNT 3 69#define RDS_TRANS_COUNT 3
70#define RDS_TRANS_NONE (~0) 70#define RDS_TRANS_NONE (~0)
71 71
72/* IOCTLS commands for SOL_RDS */
73#define SIOCRDSSETTOS (SIOCPROTOPRIVATE)
74#define SIOCRDSGETTOS (SIOCPROTOPRIVATE + 1)
75
76typedef __u8 rds_tos_t;
77
72/* 78/*
73 * Control message types for SOL_RDS. 79 * Control message types for SOL_RDS.
74 * 80 *
@@ -149,6 +155,7 @@ struct rds_info_connection {
149 __be32 faddr; 155 __be32 faddr;
150 __u8 transport[TRANSNAMSIZ]; /* null term ascii */ 156 __u8 transport[TRANSNAMSIZ]; /* null term ascii */
151 __u8 flags; 157 __u8 flags;
158 __u8 tos;
152} __attribute__((packed)); 159} __attribute__((packed));
153 160
154struct rds6_info_connection { 161struct rds6_info_connection {
@@ -171,6 +178,7 @@ struct rds_info_message {
171 __be16 lport; 178 __be16 lport;
172 __be16 fport; 179 __be16 fport;
173 __u8 flags; 180 __u8 flags;
181 __u8 tos;
174} __attribute__((packed)); 182} __attribute__((packed));
175 183
176struct rds6_info_message { 184struct rds6_info_message {
@@ -214,6 +222,7 @@ struct rds_info_tcp_socket {
214 __u32 last_sent_nxt; 222 __u32 last_sent_nxt;
215 __u32 last_expected_una; 223 __u32 last_expected_una;
216 __u32 last_seen_una; 224 __u32 last_seen_una;
225 __u8 tos;
217} __attribute__((packed)); 226} __attribute__((packed));
218 227
219struct rds6_info_tcp_socket { 228struct rds6_info_tcp_socket {
@@ -240,6 +249,7 @@ struct rds_info_rdma_connection {
240 __u32 max_send_sge; 249 __u32 max_send_sge;
241 __u32 rdma_mr_max; 250 __u32 rdma_mr_max;
242 __u32 rdma_mr_size; 251 __u32 rdma_mr_size;
252 __u8 tos;
243}; 253};
244 254
245struct rds6_info_rdma_connection { 255struct rds6_info_rdma_connection {
@@ -253,6 +263,7 @@ struct rds6_info_rdma_connection {
253 __u32 max_send_sge; 263 __u32 max_send_sge;
254 __u32 rdma_mr_max; 264 __u32 rdma_mr_max;
255 __u32 rdma_mr_size; 265 __u32 rdma_mr_size;
266 __u8 tos;
256}; 267};
257 268
258/* RDS message Receive Path Latency points */ 269/* RDS message Receive Path Latency points */
diff --git a/include/uapi/linux/sctp.h b/include/uapi/linux/sctp.h
index d584073532b8..b8f2c4d56532 100644
--- a/include/uapi/linux/sctp.h
+++ b/include/uapi/linux/sctp.h
@@ -59,6 +59,10 @@
59 59
60typedef __s32 sctp_assoc_t; 60typedef __s32 sctp_assoc_t;
61 61
62#define SCTP_FUTURE_ASSOC 0
63#define SCTP_CURRENT_ASSOC 1
64#define SCTP_ALL_ASSOC 2
65
62/* The following symbols come from the Sockets API Extensions for 66/* The following symbols come from the Sockets API Extensions for
63 * SCTP <draft-ietf-tsvwg-sctpsocket-07.txt>. 67 * SCTP <draft-ietf-tsvwg-sctpsocket-07.txt>.
64 */ 68 */
diff --git a/include/uapi/linux/serial_core.h b/include/uapi/linux/serial_core.h
index df4a7534e239..6009ee2c2e99 100644
--- a/include/uapi/linux/serial_core.h
+++ b/include/uapi/linux/serial_core.h
@@ -79,6 +79,9 @@
79/* Nuvoton UART */ 79/* Nuvoton UART */
80#define PORT_NPCM 40 80#define PORT_NPCM 40
81 81
82/* NVIDIA Tegra Combined UART */
83#define PORT_TEGRA_TCU 41
84
82/* Intel EG20 */ 85/* Intel EG20 */
83#define PORT_PCH_8LINE 44 86#define PORT_PCH_8LINE 44
84#define PORT_PCH_2LINE 45 87#define PORT_PCH_2LINE 45
diff --git a/include/uapi/linux/tc_act/tc_bpf.h b/include/uapi/linux/tc_act/tc_bpf.h
index 6e89a5df49a4..653c4f94f76e 100644
--- a/include/uapi/linux/tc_act/tc_bpf.h
+++ b/include/uapi/linux/tc_act/tc_bpf.h
@@ -13,8 +13,6 @@
13 13
14#include <linux/pkt_cls.h> 14#include <linux/pkt_cls.h>
15 15
16#define TCA_ACT_BPF 13
17
18struct tc_act_bpf { 16struct tc_act_bpf {
19 tc_gen; 17 tc_gen;
20}; 18};
diff --git a/include/uapi/linux/tc_act/tc_connmark.h b/include/uapi/linux/tc_act/tc_connmark.h
index 80caa47b1933..9f8f6f709feb 100644
--- a/include/uapi/linux/tc_act/tc_connmark.h
+++ b/include/uapi/linux/tc_act/tc_connmark.h
@@ -5,8 +5,6 @@
5#include <linux/types.h> 5#include <linux/types.h>
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7 7
8#define TCA_ACT_CONNMARK 14
9
10struct tc_connmark { 8struct tc_connmark {
11 tc_gen; 9 tc_gen;
12 __u16 zone; 10 __u16 zone;
diff --git a/include/uapi/linux/tc_act/tc_csum.h b/include/uapi/linux/tc_act/tc_csum.h
index 0ecf4d29e2f3..94b2044929de 100644
--- a/include/uapi/linux/tc_act/tc_csum.h
+++ b/include/uapi/linux/tc_act/tc_csum.h
@@ -5,8 +5,6 @@
5#include <linux/types.h> 5#include <linux/types.h>
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7 7
8#define TCA_ACT_CSUM 16
9
10enum { 8enum {
11 TCA_CSUM_UNSPEC, 9 TCA_CSUM_UNSPEC,
12 TCA_CSUM_PARMS, 10 TCA_CSUM_PARMS,
diff --git a/include/uapi/linux/tc_act/tc_gact.h b/include/uapi/linux/tc_act/tc_gact.h
index 94273c3b81b0..37e5392e02c7 100644
--- a/include/uapi/linux/tc_act/tc_gact.h
+++ b/include/uapi/linux/tc_act/tc_gact.h
@@ -5,7 +5,6 @@
5#include <linux/types.h> 5#include <linux/types.h>
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7 7
8#define TCA_ACT_GACT 5
9struct tc_gact { 8struct tc_gact {
10 tc_gen; 9 tc_gen;
11 10
diff --git a/include/uapi/linux/tc_act/tc_ife.h b/include/uapi/linux/tc_act/tc_ife.h
index 2f48490ef386..8c401f185675 100644
--- a/include/uapi/linux/tc_act/tc_ife.h
+++ b/include/uapi/linux/tc_act/tc_ife.h
@@ -6,7 +6,6 @@
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7#include <linux/ife.h> 7#include <linux/ife.h>
8 8
9#define TCA_ACT_IFE 25
10/* Flag bits for now just encoding/decoding; mutually exclusive */ 9/* Flag bits for now just encoding/decoding; mutually exclusive */
11#define IFE_ENCODE 1 10#define IFE_ENCODE 1
12#define IFE_DECODE 0 11#define IFE_DECODE 0
diff --git a/include/uapi/linux/tc_act/tc_ipt.h b/include/uapi/linux/tc_act/tc_ipt.h
index b743c8bddd13..c48d7da6750d 100644
--- a/include/uapi/linux/tc_act/tc_ipt.h
+++ b/include/uapi/linux/tc_act/tc_ipt.h
@@ -4,9 +4,6 @@
4 4
5#include <linux/pkt_cls.h> 5#include <linux/pkt_cls.h>
6 6
7#define TCA_ACT_IPT 6
8#define TCA_ACT_XT 10
9
10enum { 7enum {
11 TCA_IPT_UNSPEC, 8 TCA_IPT_UNSPEC,
12 TCA_IPT_TABLE, 9 TCA_IPT_TABLE,
diff --git a/include/uapi/linux/tc_act/tc_mirred.h b/include/uapi/linux/tc_act/tc_mirred.h
index 5dd671cf5776..2500a0005d05 100644
--- a/include/uapi/linux/tc_act/tc_mirred.h
+++ b/include/uapi/linux/tc_act/tc_mirred.h
@@ -5,7 +5,6 @@
5#include <linux/types.h> 5#include <linux/types.h>
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7 7
8#define TCA_ACT_MIRRED 8
9#define TCA_EGRESS_REDIR 1 /* packet redirect to EGRESS*/ 8#define TCA_EGRESS_REDIR 1 /* packet redirect to EGRESS*/
10#define TCA_EGRESS_MIRROR 2 /* mirror packet to EGRESS */ 9#define TCA_EGRESS_MIRROR 2 /* mirror packet to EGRESS */
11#define TCA_INGRESS_REDIR 3 /* packet redirect to INGRESS*/ 10#define TCA_INGRESS_REDIR 3 /* packet redirect to INGRESS*/
diff --git a/include/uapi/linux/tc_act/tc_nat.h b/include/uapi/linux/tc_act/tc_nat.h
index 086be842587b..21399c2c6130 100644
--- a/include/uapi/linux/tc_act/tc_nat.h
+++ b/include/uapi/linux/tc_act/tc_nat.h
@@ -5,8 +5,6 @@
5#include <linux/pkt_cls.h> 5#include <linux/pkt_cls.h>
6#include <linux/types.h> 6#include <linux/types.h>
7 7
8#define TCA_ACT_NAT 9
9
10enum { 8enum {
11 TCA_NAT_UNSPEC, 9 TCA_NAT_UNSPEC,
12 TCA_NAT_PARMS, 10 TCA_NAT_PARMS,
diff --git a/include/uapi/linux/tc_act/tc_pedit.h b/include/uapi/linux/tc_act/tc_pedit.h
index 24ec792dacc1..f3e61b04fa01 100644
--- a/include/uapi/linux/tc_act/tc_pedit.h
+++ b/include/uapi/linux/tc_act/tc_pedit.h
@@ -5,8 +5,6 @@
5#include <linux/types.h> 5#include <linux/types.h>
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7 7
8#define TCA_ACT_PEDIT 7
9
10enum { 8enum {
11 TCA_PEDIT_UNSPEC, 9 TCA_PEDIT_UNSPEC,
12 TCA_PEDIT_TM, 10 TCA_PEDIT_TM,
diff --git a/include/uapi/linux/tc_act/tc_sample.h b/include/uapi/linux/tc_act/tc_sample.h
index bd7e9f03abd2..fee1bcc20793 100644
--- a/include/uapi/linux/tc_act/tc_sample.h
+++ b/include/uapi/linux/tc_act/tc_sample.h
@@ -6,8 +6,6 @@
6#include <linux/pkt_cls.h> 6#include <linux/pkt_cls.h>
7#include <linux/if_ether.h> 7#include <linux/if_ether.h>
8 8
9#define TCA_ACT_SAMPLE 26
10
11struct tc_sample { 9struct tc_sample {
12 tc_gen; 10 tc_gen;
13}; 11};
diff --git a/include/uapi/linux/tc_act/tc_skbedit.h b/include/uapi/linux/tc_act/tc_skbedit.h
index 6de6071ebed6..800e93377218 100644
--- a/include/uapi/linux/tc_act/tc_skbedit.h
+++ b/include/uapi/linux/tc_act/tc_skbedit.h
@@ -23,8 +23,6 @@
23 23
24#include <linux/pkt_cls.h> 24#include <linux/pkt_cls.h>
25 25
26#define TCA_ACT_SKBEDIT 11
27
28#define SKBEDIT_F_PRIORITY 0x1 26#define SKBEDIT_F_PRIORITY 0x1
29#define SKBEDIT_F_QUEUE_MAPPING 0x2 27#define SKBEDIT_F_QUEUE_MAPPING 0x2
30#define SKBEDIT_F_MARK 0x4 28#define SKBEDIT_F_MARK 0x4
diff --git a/include/uapi/linux/tc_act/tc_skbmod.h b/include/uapi/linux/tc_act/tc_skbmod.h
index 38c072f66f2f..c525b3503797 100644
--- a/include/uapi/linux/tc_act/tc_skbmod.h
+++ b/include/uapi/linux/tc_act/tc_skbmod.h
@@ -13,8 +13,6 @@
13 13
14#include <linux/pkt_cls.h> 14#include <linux/pkt_cls.h>
15 15
16#define TCA_ACT_SKBMOD 15
17
18#define SKBMOD_F_DMAC 0x1 16#define SKBMOD_F_DMAC 0x1
19#define SKBMOD_F_SMAC 0x2 17#define SKBMOD_F_SMAC 0x2
20#define SKBMOD_F_ETYPE 0x4 18#define SKBMOD_F_ETYPE 0x4
diff --git a/include/uapi/linux/tc_act/tc_tunnel_key.h b/include/uapi/linux/tc_act/tc_tunnel_key.h
index be384d63e1b5..41c8b462c177 100644
--- a/include/uapi/linux/tc_act/tc_tunnel_key.h
+++ b/include/uapi/linux/tc_act/tc_tunnel_key.h
@@ -14,8 +14,6 @@
14 14
15#include <linux/pkt_cls.h> 15#include <linux/pkt_cls.h>
16 16
17#define TCA_ACT_TUNNEL_KEY 17
18
19#define TCA_TUNNEL_KEY_ACT_SET 1 17#define TCA_TUNNEL_KEY_ACT_SET 1
20#define TCA_TUNNEL_KEY_ACT_RELEASE 2 18#define TCA_TUNNEL_KEY_ACT_RELEASE 2
21 19
diff --git a/include/uapi/linux/tc_act/tc_vlan.h b/include/uapi/linux/tc_act/tc_vlan.h
index 0d7b5fd6605b..168995b54a70 100644
--- a/include/uapi/linux/tc_act/tc_vlan.h
+++ b/include/uapi/linux/tc_act/tc_vlan.h
@@ -13,8 +13,6 @@
13 13
14#include <linux/pkt_cls.h> 14#include <linux/pkt_cls.h>
15 15
16#define TCA_ACT_VLAN 12
17
18#define TCA_VLAN_ACT_POP 1 16#define TCA_VLAN_ACT_POP 1
19#define TCA_VLAN_ACT_PUSH 2 17#define TCA_VLAN_ACT_PUSH 2
20#define TCA_VLAN_ACT_MODIFY 3 18#define TCA_VLAN_ACT_MODIFY 3
diff --git a/include/uapi/linux/time.h b/include/uapi/linux/time.h
index 6b56a2208be7..958932effc5e 100644
--- a/include/uapi/linux/time.h
+++ b/include/uapi/linux/time.h
@@ -3,7 +3,7 @@
3#define _UAPI_LINUX_TIME_H 3#define _UAPI_LINUX_TIME_H
4 4
5#include <linux/types.h> 5#include <linux/types.h>
6 6#include <linux/time_types.h>
7 7
8#ifndef _STRUCT_TIMESPEC 8#ifndef _STRUCT_TIMESPEC
9#define _STRUCT_TIMESPEC 9#define _STRUCT_TIMESPEC
@@ -23,7 +23,6 @@ struct timezone {
23 int tz_dsttime; /* type of dst correction */ 23 int tz_dsttime; /* type of dst correction */
24}; 24};
25 25
26
27/* 26/*
28 * Names of the interval timers, and structure 27 * Names of the interval timers, and structure
29 * defining a timer setting: 28 * defining a timer setting:
@@ -42,32 +41,6 @@ struct itimerval {
42 struct timeval it_value; /* current value */ 41 struct timeval it_value; /* current value */
43}; 42};
44 43
45#ifndef __kernel_timespec
46struct __kernel_timespec {
47 __kernel_time64_t tv_sec; /* seconds */
48 long long tv_nsec; /* nanoseconds */
49};
50#endif
51
52#ifndef __kernel_itimerspec
53struct __kernel_itimerspec {
54 struct __kernel_timespec it_interval; /* timer period */
55 struct __kernel_timespec it_value; /* timer expiration */
56};
57#endif
58
59/*
60 * legacy timeval structure, only embedded in structures that
61 * traditionally used 'timeval' to pass time intervals (not absolute
62 * times). Do not add new users. If user space fails to compile
63 * here, this is probably because it is not y2038 safe and needs to
64 * be changed to use another interface.
65 */
66struct __kernel_old_timeval {
67 __kernel_long_t tv_sec;
68 __kernel_long_t tv_usec;
69};
70
71/* 44/*
72 * The IDs of the various system clocks (for POSIX.1b interval timers): 45 * The IDs of the various system clocks (for POSIX.1b interval timers):
73 */ 46 */
diff --git a/include/uapi/linux/time_types.h b/include/uapi/linux/time_types.h
new file mode 100644
index 000000000000..27bfc8fc6904
--- /dev/null
+++ b/include/uapi/linux/time_types.h
@@ -0,0 +1,36 @@
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2#ifndef _UAPI_LINUX_TIME_TYPES_H
3#define _UAPI_LINUX_TIME_TYPES_H
4
5#include <linux/types.h>
6
7struct __kernel_timespec {
8 __kernel_time64_t tv_sec; /* seconds */
9 long long tv_nsec; /* nanoseconds */
10};
11
12struct __kernel_itimerspec {
13 struct __kernel_timespec it_interval; /* timer period */
14 struct __kernel_timespec it_value; /* timer expiration */
15};
16
17/*
18 * legacy timeval structure, only embedded in structures that
19 * traditionally used 'timeval' to pass time intervals (not absolute
20 * times). Do not add new users. If user space fails to compile
21 * here, this is probably because it is not y2038 safe and needs to
22 * be changed to use another interface.
23 */
24#ifndef __kernel_old_timeval
25struct __kernel_old_timeval {
26 __kernel_long_t tv_sec;
27 __kernel_long_t tv_usec;
28};
29#endif
30
31struct __kernel_sock_timeval {
32 __s64 tv_sec;
33 __s64 tv_usec;
34};
35
36#endif /* _UAPI_LINUX_TIME_TYPES_H */
diff --git a/include/uapi/linux/timex.h b/include/uapi/linux/timex.h
index 92685d826444..9f517f9010bb 100644
--- a/include/uapi/linux/timex.h
+++ b/include/uapi/linux/timex.h
@@ -92,6 +92,45 @@ struct timex {
92 int :32; int :32; int :32; 92 int :32; int :32; int :32;
93}; 93};
94 94
95struct __kernel_timex_timeval {
96 __kernel_time64_t tv_sec;
97 long long tv_usec;
98};
99
100struct __kernel_timex {
101 unsigned int modes; /* mode selector */
102 int :32; /* pad */
103 long long offset; /* time offset (usec) */
104 long long freq; /* frequency offset (scaled ppm) */
105 long long maxerror;/* maximum error (usec) */
106 long long esterror;/* estimated error (usec) */
107 int status; /* clock command/status */
108 int :32; /* pad */
109 long long constant;/* pll time constant */
110 long long precision;/* clock precision (usec) (read only) */
111 long long tolerance;/* clock frequency tolerance (ppm)
112 * (read only)
113 */
114 struct __kernel_timex_timeval time; /* (read only, except for ADJ_SETOFFSET) */
115 long long tick; /* (modified) usecs between clock ticks */
116
117 long long ppsfreq;/* pps frequency (scaled ppm) (ro) */
118 long long jitter; /* pps jitter (us) (ro) */
119 int shift; /* interval duration (s) (shift) (ro) */
120 int :32; /* pad */
121 long long stabil; /* pps stability (scaled ppm) (ro) */
122 long long jitcnt; /* jitter limit exceeded (ro) */
123 long long calcnt; /* calibration intervals (ro) */
124 long long errcnt; /* calibration errors (ro) */
125 long long stbcnt; /* stability limit exceeded (ro) */
126
127 int tai; /* TAI offset (ro) */
128
129 int :32; int :32; int :32; int :32;
130 int :32; int :32; int :32; int :32;
131 int :32; int :32; int :32;
132};
133
95/* 134/*
96 * Mode codes (timex.mode) 135 * Mode codes (timex.mode)
97 */ 136 */
diff --git a/include/uapi/linux/tls.h b/include/uapi/linux/tls.h
index ff02287495ac..401d6f01de6a 100644
--- a/include/uapi/linux/tls.h
+++ b/include/uapi/linux/tls.h
@@ -51,6 +51,10 @@
51#define TLS_1_2_VERSION_MINOR 0x3 51#define TLS_1_2_VERSION_MINOR 0x3
52#define TLS_1_2_VERSION TLS_VERSION_NUMBER(TLS_1_2) 52#define TLS_1_2_VERSION TLS_VERSION_NUMBER(TLS_1_2)
53 53
54#define TLS_1_3_VERSION_MAJOR 0x3
55#define TLS_1_3_VERSION_MINOR 0x4
56#define TLS_1_3_VERSION TLS_VERSION_NUMBER(TLS_1_3)
57
54/* Supported ciphers */ 58/* Supported ciphers */
55#define TLS_CIPHER_AES_GCM_128 51 59#define TLS_CIPHER_AES_GCM_128 51
56#define TLS_CIPHER_AES_GCM_128_IV_SIZE 8 60#define TLS_CIPHER_AES_GCM_128_IV_SIZE 8
@@ -59,6 +63,13 @@
59#define TLS_CIPHER_AES_GCM_128_TAG_SIZE 16 63#define TLS_CIPHER_AES_GCM_128_TAG_SIZE 16
60#define TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE 8 64#define TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE 8
61 65
66#define TLS_CIPHER_AES_GCM_256 52
67#define TLS_CIPHER_AES_GCM_256_IV_SIZE 8
68#define TLS_CIPHER_AES_GCM_256_KEY_SIZE 32
69#define TLS_CIPHER_AES_GCM_256_SALT_SIZE 4
70#define TLS_CIPHER_AES_GCM_256_TAG_SIZE 16
71#define TLS_CIPHER_AES_GCM_256_REC_SEQ_SIZE 8
72
62#define TLS_SET_RECORD_TYPE 1 73#define TLS_SET_RECORD_TYPE 1
63#define TLS_GET_RECORD_TYPE 2 74#define TLS_GET_RECORD_TYPE 2
64 75
@@ -75,4 +86,12 @@ struct tls12_crypto_info_aes_gcm_128 {
75 unsigned char rec_seq[TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE]; 86 unsigned char rec_seq[TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE];
76}; 87};
77 88
89struct tls12_crypto_info_aes_gcm_256 {
90 struct tls_crypto_info info;
91 unsigned char iv[TLS_CIPHER_AES_GCM_256_IV_SIZE];
92 unsigned char key[TLS_CIPHER_AES_GCM_256_KEY_SIZE];
93 unsigned char salt[TLS_CIPHER_AES_GCM_256_SALT_SIZE];
94 unsigned char rec_seq[TLS_CIPHER_AES_GCM_256_REC_SEQ_SIZE];
95};
96
78#endif /* _UAPI_LINUX_TLS_H */ 97#endif /* _UAPI_LINUX_TLS_H */
diff --git a/include/uapi/linux/v4l2-controls.h b/include/uapi/linux/v4l2-controls.h
index 3dcfc6148f99..06479f2fb3ae 100644
--- a/include/uapi/linux/v4l2-controls.h
+++ b/include/uapi/linux/v4l2-controls.h
@@ -533,6 +533,8 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type {
533}; 533};
534#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER (V4L2_CID_MPEG_BASE+381) 534#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER (V4L2_CID_MPEG_BASE+381)
535#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (V4L2_CID_MPEG_BASE+382) 535#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (V4L2_CID_MPEG_BASE+382)
536#define V4L2_CID_MPEG_VIDEO_H264_CONSTRAINED_INTRA_PREDICTION (V4L2_CID_MPEG_BASE+383)
537#define V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (V4L2_CID_MPEG_BASE+384)
536#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (V4L2_CID_MPEG_BASE+400) 538#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (V4L2_CID_MPEG_BASE+400)
537#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (V4L2_CID_MPEG_BASE+401) 539#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (V4L2_CID_MPEG_BASE+401)
538#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (V4L2_CID_MPEG_BASE+402) 540#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (V4L2_CID_MPEG_BASE+402)
diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h
index b5671ce2724f..1db220da3bcc 100644
--- a/include/uapi/linux/videodev2.h
+++ b/include/uapi/linux/videodev2.h
@@ -130,6 +130,13 @@ enum v4l2_field {
130 ((field) == V4L2_FIELD_BOTTOM ||\ 130 ((field) == V4L2_FIELD_BOTTOM ||\
131 (field) == V4L2_FIELD_TOP ||\ 131 (field) == V4L2_FIELD_TOP ||\
132 (field) == V4L2_FIELD_ALTERNATE) 132 (field) == V4L2_FIELD_ALTERNATE)
133#define V4L2_FIELD_IS_INTERLACED(field) \
134 ((field) == V4L2_FIELD_INTERLACED ||\
135 (field) == V4L2_FIELD_INTERLACED_TB ||\
136 (field) == V4L2_FIELD_INTERLACED_BT)
137#define V4L2_FIELD_IS_SEQUENTIAL(field) \
138 ((field) == V4L2_FIELD_SEQ_TB ||\
139 (field) == V4L2_FIELD_SEQ_BT)
133 140
134enum v4l2_buf_type { 141enum v4l2_buf_type {
135 V4L2_BUF_TYPE_VIDEO_CAPTURE = 1, 142 V4L2_BUF_TYPE_VIDEO_CAPTURE = 1,
@@ -161,7 +168,8 @@ enum v4l2_buf_type {
161 || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY \ 168 || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY \
162 || (type) == V4L2_BUF_TYPE_VBI_OUTPUT \ 169 || (type) == V4L2_BUF_TYPE_VBI_OUTPUT \
163 || (type) == V4L2_BUF_TYPE_SLICED_VBI_OUTPUT \ 170 || (type) == V4L2_BUF_TYPE_SLICED_VBI_OUTPUT \
164 || (type) == V4L2_BUF_TYPE_SDR_OUTPUT) 171 || (type) == V4L2_BUF_TYPE_SDR_OUTPUT \
172 || (type) == V4L2_BUF_TYPE_META_OUTPUT)
165 173
166enum v4l2_tuner_type { 174enum v4l2_tuner_type {
167 V4L2_TUNER_RADIO = 1, 175 V4L2_TUNER_RADIO = 1,
@@ -554,6 +562,10 @@ struct v4l2_pix_format {
554#define V4L2_PIX_FMT_YUV555 v4l2_fourcc('Y', 'U', 'V', 'O') /* 16 YUV-5-5-5 */ 562#define V4L2_PIX_FMT_YUV555 v4l2_fourcc('Y', 'U', 'V', 'O') /* 16 YUV-5-5-5 */
555#define V4L2_PIX_FMT_YUV565 v4l2_fourcc('Y', 'U', 'V', 'P') /* 16 YUV-5-6-5 */ 563#define V4L2_PIX_FMT_YUV565 v4l2_fourcc('Y', 'U', 'V', 'P') /* 16 YUV-5-6-5 */
556#define V4L2_PIX_FMT_YUV32 v4l2_fourcc('Y', 'U', 'V', '4') /* 32 YUV-8-8-8-8 */ 564#define V4L2_PIX_FMT_YUV32 v4l2_fourcc('Y', 'U', 'V', '4') /* 32 YUV-8-8-8-8 */
565#define V4L2_PIX_FMT_AYUV32 v4l2_fourcc('A', 'Y', 'U', 'V') /* 32 AYUV-8-8-8-8 */
566#define V4L2_PIX_FMT_XYUV32 v4l2_fourcc('X', 'Y', 'U', 'V') /* 32 XYUV-8-8-8-8 */
567#define V4L2_PIX_FMT_VUYA32 v4l2_fourcc('V', 'U', 'Y', 'A') /* 32 VUYA-8-8-8-8 */
568#define V4L2_PIX_FMT_VUYX32 v4l2_fourcc('V', 'U', 'Y', 'X') /* 32 VUYX-8-8-8-8 */
557#define V4L2_PIX_FMT_HI240 v4l2_fourcc('H', 'I', '2', '4') /* 8 8-bit color */ 569#define V4L2_PIX_FMT_HI240 v4l2_fourcc('H', 'I', '2', '4') /* 8 8-bit color */
558#define V4L2_PIX_FMT_HM12 v4l2_fourcc('H', 'M', '1', '2') /* 8 YUV 4:2:0 16x16 macroblocks */ 570#define V4L2_PIX_FMT_HM12 v4l2_fourcc('H', 'M', '1', '2') /* 8 YUV 4:2:0 16x16 macroblocks */
559#define V4L2_PIX_FMT_M420 v4l2_fourcc('M', '4', '2', '0') /* 12 YUV 4:2:0 2 lines y, 1 line uv interleaved */ 571#define V4L2_PIX_FMT_M420 v4l2_fourcc('M', '4', '2', '0') /* 12 YUV 4:2:0 2 lines y, 1 line uv interleaved */
@@ -973,6 +985,18 @@ struct v4l2_buffer {
973 }; 985 };
974}; 986};
975 987
988/**
989 * v4l2_timeval_to_ns - Convert timeval to nanoseconds
990 * @ts: pointer to the timeval variable to be converted
991 *
992 * Returns the scalar nanosecond representation of the timeval
993 * parameter.
994 */
995static inline __u64 v4l2_timeval_to_ns(const struct timeval *tv)
996{
997 return (__u64)tv->tv_sec * 1000000000ULL + tv->tv_usec * 1000;
998}
999
976/* Flags for 'flags' field */ 1000/* Flags for 'flags' field */
977/* Buffer is mapped (flag) */ 1001/* Buffer is mapped (flag) */
978#define V4L2_BUF_FLAG_MAPPED 0x00000001 1002#define V4L2_BUF_FLAG_MAPPED 0x00000001
diff --git a/include/uapi/linux/xdp_diag.h b/include/uapi/linux/xdp_diag.h
new file mode 100644
index 000000000000..78b2591a7782
--- /dev/null
+++ b/include/uapi/linux/xdp_diag.h
@@ -0,0 +1,72 @@
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2/*
3 * xdp_diag: interface for query/monitor XDP sockets
4 * Copyright(c) 2019 Intel Corporation.
5 */
6
7#ifndef _LINUX_XDP_DIAG_H
8#define _LINUX_XDP_DIAG_H
9
10#include <linux/types.h>
11
12struct xdp_diag_req {
13 __u8 sdiag_family;
14 __u8 sdiag_protocol;
15 __u16 pad;
16 __u32 xdiag_ino;
17 __u32 xdiag_show;
18 __u32 xdiag_cookie[2];
19};
20
21struct xdp_diag_msg {
22 __u8 xdiag_family;
23 __u8 xdiag_type;
24 __u16 pad;
25 __u32 xdiag_ino;
26 __u32 xdiag_cookie[2];
27};
28
29#define XDP_SHOW_INFO (1 << 0) /* Basic information */
30#define XDP_SHOW_RING_CFG (1 << 1)
31#define XDP_SHOW_UMEM (1 << 2)
32#define XDP_SHOW_MEMINFO (1 << 3)
33
34enum {
35 XDP_DIAG_NONE,
36 XDP_DIAG_INFO,
37 XDP_DIAG_UID,
38 XDP_DIAG_RX_RING,
39 XDP_DIAG_TX_RING,
40 XDP_DIAG_UMEM,
41 XDP_DIAG_UMEM_FILL_RING,
42 XDP_DIAG_UMEM_COMPLETION_RING,
43 XDP_DIAG_MEMINFO,
44 __XDP_DIAG_MAX,
45};
46
47#define XDP_DIAG_MAX (__XDP_DIAG_MAX - 1)
48
49struct xdp_diag_info {
50 __u32 ifindex;
51 __u32 queue_id;
52};
53
54struct xdp_diag_ring {
55 __u32 entries; /*num descs */
56};
57
58#define XDP_DU_F_ZEROCOPY (1 << 0)
59
60struct xdp_diag_umem {
61 __u64 size;
62 __u32 id;
63 __u32 num_pages;
64 __u32 chunk_size;
65 __u32 headroom;
66 __u32 ifindex;
67 __u32 queue_id;
68 __u32 flags;
69 __u32 refs;
70};
71
72#endif /* _LINUX_XDP_DIAG_H */
diff --git a/include/uapi/misc/fastrpc.h b/include/uapi/misc/fastrpc.h
new file mode 100644
index 000000000000..6d701af9fc42
--- /dev/null
+++ b/include/uapi/misc/fastrpc.h
@@ -0,0 +1,41 @@
1/* SPDX-License-Identifier: GPL-2.0 */
2
3#ifndef __QCOM_FASTRPC_H__
4#define __QCOM_FASTRPC_H__
5
6#include <linux/types.h>
7
8#define FASTRPC_IOCTL_ALLOC_DMA_BUFF _IOWR('R', 1, struct fastrpc_alloc_dma_buf)
9#define FASTRPC_IOCTL_FREE_DMA_BUFF _IOWR('R', 2, __u32)
10#define FASTRPC_IOCTL_INVOKE _IOWR('R', 3, struct fastrpc_invoke)
11#define FASTRPC_IOCTL_INIT_ATTACH _IO('R', 4)
12#define FASTRPC_IOCTL_INIT_CREATE _IOWR('R', 5, struct fastrpc_init_create)
13
14struct fastrpc_invoke_args {
15 __u64 ptr;
16 __u64 length;
17 __s32 fd;
18 __u32 reserved;
19};
20
21struct fastrpc_invoke {
22 __u32 handle;
23 __u32 sc;
24 __u64 args;
25};
26
27struct fastrpc_init_create {
28 __u32 filelen; /* elf file length */
29 __s32 filefd; /* fd for the file */
30 __u32 attrs;
31 __u32 siglen;
32 __u64 file; /* pointer to elf file */
33};
34
35struct fastrpc_alloc_dma_buf {
36 __s32 fd; /* fd */
37 __u32 flags; /* flags to map with */
38 __u64 size; /* size */
39};
40
41#endif /* __QCOM_FASTRPC_H__ */
diff --git a/include/uapi/misc/habanalabs.h b/include/uapi/misc/habanalabs.h
new file mode 100644
index 000000000000..7fd6f633534c
--- /dev/null
+++ b/include/uapi/misc/habanalabs.h
@@ -0,0 +1,450 @@
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
2 *
3 * Copyright 2016-2018 HabanaLabs, Ltd.
4 * All Rights Reserved.
5 *
6 */
7
8#ifndef HABANALABS_H_
9#define HABANALABS_H_
10
11#include <linux/types.h>
12#include <linux/ioctl.h>
13
14/*
15 * Defines that are asic-specific but constitutes as ABI between kernel driver
16 * and userspace
17 */
18#define GOYA_KMD_SRAM_RESERVED_SIZE_FROM_START 0x8000 /* 32KB */
19
20/*
21 * Queue Numbering
22 *
23 * The external queues (DMA channels + CPU) MUST be before the internal queues
24 * and each group (DMA channels + CPU and internal) must be contiguous inside
25 * itself but there can be a gap between the two groups (although not
26 * recommended)
27 */
28
29enum goya_queue_id {
30 GOYA_QUEUE_ID_DMA_0 = 0,
31 GOYA_QUEUE_ID_DMA_1,
32 GOYA_QUEUE_ID_DMA_2,
33 GOYA_QUEUE_ID_DMA_3,
34 GOYA_QUEUE_ID_DMA_4,
35 GOYA_QUEUE_ID_CPU_PQ,
36 GOYA_QUEUE_ID_MME,
37 GOYA_QUEUE_ID_TPC0,
38 GOYA_QUEUE_ID_TPC1,
39 GOYA_QUEUE_ID_TPC2,
40 GOYA_QUEUE_ID_TPC3,
41 GOYA_QUEUE_ID_TPC4,
42 GOYA_QUEUE_ID_TPC5,
43 GOYA_QUEUE_ID_TPC6,
44 GOYA_QUEUE_ID_TPC7,
45 GOYA_QUEUE_ID_SIZE
46};
47
48/* Opcode for management ioctl */
49#define HL_INFO_HW_IP_INFO 0
50#define HL_INFO_HW_EVENTS 1
51#define HL_INFO_DRAM_USAGE 2
52#define HL_INFO_HW_IDLE 3
53
54#define HL_INFO_VERSION_MAX_LEN 128
55
56struct hl_info_hw_ip_info {
57 __u64 sram_base_address;
58 __u64 dram_base_address;
59 __u64 dram_size;
60 __u32 sram_size;
61 __u32 num_of_events;
62 __u32 device_id; /* PCI Device ID */
63 __u32 reserved[3];
64 __u32 armcp_cpld_version;
65 __u32 psoc_pci_pll_nr;
66 __u32 psoc_pci_pll_nf;
67 __u32 psoc_pci_pll_od;
68 __u32 psoc_pci_pll_div_factor;
69 __u8 tpc_enabled_mask;
70 __u8 dram_enabled;
71 __u8 pad[2];
72 __u8 armcp_version[HL_INFO_VERSION_MAX_LEN];
73};
74
75struct hl_info_dram_usage {
76 __u64 dram_free_mem;
77 __u64 ctx_dram_mem;
78};
79
80struct hl_info_hw_idle {
81 __u32 is_idle;
82 __u32 pad;
83};
84
85struct hl_info_args {
86 /* Location of relevant struct in userspace */
87 __u64 return_pointer;
88 /*
89 * The size of the return value. Just like "size" in "snprintf",
90 * it limits how many bytes the kernel can write
91 *
92 * For hw_events array, the size should be
93 * hl_info_hw_ip_info.num_of_events * sizeof(__u32)
94 */
95 __u32 return_size;
96
97 /* HL_INFO_* */
98 __u32 op;
99
100 /* Context ID - Currently not in use */
101 __u32 ctx_id;
102 __u32 pad;
103};
104
105/* Opcode to create a new command buffer */
106#define HL_CB_OP_CREATE 0
107/* Opcode to destroy previously created command buffer */
108#define HL_CB_OP_DESTROY 1
109
110struct hl_cb_in {
111 /* Handle of CB or 0 if we want to create one */
112 __u64 cb_handle;
113 /* HL_CB_OP_* */
114 __u32 op;
115 /* Size of CB. Maximum size is 2MB. The minimum size that will be
116 * allocated, regardless of this parameter's value, is PAGE_SIZE
117 */
118 __u32 cb_size;
119 /* Context ID - Currently not in use */
120 __u32 ctx_id;
121 __u32 pad;
122};
123
124struct hl_cb_out {
125 /* Handle of CB */
126 __u64 cb_handle;
127};
128
129union hl_cb_args {
130 struct hl_cb_in in;
131 struct hl_cb_out out;
132};
133
134/*
135 * This structure size must always be fixed to 64-bytes for backward
136 * compatibility
137 */
138struct hl_cs_chunk {
139 /*
140 * For external queue, this represents a Handle of CB on the Host
141 * For internal queue, this represents an SRAM or DRAM address of the
142 * internal CB
143 */
144 __u64 cb_handle;
145 /* Index of queue to put the CB on */
146 __u32 queue_index;
147 /*
148 * Size of command buffer with valid packets
149 * Can be smaller then actual CB size
150 */
151 __u32 cb_size;
152 /* HL_CS_CHUNK_FLAGS_* */
153 __u32 cs_chunk_flags;
154 /* Align structure to 64 bytes */
155 __u32 pad[11];
156};
157
158#define HL_CS_FLAGS_FORCE_RESTORE 0x1
159
160#define HL_CS_STATUS_SUCCESS 0
161
162struct hl_cs_in {
163 /* this holds address of array of hl_cs_chunk for restore phase */
164 __u64 chunks_restore;
165 /* this holds address of array of hl_cs_chunk for execution phase */
166 __u64 chunks_execute;
167 /* this holds address of array of hl_cs_chunk for store phase -
168 * Currently not in use
169 */
170 __u64 chunks_store;
171 /* Number of chunks in restore phase array */
172 __u32 num_chunks_restore;
173 /* Number of chunks in execution array */
174 __u32 num_chunks_execute;
175 /* Number of chunks in restore phase array - Currently not in use */
176 __u32 num_chunks_store;
177 /* HL_CS_FLAGS_* */
178 __u32 cs_flags;
179 /* Context ID - Currently not in use */
180 __u32 ctx_id;
181};
182
183struct hl_cs_out {
184 /* this holds the sequence number of the CS to pass to wait ioctl */
185 __u64 seq;
186 /* HL_CS_STATUS_* */
187 __u32 status;
188 __u32 pad;
189};
190
191union hl_cs_args {
192 struct hl_cs_in in;
193 struct hl_cs_out out;
194};
195
196struct hl_wait_cs_in {
197 /* Command submission sequence number */
198 __u64 seq;
199 /* Absolute timeout to wait in microseconds */
200 __u64 timeout_us;
201 /* Context ID - Currently not in use */
202 __u32 ctx_id;
203 __u32 pad;
204};
205
206#define HL_WAIT_CS_STATUS_COMPLETED 0
207#define HL_WAIT_CS_STATUS_BUSY 1
208#define HL_WAIT_CS_STATUS_TIMEDOUT 2
209#define HL_WAIT_CS_STATUS_ABORTED 3
210#define HL_WAIT_CS_STATUS_INTERRUPTED 4
211
212struct hl_wait_cs_out {
213 /* HL_WAIT_CS_STATUS_* */
214 __u32 status;
215 __u32 pad;
216};
217
218union hl_wait_cs_args {
219 struct hl_wait_cs_in in;
220 struct hl_wait_cs_out out;
221};
222
223/* Opcode to alloc device memory */
224#define HL_MEM_OP_ALLOC 0
225/* Opcode to free previously allocated device memory */
226#define HL_MEM_OP_FREE 1
227/* Opcode to map host memory */
228#define HL_MEM_OP_MAP 2
229/* Opcode to unmap previously mapped host memory */
230#define HL_MEM_OP_UNMAP 3
231
232/* Memory flags */
233#define HL_MEM_CONTIGUOUS 0x1
234#define HL_MEM_SHARED 0x2
235#define HL_MEM_USERPTR 0x4
236
237struct hl_mem_in {
238 union {
239 /* HL_MEM_OP_ALLOC- allocate device memory */
240 struct {
241 /* Size to alloc */
242 __u64 mem_size;
243 } alloc;
244
245 /* HL_MEM_OP_FREE - free device memory */
246 struct {
247 /* Handle returned from HL_MEM_OP_ALLOC */
248 __u64 handle;
249 } free;
250
251 /* HL_MEM_OP_MAP - map device memory */
252 struct {
253 /*
254 * Requested virtual address of mapped memory.
255 * KMD will try to map the requested region to this
256 * hint address, as long as the address is valid and
257 * not already mapped. The user should check the
258 * returned address of the IOCTL to make sure he got
259 * the hint address. Passing 0 here means that KMD
260 * will choose the address itself.
261 */
262 __u64 hint_addr;
263 /* Handle returned from HL_MEM_OP_ALLOC */
264 __u64 handle;
265 } map_device;
266
267 /* HL_MEM_OP_MAP - map host memory */
268 struct {
269 /* Address of allocated host memory */
270 __u64 host_virt_addr;
271 /*
272 * Requested virtual address of mapped memory.
273 * KMD will try to map the requested region to this
274 * hint address, as long as the address is valid and
275 * not already mapped. The user should check the
276 * returned address of the IOCTL to make sure he got
277 * the hint address. Passing 0 here means that KMD
278 * will choose the address itself.
279 */
280 __u64 hint_addr;
281 /* Size of allocated host memory */
282 __u64 mem_size;
283 } map_host;
284
285 /* HL_MEM_OP_UNMAP - unmap host memory */
286 struct {
287 /* Virtual address returned from HL_MEM_OP_MAP */
288 __u64 device_virt_addr;
289 } unmap;
290 };
291
292 /* HL_MEM_OP_* */
293 __u32 op;
294 /* HL_MEM_* flags */
295 __u32 flags;
296 /* Context ID - Currently not in use */
297 __u32 ctx_id;
298 __u32 pad;
299};
300
301struct hl_mem_out {
302 union {
303 /*
304 * Used for HL_MEM_OP_MAP as the virtual address that was
305 * assigned in the device VA space.
306 * A value of 0 means the requested operation failed.
307 */
308 __u64 device_virt_addr;
309
310 /*
311 * Used for HL_MEM_OP_ALLOC. This is the assigned
312 * handle for the allocated memory
313 */
314 __u64 handle;
315 };
316};
317
318union hl_mem_args {
319 struct hl_mem_in in;
320 struct hl_mem_out out;
321};
322
323/*
324 * Various information operations such as:
325 * - H/W IP information
326 * - Current dram usage
327 *
328 * The user calls this IOCTL with an opcode that describes the required
329 * information. The user should supply a pointer to a user-allocated memory
330 * chunk, which will be filled by the driver with the requested information.
331 *
332 * The user supplies the maximum amount of size to copy into the user's memory,
333 * in order to prevent data corruption in case of differences between the
334 * definitions of structures in kernel and userspace, e.g. in case of old
335 * userspace and new kernel driver
336 */
337#define HL_IOCTL_INFO \
338 _IOWR('H', 0x01, struct hl_info_args)
339
340/*
341 * Command Buffer
342 * - Request a Command Buffer
343 * - Destroy a Command Buffer
344 *
345 * The command buffers are memory blocks that reside in DMA-able address
346 * space and are physically contiguous so they can be accessed by the device
347 * directly. They are allocated using the coherent DMA API.
348 *
349 * When creating a new CB, the IOCTL returns a handle of it, and the user-space
350 * process needs to use that handle to mmap the buffer so it can access them.
351 *
352 */
353#define HL_IOCTL_CB \
354 _IOWR('H', 0x02, union hl_cb_args)
355
356/*
357 * Command Submission
358 *
359 * To submit work to the device, the user need to call this IOCTL with a set
360 * of JOBS. That set of JOBS constitutes a CS object.
361 * Each JOB will be enqueued on a specific queue, according to the user's input.
362 * There can be more then one JOB per queue.
363 *
364 * There are two types of queues - external and internal. External queues
365 * are DMA queues which transfer data from/to the Host. All other queues are
366 * internal. The driver will get completion notifications from the device only
367 * on JOBS which are enqueued in the external queues.
368 *
369 * For jobs on external queues, the user needs to create command buffers
370 * through the CB ioctl and give the CB's handle to the CS ioctl. For jobs on
371 * internal queues, the user needs to prepare a "command buffer" with packets
372 * on either the SRAM or DRAM, and give the device address of that buffer to
373 * the CS ioctl.
374 *
375 * This IOCTL is asynchronous in regard to the actual execution of the CS. This
376 * means it returns immediately after ALL the JOBS were enqueued on their
377 * relevant queues. Therefore, the user mustn't assume the CS has been completed
378 * or has even started to execute.
379 *
380 * Upon successful enqueue, the IOCTL returns an opaque handle which the user
381 * can use with the "Wait for CS" IOCTL to check whether the handle's CS
382 * external JOBS have been completed. Note that if the CS has internal JOBS
383 * which can execute AFTER the external JOBS have finished, the driver might
384 * report that the CS has finished executing BEFORE the internal JOBS have
385 * actually finish executing.
386 *
387 * The CS IOCTL will receive three sets of JOBS. One set is for "restore" phase,
388 * a second set is for "execution" phase and a third set is for "store" phase.
389 * The JOBS on the "restore" phase are enqueued only after context-switch
390 * (or if its the first CS for this context). The user can also order the
391 * driver to run the "restore" phase explicitly
392 *
393 */
394#define HL_IOCTL_CS \
395 _IOWR('H', 0x03, union hl_cs_args)
396
397/*
398 * Wait for Command Submission
399 *
400 * The user can call this IOCTL with a handle it received from the CS IOCTL
401 * to wait until the handle's CS has finished executing. The user will wait
402 * inside the kernel until the CS has finished or until the user-requeusted
403 * timeout has expired.
404 *
405 * The return value of the IOCTL is a standard Linux error code. The possible
406 * values are:
407 *
408 * EINTR - Kernel waiting has been interrupted, e.g. due to OS signal
409 * that the user process received
410 * ETIMEDOUT - The CS has caused a timeout on the device
411 * EIO - The CS was aborted (usually because the device was reset)
412 * ENODEV - The device wants to do hard-reset (so user need to close FD)
413 *
414 * The driver also returns a custom define inside the IOCTL which can be:
415 *
416 * HL_WAIT_CS_STATUS_COMPLETED - The CS has been completed successfully (0)
417 * HL_WAIT_CS_STATUS_BUSY - The CS is still executing (0)
418 * HL_WAIT_CS_STATUS_TIMEDOUT - The CS has caused a timeout on the device
419 * (ETIMEDOUT)
420 * HL_WAIT_CS_STATUS_ABORTED - The CS was aborted, usually because the
421 * device was reset (EIO)
422 * HL_WAIT_CS_STATUS_INTERRUPTED - Waiting for the CS was interrupted (EINTR)
423 *
424 */
425
426#define HL_IOCTL_WAIT_CS \
427 _IOWR('H', 0x04, union hl_wait_cs_args)
428
429/*
430 * Memory
431 * - Map host memory to device MMU
432 * - Unmap host memory from device MMU
433 *
434 * This IOCTL allows the user to map host memory to the device MMU
435 *
436 * For host memory, the IOCTL doesn't allocate memory. The user is supposed
437 * to allocate the memory in user-space (malloc/new). The driver pins the
438 * physical pages (up to the allowed limit by the OS), assigns a virtual
439 * address in the device VA space and initializes the device MMU.
440 *
441 * There is an option for the user to specify the requested virtual address.
442 *
443 */
444#define HL_IOCTL_MEMORY \
445 _IOWR('H', 0x05, union hl_mem_args)
446
447#define HL_COMMAND_START 0x01
448#define HL_COMMAND_END 0x06
449
450#endif /* HABANALABS_H_ */
diff --git a/include/uapi/mtd/ubi-user.h b/include/uapi/mtd/ubi-user.h
index aad3b6201fc0..b69e9ba6742b 100644
--- a/include/uapi/mtd/ubi-user.h
+++ b/include/uapi/mtd/ubi-user.h
@@ -171,6 +171,11 @@
171/* Re-name volumes */ 171/* Re-name volumes */
172#define UBI_IOCRNVOL _IOW(UBI_IOC_MAGIC, 3, struct ubi_rnvol_req) 172#define UBI_IOCRNVOL _IOW(UBI_IOC_MAGIC, 3, struct ubi_rnvol_req)
173 173
174/* Read the specified PEB and scrub it if there are bitflips */
175#define UBI_IOCRPEB _IOW(UBI_IOC_MAGIC, 4, __s32)
176/* Force scrubbing on the specified PEB */
177#define UBI_IOCSPEB _IOW(UBI_IOC_MAGIC, 5, __s32)
178
174/* ioctl commands of the UBI control character device */ 179/* ioctl commands of the UBI control character device */
175 180
176#define UBI_CTRL_IOC_MAGIC 'o' 181#define UBI_CTRL_IOC_MAGIC 'o'
diff --git a/include/uapi/rdma/bnxt_re-abi.h b/include/uapi/rdma/bnxt_re-abi.h
index a7a6111e50c7..dc52e3cf574c 100644
--- a/include/uapi/rdma/bnxt_re-abi.h
+++ b/include/uapi/rdma/bnxt_re-abi.h
@@ -44,6 +44,14 @@
44 44
45#define BNXT_RE_ABI_VERSION 1 45#define BNXT_RE_ABI_VERSION 1
46 46
47#define BNXT_RE_CHIP_ID0_CHIP_NUM_SFT 0x00
48#define BNXT_RE_CHIP_ID0_CHIP_REV_SFT 0x10
49#define BNXT_RE_CHIP_ID0_CHIP_MET_SFT 0x18
50
51enum {
52 BNXT_RE_UCNTX_CMASK_HAVE_CCTX = 0x1ULL
53};
54
47struct bnxt_re_uctx_resp { 55struct bnxt_re_uctx_resp {
48 __u32 dev_id; 56 __u32 dev_id;
49 __u32 max_qp; 57 __u32 max_qp;
@@ -51,6 +59,9 @@ struct bnxt_re_uctx_resp {
51 __u32 cqe_sz; 59 __u32 cqe_sz;
52 __u32 max_cqd; 60 __u32 max_cqd;
53 __u32 rsvd; 61 __u32 rsvd;
62 __aligned_u64 comp_mask;
63 __u32 chip_id0;
64 __u32 chip_id1;
54}; 65};
55 66
56/* 67/*
diff --git a/include/uapi/rdma/ib_user_verbs.h b/include/uapi/rdma/ib_user_verbs.h
index 480d9a60b68e..0474c7400268 100644
--- a/include/uapi/rdma/ib_user_verbs.h
+++ b/include/uapi/rdma/ib_user_verbs.h
@@ -270,6 +270,8 @@ struct ib_uverbs_ex_query_device_resp {
270 struct ib_uverbs_tm_caps tm_caps; 270 struct ib_uverbs_tm_caps tm_caps;
271 struct ib_uverbs_cq_moderation_caps cq_moderation_caps; 271 struct ib_uverbs_cq_moderation_caps cq_moderation_caps;
272 __aligned_u64 max_dm_size; 272 __aligned_u64 max_dm_size;
273 __u32 xrc_odp_caps;
274 __u32 reserved;
273}; 275};
274 276
275struct ib_uverbs_query_port { 277struct ib_uverbs_query_port {
diff --git a/include/uapi/rdma/mlx5_user_ioctl_cmds.h b/include/uapi/rdma/mlx5_user_ioctl_cmds.h
index b8d121d457f1..8149d224030b 100644
--- a/include/uapi/rdma/mlx5_user_ioctl_cmds.h
+++ b/include/uapi/rdma/mlx5_user_ioctl_cmds.h
@@ -84,6 +84,14 @@ enum mlx5_ib_devx_obj_query_attrs {
84 MLX5_IB_ATTR_DEVX_OBJ_QUERY_CMD_OUT, 84 MLX5_IB_ATTR_DEVX_OBJ_QUERY_CMD_OUT,
85}; 85};
86 86
87enum mlx5_ib_devx_obj_query_async_attrs {
88 MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_HANDLE = (1U << UVERBS_ID_NS_SHIFT),
89 MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_CMD_IN,
90 MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_FD,
91 MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_WR_ID,
92 MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_OUT_LEN,
93};
94
87enum mlx5_ib_devx_query_eqn_attrs { 95enum mlx5_ib_devx_query_eqn_attrs {
88 MLX5_IB_ATTR_DEVX_QUERY_EQN_USER_VEC = (1U << UVERBS_ID_NS_SHIFT), 96 MLX5_IB_ATTR_DEVX_QUERY_EQN_USER_VEC = (1U << UVERBS_ID_NS_SHIFT),
89 MLX5_IB_ATTR_DEVX_QUERY_EQN_DEV_EQN, 97 MLX5_IB_ATTR_DEVX_QUERY_EQN_DEV_EQN,
@@ -94,6 +102,7 @@ enum mlx5_ib_devx_obj_methods {
94 MLX5_IB_METHOD_DEVX_OBJ_DESTROY, 102 MLX5_IB_METHOD_DEVX_OBJ_DESTROY,
95 MLX5_IB_METHOD_DEVX_OBJ_MODIFY, 103 MLX5_IB_METHOD_DEVX_OBJ_MODIFY,
96 MLX5_IB_METHOD_DEVX_OBJ_QUERY, 104 MLX5_IB_METHOD_DEVX_OBJ_QUERY,
105 MLX5_IB_METHOD_DEVX_OBJ_ASYNC_QUERY,
97}; 106};
98 107
99enum mlx5_ib_devx_umem_reg_attrs { 108enum mlx5_ib_devx_umem_reg_attrs {
@@ -113,11 +122,20 @@ enum mlx5_ib_devx_umem_methods {
113 MLX5_IB_METHOD_DEVX_UMEM_DEREG, 122 MLX5_IB_METHOD_DEVX_UMEM_DEREG,
114}; 123};
115 124
125enum mlx5_ib_devx_async_cmd_fd_alloc_attrs {
126 MLX5_IB_ATTR_DEVX_ASYNC_CMD_FD_ALLOC_HANDLE = (1U << UVERBS_ID_NS_SHIFT),
127};
128
129enum mlx5_ib_devx_async_cmd_fd_methods {
130 MLX5_IB_METHOD_DEVX_ASYNC_CMD_FD_ALLOC = (1U << UVERBS_ID_NS_SHIFT),
131};
132
116enum mlx5_ib_objects { 133enum mlx5_ib_objects {
117 MLX5_IB_OBJECT_DEVX = (1U << UVERBS_ID_NS_SHIFT), 134 MLX5_IB_OBJECT_DEVX = (1U << UVERBS_ID_NS_SHIFT),
118 MLX5_IB_OBJECT_DEVX_OBJ, 135 MLX5_IB_OBJECT_DEVX_OBJ,
119 MLX5_IB_OBJECT_DEVX_UMEM, 136 MLX5_IB_OBJECT_DEVX_UMEM,
120 MLX5_IB_OBJECT_FLOW_MATCHER, 137 MLX5_IB_OBJECT_FLOW_MATCHER,
138 MLX5_IB_OBJECT_DEVX_ASYNC_CMD_FD,
121}; 139};
122 140
123enum mlx5_ib_flow_matcher_create_attrs { 141enum mlx5_ib_flow_matcher_create_attrs {
diff --git a/include/uapi/rdma/mlx5_user_ioctl_verbs.h b/include/uapi/rdma/mlx5_user_ioctl_verbs.h
index 4ef62c0e8452..4a701033b93f 100644
--- a/include/uapi/rdma/mlx5_user_ioctl_verbs.h
+++ b/include/uapi/rdma/mlx5_user_ioctl_verbs.h
@@ -51,5 +51,10 @@ enum mlx5_ib_uapi_flow_action_packet_reformat_type {
51 MLX5_IB_UAPI_FLOW_ACTION_PACKET_REFORMAT_TYPE_L2_TO_L3_TUNNEL = 0x3, 51 MLX5_IB_UAPI_FLOW_ACTION_PACKET_REFORMAT_TYPE_L2_TO_L3_TUNNEL = 0x3,
52}; 52};
53 53
54struct mlx5_ib_uapi_devx_async_cmd_hdr {
55 __aligned_u64 wr_id;
56 __u8 out_data[];
57};
58
54#endif 59#endif
55 60
diff --git a/include/uapi/rdma/rdma_netlink.h b/include/uapi/rdma/rdma_netlink.h
index 2e18b77a817f..5cc592728071 100644
--- a/include/uapi/rdma/rdma_netlink.h
+++ b/include/uapi/rdma/rdma_netlink.h
@@ -5,8 +5,7 @@
5#include <linux/types.h> 5#include <linux/types.h>
6 6
7enum { 7enum {
8 RDMA_NL_RDMA_CM = 1, 8 RDMA_NL_IWCM = 2,
9 RDMA_NL_IWCM,
10 RDMA_NL_RSVD, 9 RDMA_NL_RSVD,
11 RDMA_NL_LS, /* RDMA Local Services */ 10 RDMA_NL_LS, /* RDMA Local Services */
12 RDMA_NL_NLDEV, /* RDMA device interface */ 11 RDMA_NL_NLDEV, /* RDMA device interface */
@@ -14,8 +13,7 @@ enum {
14}; 13};
15 14
16enum { 15enum {
17 RDMA_NL_GROUP_CM = 1, 16 RDMA_NL_GROUP_IWPM = 2,
18 RDMA_NL_GROUP_IWPM,
19 RDMA_NL_GROUP_LS, 17 RDMA_NL_GROUP_LS,
20 RDMA_NL_NUM_GROUPS 18 RDMA_NL_NUM_GROUPS
21}; 19};
@@ -24,15 +22,17 @@ enum {
24#define RDMA_NL_GET_OP(type) (type & ((1 << 10) - 1)) 22#define RDMA_NL_GET_OP(type) (type & ((1 << 10) - 1))
25#define RDMA_NL_GET_TYPE(client, op) ((client << 10) + op) 23#define RDMA_NL_GET_TYPE(client, op) ((client << 10) + op)
26 24
27enum { 25/* The minimum version that the iwpm kernel supports */
28 RDMA_NL_RDMA_CM_ID_STATS = 0, 26#define IWPM_UABI_VERSION_MIN 3
29 RDMA_NL_RDMA_CM_NUM_OPS 27
30}; 28/* The latest version that the iwpm kernel supports */
29#define IWPM_UABI_VERSION 4
31 30
31/* iwarp port mapper message flags */
32enum { 32enum {
33 RDMA_NL_RDMA_CM_ATTR_SRC_ADDR = 1, 33
34 RDMA_NL_RDMA_CM_ATTR_DST_ADDR, 34 /* Do not map the port for this IWPM request */
35 RDMA_NL_RDMA_CM_NUM_ATTR, 35 IWPM_FLAGS_NO_PORT_MAP = (1 << 0),
36}; 36};
37 37
38/* iwarp port mapper op-codes */ 38/* iwarp port mapper op-codes */
@@ -45,6 +45,7 @@ enum {
45 RDMA_NL_IWPM_HANDLE_ERR, 45 RDMA_NL_IWPM_HANDLE_ERR,
46 RDMA_NL_IWPM_MAPINFO, 46 RDMA_NL_IWPM_MAPINFO,
47 RDMA_NL_IWPM_MAPINFO_NUM, 47 RDMA_NL_IWPM_MAPINFO_NUM,
48 RDMA_NL_IWPM_HELLO,
48 RDMA_NL_IWPM_NUM_OPS 49 RDMA_NL_IWPM_NUM_OPS
49}; 50};
50 51
@@ -83,20 +84,38 @@ enum {
83 IWPM_NLA_MANAGE_MAPPING_UNSPEC = 0, 84 IWPM_NLA_MANAGE_MAPPING_UNSPEC = 0,
84 IWPM_NLA_MANAGE_MAPPING_SEQ, 85 IWPM_NLA_MANAGE_MAPPING_SEQ,
85 IWPM_NLA_MANAGE_ADDR, 86 IWPM_NLA_MANAGE_ADDR,
86 IWPM_NLA_MANAGE_MAPPED_LOC_ADDR, 87 IWPM_NLA_MANAGE_FLAGS,
88 IWPM_NLA_MANAGE_MAPPING_MAX
89};
90
91enum {
92 IWPM_NLA_RMANAGE_MAPPING_UNSPEC = 0,
93 IWPM_NLA_RMANAGE_MAPPING_SEQ,
94 IWPM_NLA_RMANAGE_ADDR,
95 IWPM_NLA_RMANAGE_MAPPED_LOC_ADDR,
96 /* The following maintains bisectability of rdma-core */
97 IWPM_NLA_MANAGE_MAPPED_LOC_ADDR = IWPM_NLA_RMANAGE_MAPPED_LOC_ADDR,
87 IWPM_NLA_RMANAGE_MAPPING_ERR, 98 IWPM_NLA_RMANAGE_MAPPING_ERR,
88 IWPM_NLA_RMANAGE_MAPPING_MAX 99 IWPM_NLA_RMANAGE_MAPPING_MAX
89}; 100};
90 101
91#define IWPM_NLA_MANAGE_MAPPING_MAX 3
92#define IWPM_NLA_QUERY_MAPPING_MAX 4
93#define IWPM_NLA_MAPINFO_SEND_MAX 3 102#define IWPM_NLA_MAPINFO_SEND_MAX 3
103#define IWPM_NLA_REMOVE_MAPPING_MAX 3
94 104
95enum { 105enum {
96 IWPM_NLA_QUERY_MAPPING_UNSPEC = 0, 106 IWPM_NLA_QUERY_MAPPING_UNSPEC = 0,
97 IWPM_NLA_QUERY_MAPPING_SEQ, 107 IWPM_NLA_QUERY_MAPPING_SEQ,
98 IWPM_NLA_QUERY_LOCAL_ADDR, 108 IWPM_NLA_QUERY_LOCAL_ADDR,
99 IWPM_NLA_QUERY_REMOTE_ADDR, 109 IWPM_NLA_QUERY_REMOTE_ADDR,
110 IWPM_NLA_QUERY_FLAGS,
111 IWPM_NLA_QUERY_MAPPING_MAX,
112};
113
114enum {
115 IWPM_NLA_RQUERY_MAPPING_UNSPEC = 0,
116 IWPM_NLA_RQUERY_MAPPING_SEQ,
117 IWPM_NLA_RQUERY_LOCAL_ADDR,
118 IWPM_NLA_RQUERY_REMOTE_ADDR,
100 IWPM_NLA_RQUERY_MAPPED_LOC_ADDR, 119 IWPM_NLA_RQUERY_MAPPED_LOC_ADDR,
101 IWPM_NLA_RQUERY_MAPPED_REM_ADDR, 120 IWPM_NLA_RQUERY_MAPPED_REM_ADDR,
102 IWPM_NLA_RQUERY_MAPPING_ERR, 121 IWPM_NLA_RQUERY_MAPPING_ERR,
@@ -114,6 +133,7 @@ enum {
114 IWPM_NLA_MAPINFO_UNSPEC = 0, 133 IWPM_NLA_MAPINFO_UNSPEC = 0,
115 IWPM_NLA_MAPINFO_LOCAL_ADDR, 134 IWPM_NLA_MAPINFO_LOCAL_ADDR,
116 IWPM_NLA_MAPINFO_MAPPED_ADDR, 135 IWPM_NLA_MAPINFO_MAPPED_ADDR,
136 IWPM_NLA_MAPINFO_FLAGS,
117 IWPM_NLA_MAPINFO_MAX 137 IWPM_NLA_MAPINFO_MAX
118}; 138};
119 139
@@ -132,6 +152,12 @@ enum {
132 IWPM_NLA_ERR_MAX 152 IWPM_NLA_ERR_MAX
133}; 153};
134 154
155enum {
156 IWPM_NLA_HELLO_UNSPEC = 0,
157 IWPM_NLA_HELLO_ABI_VERSION,
158 IWPM_NLA_HELLO_MAX
159};
160
135/* 161/*
136 * Local service operations: 162 * Local service operations:
137 * RESOLVE - The client requests the local service to resolve a path. 163 * RESOLVE - The client requests the local service to resolve a path.
@@ -229,9 +255,11 @@ enum rdma_nldev_command {
229 RDMA_NLDEV_CMD_GET, /* can dump */ 255 RDMA_NLDEV_CMD_GET, /* can dump */
230 RDMA_NLDEV_CMD_SET, 256 RDMA_NLDEV_CMD_SET,
231 257
232 /* 3 - 4 are free to use */ 258 RDMA_NLDEV_CMD_NEWLINK,
233 259
234 RDMA_NLDEV_CMD_PORT_GET = 5, /* can dump */ 260 RDMA_NLDEV_CMD_DELLINK,
261
262 RDMA_NLDEV_CMD_PORT_GET, /* can dump */
235 263
236 /* 6 - 8 are free to use */ 264 /* 6 - 8 are free to use */
237 265
@@ -431,6 +459,20 @@ enum rdma_nldev_attr {
431 RDMA_NLDEV_ATTR_DRIVER_U64, /* u64 */ 459 RDMA_NLDEV_ATTR_DRIVER_U64, /* u64 */
432 460
433 /* 461 /*
462 * Indexes to get/set secific entry,
463 * for QP use RDMA_NLDEV_ATTR_RES_LQPN
464 */
465 RDMA_NLDEV_ATTR_RES_PDN, /* u32 */
466 RDMA_NLDEV_ATTR_RES_CQN, /* u32 */
467 RDMA_NLDEV_ATTR_RES_MRN, /* u32 */
468 RDMA_NLDEV_ATTR_RES_CM_IDN, /* u32 */
469 RDMA_NLDEV_ATTR_RES_CTXN, /* u32 */
470 /*
471 * Identifies the rdma driver. eg: "rxe" or "siw"
472 */
473 RDMA_NLDEV_ATTR_LINK_TYPE, /* string */
474
475 /*
434 * Always the end 476 * Always the end
435 */ 477 */
436 RDMA_NLDEV_ATTR_MAX 478 RDMA_NLDEV_ATTR_MAX
diff --git a/include/uapi/rdma/rdma_user_cm.h b/include/uapi/rdma/rdma_user_cm.h
index 0d1e78ebad05..e42940a215a3 100644
--- a/include/uapi/rdma/rdma_user_cm.h
+++ b/include/uapi/rdma/rdma_user_cm.h
@@ -300,6 +300,10 @@ enum {
300 RDMA_OPTION_ID_TOS = 0, 300 RDMA_OPTION_ID_TOS = 0,
301 RDMA_OPTION_ID_REUSEADDR = 1, 301 RDMA_OPTION_ID_REUSEADDR = 1,
302 RDMA_OPTION_ID_AFONLY = 2, 302 RDMA_OPTION_ID_AFONLY = 2,
303 RDMA_OPTION_ID_ACK_TIMEOUT = 3
304};
305
306enum {
303 RDMA_OPTION_IB_PATH = 1 307 RDMA_OPTION_IB_PATH = 1
304}; 308};
305 309
diff --git a/include/uapi/rdma/rdma_user_rxe.h b/include/uapi/rdma/rdma_user_rxe.h
index 44ef6a3b7afc..aae2e696bb38 100644
--- a/include/uapi/rdma/rdma_user_rxe.h
+++ b/include/uapi/rdma/rdma_user_rxe.h
@@ -58,8 +58,7 @@ struct rxe_global_route {
58struct rxe_av { 58struct rxe_av {
59 __u8 port_num; 59 __u8 port_num;
60 __u8 network_type; 60 __u8 network_type;
61 __u16 reserved1; 61 __u8 dmac[6];
62 __u32 reserved2;
63 struct rxe_global_route grh; 62 struct rxe_global_route grh;
64 union { 63 union {
65 struct sockaddr_in _sockaddr_in; 64 struct sockaddr_in _sockaddr_in;