History

Merge drm/drm-next into drm-misc-next

Backmerging 5.2-rc1 to -misc-next for robher

Sean Paul committed 7 years ago

Commit 374ed542 parents 270afb3 a18833910984 files · +473676 −302814Browse files

Showing the changes to include/uapi (67 of 10984 files). Show all

Unified · Split

67 files
  1. include/uapi/asm-generic/sockios.h +2 −2
  2. include/uapi/asm-generic/unistd.h +13 −1
  3. include/uapi/linux/aspeed-p2a-ctrl.h +62 −0
  4. include/uapi/linux/audit.h +14 −0
  5. include/uapi/linux/batadv_packet.h +0 −12
  6. include/uapi/linux/batman_adv.h +7 −18
  7. include/uapi/linux/bpf.h +323 −41
  8. include/uapi/linux/btf.h +28 −4
  9. include/uapi/linux/btrfs_tree.h +2 −0
  10. include/uapi/linux/elf-em.h +6 −0
  11. include/uapi/linux/ethtool.h +11 −0
  12. include/uapi/linux/fcntl.h +2 −0
  13. include/uapi/linux/fou.h +6 −0
  14. include/uapi/linux/fs.h +3 −0
  15. include/uapi/linux/fuse.h +20 −2
  16. include/uapi/linux/icmpv6.h +4 −0
  17. include/uapi/linux/if_ether.h +1 −0
  18. include/uapi/linux/if_tun.h +1 −0
  19. include/uapi/linux/if_vlan.h +5 −4
  20. include/uapi/linux/input-event-codes.h +5 −2
  21. include/uapi/linux/io_uring.h +5 −0
  22. include/uapi/linux/ip_vs.h +11 −0
  23. include/uapi/linux/kvm.h +13 −2
  24. include/uapi/linux/lirc.h +2 −0
  25. include/uapi/linux/media-bus-format.h +2 −1
  26. include/uapi/linux/media.h +15 −10
  27. include/uapi/linux/mei.h +3 −64
  28. include/uapi/linux/mount.h +62 −0
  29. include/uapi/linux/netfilter/nf_tables.h +9 −3
  30. include/uapi/linux/nfs_mount.h +0 −9
  31. include/uapi/linux/nfsd/cld.h +1 −0
  32. include/uapi/linux/nl80211.h +84 −2
  33. include/uapi/linux/openvswitch.h +46 −0
  34. include/uapi/linux/pci_regs.h +71 −67
  35. include/uapi/linux/pkt_sched.h +13 −0
  36. include/uapi/linux/psci.h +7 −0
  37. include/uapi/linux/psp-sev.h +14 −4
  38. include/uapi/linux/sched.h +1 −0
  39. include/uapi/linux/sed-opal.h +1 −10
  40. include/uapi/linux/serial_core.h +6 −0
  41. include/uapi/linux/sockios.h +21 −0
  42. include/uapi/linux/spi/spidev.h +5 −1
  43. include/uapi/linux/switchtec_ioctl.h +12 −1
  44. include/uapi/linux/tcp.h +27 −0
  45. include/uapi/linux/tipc.h +1 −0
  46. include/uapi/linux/tipc_netlink.h +2 −0
  47. include/uapi/linux/tls.h +15 −0
  48. include/uapi/linux/v4l2-controls.h +8 −0
  49. include/uapi/linux/vfio.h +4 −0
  50. include/uapi/linux/vfio_ccw.h +12 −0
  51. include/uapi/linux/videodev2.h +17 −0
  52. include/uapi/misc/habanalabs.h +149 −12
  53. include/uapi/rdma/efa-abi.h +101 −0
  54. include/uapi/rdma/mlx5-abi.h +3 −0
  55. include/uapi/rdma/mlx5_user_ioctl_cmds.h +2 −0
  56. include/uapi/rdma/mlx5_user_ioctl_verbs.h +7 −0
  57. include/uapi/rdma/rdma_netlink.h +19 −12
  58. include/uapi/rdma/rdma_user_ioctl_cmds.h +1 −0
  59. include/uapi/scsi/fc/fc_els.h +33 −0
  60. include/uapi/sound/sof/abi.h +62 −0
  61. include/uapi/sound/sof/eq.h +172 −0
  62. include/uapi/sound/sof/fw.h +78 −0
  63. include/uapi/sound/sof/header.h +27 −0
  64. include/uapi/sound/sof/manifest.h +188 −0
  65. include/uapi/sound/sof/tokens.h +107 −0
  66. include/uapi/sound/sof/tone.h +21 −0
  67. include/uapi/sound/sof/trace.h +66 −0
include/uapi/asm-generic/sockios.h+2−2
@@ -8,7 +8,7 @@ · 7 unmodified lines
8#define FIOGETOWN 0x89038#define FIOGETOWN 0x8903
9#define SIOCGPGRP 0x89049#define SIOCGPGRP 0x8904
10#define SIOCATMARK 0x890510#define SIOCATMARK 0x8905
11#define SIOCGSTAMP 0x8906 /* Get stamp (timeval) */11#define SIOCGSTAMP_OLD 0x8906 /* Get stamp (timeval) */
12#define SIOCGSTAMPNS 0x8907 /* Get stamp (timespec) */12#define SIOCGSTAMPNS_OLD 0x8907 /* Get stamp (timespec) */
13 13
14#endif /* __ASM_GENERIC_SOCKIOS_H */14#endif /* __ASM_GENERIC_SOCKIOS_H */
include/uapi/asm-generic/unistd.h+13−1
@@ -832,9 +832,21 @@ __SYSCALL(__NR_io_uring_setup, sys_io_uring_setup) · 831 unmodified lines
832__SYSCALL(__NR_io_uring_enter, sys_io_uring_enter)832__SYSCALL(__NR_io_uring_enter, sys_io_uring_enter)
833#define __NR_io_uring_register 427833#define __NR_io_uring_register 427
834__SYSCALL(__NR_io_uring_register, sys_io_uring_register)834__SYSCALL(__NR_io_uring_register, sys_io_uring_register)
835#define __NR_open_tree 428
836__SYSCALL(__NR_open_tree, sys_open_tree)
837#define __NR_move_mount 429
838__SYSCALL(__NR_move_mount, sys_move_mount)
839#define __NR_fsopen 430
840__SYSCALL(__NR_fsopen, sys_fsopen)
841#define __NR_fsconfig 431
842__SYSCALL(__NR_fsconfig, sys_fsconfig)
843#define __NR_fsmount 432
844__SYSCALL(__NR_fsmount, sys_fsmount)
845#define __NR_fspick 433
846__SYSCALL(__NR_fspick, sys_fspick)
835 847
836#undef __NR_syscalls848#undef __NR_syscalls
837#define __NR_syscalls 428849#define __NR_syscalls 434
838 850
839/*851/*
840 * 32 bit systems traditionally used different852 * 32 bit systems traditionally used different
include/uapi/linux/aspeed-p2a-ctrl.h+62−0
@@ -0,0 +1,62 @@
1/* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
2/*
3 * Copyright 2019 Google Inc
4 *
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License
7 * as published by the Free Software Foundation; either version
8 * 2 of the License, or (at your option) any later version.
9 *
10 * Provides a simple driver to control the ASPEED P2A interface which allows
11 * the host to read and write to various regions of the BMC's memory.
12 */
13
14#ifndef _UAPI_LINUX_ASPEED_P2A_CTRL_H
15#define _UAPI_LINUX_ASPEED_P2A_CTRL_H
16
17#include <linux/ioctl.h>
18#include <linux/types.h>
19
20#define ASPEED_P2A_CTRL_READ_ONLY 0
21#define ASPEED_P2A_CTRL_READWRITE 1
22
23/*
24 * This driver provides a mechanism for enabling or disabling the read-write
25 * property of specific windows into the ASPEED BMC's memory.
26 *
27 * A user can map a region of the BMC's memory as read-only or read-write, with
28 * the caveat that once any region is mapped, all regions are unlocked for
29 * reading.
30 */
31
32/*
33 * Unlock a region of BMC physical memory for access from the host.
34 *
35 * Also used to read back the optional memory-region configuration for the
36 * driver.
37 */
38struct aspeed_p2a_ctrl_mapping {
39 __u64 addr;
40 __u32 length;
41 __u32 flags;
42};
43
44#define __ASPEED_P2A_CTRL_IOCTL_MAGIC 0xb3
45
46/*
47 * This IOCTL is meant to configure a region or regions of memory given a
48 * starting address and length to be readable by the host, or
49 * readable-writeable.
50 */
51#define ASPEED_P2A_CTRL_IOCTL_SET_WINDOW _IOW(__ASPEED_P2A_CTRL_IOCTL_MAGIC, \
52 0x00, struct aspeed_p2a_ctrl_mapping)
53
54/*
55 * This IOCTL is meant to read back to the user the base address and length of
56 * the memory-region specified to the driver for use with mmap.
57 */
58#define ASPEED_P2A_CTRL_IOCTL_GET_MEMORY_CONFIG \
59 _IOWR(__ASPEED_P2A_CTRL_IOCTL_MAGIC, \
60 0x01, struct aspeed_p2a_ctrl_mapping)
61
62#endif /* _UAPI_LINUX_ASPEED_P2A_CTRL_H */
include/uapi/linux/audit.h+14−0
@@ -114,6 +114,8 @@ · 113 unmodified lines
114#define AUDIT_REPLACE 1329 /* Replace auditd if this packet unanswerd */114#define AUDIT_REPLACE 1329 /* Replace auditd if this packet unanswerd */
115#define AUDIT_KERN_MODULE 1330 /* Kernel Module events */115#define AUDIT_KERN_MODULE 1330 /* Kernel Module events */
116#define AUDIT_FANOTIFY 1331 /* Fanotify access decision */116#define AUDIT_FANOTIFY 1331 /* Fanotify access decision */
117#define AUDIT_TIME_INJOFFSET 1332 /* Timekeeping offset injected */
118#define AUDIT_TIME_ADJNTPVAL 1333 /* NTP value adjustment */
117 119
118#define AUDIT_AVC 1400 /* SE Linux avc denial or grant */120#define AUDIT_AVC 1400 /* SE Linux avc denial or grant */
119#define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */121#define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */
@@ -375,11 +377,19 @@ enum { · 255 unmodified lines
375 377
376#define AUDIT_ARCH_AARCH64 (EM_AARCH64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)378#define AUDIT_ARCH_AARCH64 (EM_AARCH64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
377#define AUDIT_ARCH_ALPHA (EM_ALPHA|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)379#define AUDIT_ARCH_ALPHA (EM_ALPHA|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
380#define AUDIT_ARCH_ARCOMPACT (EM_ARCOMPACT|__AUDIT_ARCH_LE)
381#define AUDIT_ARCH_ARCOMPACTBE (EM_ARCOMPACT)
382#define AUDIT_ARCH_ARCV2 (EM_ARCV2|__AUDIT_ARCH_LE)
383#define AUDIT_ARCH_ARCV2BE (EM_ARCV2)
378#define AUDIT_ARCH_ARM (EM_ARM|__AUDIT_ARCH_LE)384#define AUDIT_ARCH_ARM (EM_ARM|__AUDIT_ARCH_LE)
379#define AUDIT_ARCH_ARMEB (EM_ARM)385#define AUDIT_ARCH_ARMEB (EM_ARM)
386#define AUDIT_ARCH_C6X (EM_TI_C6000|__AUDIT_ARCH_LE)
387#define AUDIT_ARCH_C6XBE (EM_TI_C6000)
380#define AUDIT_ARCH_CRIS (EM_CRIS|__AUDIT_ARCH_LE)388#define AUDIT_ARCH_CRIS (EM_CRIS|__AUDIT_ARCH_LE)
381#define AUDIT_ARCH_CSKY (EM_CSKY|__AUDIT_ARCH_LE)389#define AUDIT_ARCH_CSKY (EM_CSKY|__AUDIT_ARCH_LE)
382#define AUDIT_ARCH_FRV (EM_FRV)390#define AUDIT_ARCH_FRV (EM_FRV)
391#define AUDIT_ARCH_H8300 (EM_H8_300)
392#define AUDIT_ARCH_HEXAGON (EM_HEXAGON)
383#define AUDIT_ARCH_I386 (EM_386|__AUDIT_ARCH_LE)393#define AUDIT_ARCH_I386 (EM_386|__AUDIT_ARCH_LE)
384#define AUDIT_ARCH_IA64 (EM_IA_64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)394#define AUDIT_ARCH_IA64 (EM_IA_64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
385#define AUDIT_ARCH_M32R (EM_M32R)395#define AUDIT_ARCH_M32R (EM_M32R)
@@ -393,6 +403,9 @@ enum { · 7 unmodified lines
393#define AUDIT_ARCH_MIPSEL64 (EM_MIPS|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)403#define AUDIT_ARCH_MIPSEL64 (EM_MIPS|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
394#define AUDIT_ARCH_MIPSEL64N32 (EM_MIPS|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE|\404#define AUDIT_ARCH_MIPSEL64N32 (EM_MIPS|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE|\
395 __AUDIT_ARCH_CONVENTION_MIPS64_N32)405 __AUDIT_ARCH_CONVENTION_MIPS64_N32)
406#define AUDIT_ARCH_NDS32 (EM_NDS32|__AUDIT_ARCH_LE)
407#define AUDIT_ARCH_NDS32BE (EM_NDS32)
408#define AUDIT_ARCH_NIOS2 (EM_ALTERA_NIOS2|__AUDIT_ARCH_LE)
396#define AUDIT_ARCH_OPENRISC (EM_OPENRISC)409#define AUDIT_ARCH_OPENRISC (EM_OPENRISC)
397#define AUDIT_ARCH_PARISC (EM_PARISC)410#define AUDIT_ARCH_PARISC (EM_PARISC)
398#define AUDIT_ARCH_PARISC64 (EM_PARISC|__AUDIT_ARCH_64BIT)411#define AUDIT_ARCH_PARISC64 (EM_PARISC|__AUDIT_ARCH_64BIT)
@@ -413,6 +426,7 @@ enum { · 14 unmodified lines
413#define AUDIT_ARCH_TILEGX (EM_TILEGX|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)426#define AUDIT_ARCH_TILEGX (EM_TILEGX|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
414#define AUDIT_ARCH_TILEGX32 (EM_TILEGX|__AUDIT_ARCH_LE)427#define AUDIT_ARCH_TILEGX32 (EM_TILEGX|__AUDIT_ARCH_LE)
415#define AUDIT_ARCH_TILEPRO (EM_TILEPRO|__AUDIT_ARCH_LE)428#define AUDIT_ARCH_TILEPRO (EM_TILEPRO|__AUDIT_ARCH_LE)
429#define AUDIT_ARCH_UNICORE (EM_UNICORE|__AUDIT_ARCH_LE)
416#define AUDIT_ARCH_X86_64 (EM_X86_64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)430#define AUDIT_ARCH_X86_64 (EM_X86_64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
417#define AUDIT_ARCH_XTENSA (EM_XTENSA)431#define AUDIT_ARCH_XTENSA (EM_XTENSA)
418 432
include/uapi/linux/batadv_packet.h+0−12
@@ -2,18 +2,6 @@ · 1 unmodified line
2/* Copyright (C) 2007-2019 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 Wunderlich4 * Marek Lindner, Simon Wunderlich
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of version 2 of the GNU General Public
8 * License as published by the Free Software Foundation.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, see <http://www.gnu.org/licenses/>.
17 */5 */
18 6
19#ifndef _UAPI_LINUX_BATADV_PACKET_H_7#ifndef _UAPI_LINUX_BATADV_PACKET_H_
include/uapi/linux/batman_adv.h+7−18
@@ -2,24 +2,6 @@ · 1 unmodified line
2/* Copyright (C) 2016-2019 B.A.T.M.A.N. contributors:2/* Copyright (C) 2016-2019 B.A.T.M.A.N. contributors:
3 *3 *
4 * Matthias Schiffer4 * Matthias Schiffer
5 *
6 * Permission is hereby granted, free of charge, to any person obtaining a
7 * copy of this software and associated documentation files (the "Software"),
8 * to deal in the Software without restriction, including without limitation
9 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
10 * and/or sell copies of the Software, and to permit persons to whom the
11 * Software is furnished to do so, subject to the following conditions:
12 *
13 * The above copyright notice and this permission notice shall be included in
14 * all copies or substantial portions of the Software.
15 *
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22 * DEALINGS IN THE SOFTWARE.
23 */5 */
24 6
25#ifndef _UAPI_LINUX_BATMAN_ADV_H_7#ifndef _UAPI_LINUX_BATMAN_ADV_H_
@@ -491,6 +473,13 @@ enum batadv_nl_attrs { · 465 unmodified lines
491 */473 */
492 BATADV_ATTR_THROUGHPUT_OVERRIDE,474 BATADV_ATTR_THROUGHPUT_OVERRIDE,
493 475
476 /**
477 * @BATADV_ATTR_MULTICAST_FANOUT: defines the maximum number of packet
478 * copies that may be generated for a multicast-to-unicast conversion.
479 * Once this limit is exceeded distribution will fall back to broadcast.
480 */
481 BATADV_ATTR_MULTICAST_FANOUT,
482
494 /* add attributes above here, update the policy in netlink.c */483 /* add attributes above here, update the policy in netlink.c */
495 484
496 /**485 /**
include/uapi/linux/bpf.h+323−41
@@ -105,6 +105,7 @@ enum bpf_cmd { · 104 unmodified lines
105 BPF_BTF_GET_FD_BY_ID,105 BPF_BTF_GET_FD_BY_ID,
106 BPF_TASK_FD_QUERY,106 BPF_TASK_FD_QUERY,
107 BPF_MAP_LOOKUP_AND_DELETE_ELEM,107 BPF_MAP_LOOKUP_AND_DELETE_ELEM,
108 BPF_MAP_FREEZE,
108};109};
109 110
110enum bpf_map_type {111enum bpf_map_type {
@@ -132,6 +133,7 @@ enum bpf_map_type { · 21 unmodified lines
132 BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE,133 BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE,
133 BPF_MAP_TYPE_QUEUE,134 BPF_MAP_TYPE_QUEUE,
134 BPF_MAP_TYPE_STACK,135 BPF_MAP_TYPE_STACK,
136 BPF_MAP_TYPE_SK_STORAGE,
135};137};
136 138
137/* Note that tracing related programs such as139/* Note that tracing related programs such as
@@ -166,6 +168,8 @@ enum bpf_prog_type { · 28 unmodified lines
166 BPF_PROG_TYPE_LIRC_MODE2,168 BPF_PROG_TYPE_LIRC_MODE2,
167 BPF_PROG_TYPE_SK_REUSEPORT,169 BPF_PROG_TYPE_SK_REUSEPORT,
168 BPF_PROG_TYPE_FLOW_DISSECTOR,170 BPF_PROG_TYPE_FLOW_DISSECTOR,
171 BPF_PROG_TYPE_CGROUP_SYSCTL,
172 BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE,
169};173};
170 174
171enum bpf_attach_type {175enum bpf_attach_type {
@@ -187,6 +191,7 @@ enum bpf_attach_type { · 15 unmodified lines
187 BPF_CGROUP_UDP6_SENDMSG,191 BPF_CGROUP_UDP6_SENDMSG,
188 BPF_LIRC_MODE2,192 BPF_LIRC_MODE2,
189 BPF_FLOW_DISSECTOR,193 BPF_FLOW_DISSECTOR,
194 BPF_CGROUP_SYSCTL,
190 __MAX_BPF_ATTACH_TYPE195 __MAX_BPF_ATTACH_TYPE
191};196};
192 197
@@ -255,8 +260,19 @@ enum bpf_attach_type { · 62 unmodified lines
255 */260 */
256#define BPF_F_ANY_ALIGNMENT (1U << 1)261#define BPF_F_ANY_ALIGNMENT (1U << 1)
257 262
258/* when bpf_ldimm64->src_reg == BPF_PSEUDO_MAP_FD, bpf_ldimm64->imm == fd */263/* When BPF ldimm64's insn[0].src_reg != 0 then this can have
264 * two extensions:
265 *
266 * insn[0].src_reg: BPF_PSEUDO_MAP_FD BPF_PSEUDO_MAP_VALUE
267 * insn[0].imm: map fd map fd
268 * insn[1].imm: 0 offset into value
269 * insn[0].off: 0 0
270 * insn[1].off: 0 0
271 * ldimm64 rewrite: address of map address of map[0]+offset
272 * verifier type: CONST_PTR_TO_MAP PTR_TO_MAP_VALUE
273 */
259#define BPF_PSEUDO_MAP_FD 1274#define BPF_PSEUDO_MAP_FD 1
275#define BPF_PSEUDO_MAP_VALUE 2
260 276
261/* when bpf_call->src_reg == BPF_PSEUDO_CALL, bpf_call->imm == pc-relative277/* when bpf_call->src_reg == BPF_PSEUDO_CALL, bpf_call->imm == pc-relative
262 * offset to another bpf function278 * offset to another bpf function
@@ -283,7 +299,7 @@ enum bpf_attach_type { · 20 unmodified lines
283 299
284#define BPF_OBJ_NAME_LEN 16U300#define BPF_OBJ_NAME_LEN 16U
285 301
286/* Flags for accessing BPF object */302/* Flags for accessing BPF object from syscall side. */
287#define BPF_F_RDONLY (1U << 3)303#define BPF_F_RDONLY (1U << 3)
288#define BPF_F_WRONLY (1U << 4)304#define BPF_F_WRONLY (1U << 4)
289 305
@@ -293,6 +309,10 @@ enum bpf_attach_type { · 3 unmodified lines
293/* Zero-initialize hash function seed. This should only be used for testing. */309/* Zero-initialize hash function seed. This should only be used for testing. */
294#define BPF_F_ZERO_SEED (1U << 6)310#define BPF_F_ZERO_SEED (1U << 6)
295 311
312/* Flags for accessing BPF object from program side. */
313#define BPF_F_RDONLY_PROG (1U << 7)
314#define BPF_F_WRONLY_PROG (1U << 8)
315
296/* flags for BPF_PROG_QUERY */316/* flags for BPF_PROG_QUERY */
297#define BPF_F_QUERY_EFFECTIVE (1U << 0)317#define BPF_F_QUERY_EFFECTIVE (1U << 0)
298 318
@@ -396,6 +416,13 @@ union bpf_attr { · 97 unmodified lines
396 __aligned_u64 data_out;416 __aligned_u64 data_out;
397 __u32 repeat;417 __u32 repeat;
398 __u32 duration;418 __u32 duration;
419 __u32 ctx_size_in; /* input: len of ctx_in */
420 __u32 ctx_size_out; /* input/output: len of ctx_out
421 * returns ENOSPC if ctx_out
422 * is too small.
423 */
424 __aligned_u64 ctx_in;
425 __aligned_u64 ctx_out;
399 } test;426 } test;
400 427
401 struct { /* anonymous struct used by BPF_*_GET_*_ID */428 struct { /* anonymous struct used by BPF_*_GET_*_ID */
@@ -602,7 +629,7 @@ union bpf_attr { · 200 unmodified lines
602 * **BPF_F_INVALIDATE_HASH** (set *skb*\ **->hash**, *skb*\629 * **BPF_F_INVALIDATE_HASH** (set *skb*\ **->hash**, *skb*\
603 * **->swhash** and *skb*\ **->l4hash** to 0).630 * **->swhash** and *skb*\ **->l4hash** to 0).
604 *631 *
605 * A call to this helper is susceptible to change the underlaying632 * A call to this helper is susceptible to change the underlying
606 * packet buffer. Therefore, at load time, all checks on pointers633 * packet buffer. Therefore, at load time, all checks on pointers
607 * previously done by the verifier are invalidated and must be634 * previously done by the verifier are invalidated and must be
608 * performed again, if the helper is used in combination with635 * performed again, if the helper is used in combination with
@@ -627,7 +654,7 @@ union bpf_attr { · 18 unmodified lines
627 * flexibility and can handle sizes larger than 2 or 4 for the654 * flexibility and can handle sizes larger than 2 or 4 for the
628 * checksum to update.655 * checksum to update.
629 *656 *
630 * A call to this helper is susceptible to change the underlaying657 * A call to this helper is susceptible to change the underlying
631 * packet buffer. Therefore, at load time, all checks on pointers658 * packet buffer. Therefore, at load time, all checks on pointers
632 * previously done by the verifier are invalidated and must be659 * previously done by the verifier are invalidated and must be
633 * performed again, if the helper is used in combination with660 * performed again, if the helper is used in combination with
@@ -659,7 +686,7 @@ union bpf_attr { · 25 unmodified lines
659 * flexibility and can handle sizes larger than 2 or 4 for the686 * flexibility and can handle sizes larger than 2 or 4 for the
660 * checksum to update.687 * checksum to update.
661 *688 *
662 * A call to this helper is susceptible to change the underlaying689 * A call to this helper is susceptible to change the underlying
663 * packet buffer. Therefore, at load time, all checks on pointers690 * packet buffer. Therefore, at load time, all checks on pointers
664 * previously done by the verifier are invalidated and must be691 * previously done by the verifier are invalidated and must be
665 * performed again, if the helper is used in combination with692 * performed again, if the helper is used in combination with
@@ -714,7 +741,7 @@ union bpf_attr { · 48 unmodified lines
714 * efficient, but it is handled through an action code where the741 * efficient, but it is handled through an action code where the
715 * redirection happens only after the eBPF program has returned.742 * redirection happens only after the eBPF program has returned.
716 *743 *
717 * A call to this helper is susceptible to change the underlaying744 * A call to this helper is susceptible to change the underlying
718 * packet buffer. Therefore, at load time, all checks on pointers745 * packet buffer. Therefore, at load time, all checks on pointers
719 * previously done by the verifier are invalidated and must be746 * previously done by the verifier are invalidated and must be
720 * performed again, if the helper is used in combination with747 * performed again, if the helper is used in combination with
@@ -779,7 +806,7 @@ union bpf_attr { · 58 unmodified lines
779 * **ETH_P_8021Q** and **ETH_P_8021AD**, it is considered to806 * **ETH_P_8021Q** and **ETH_P_8021AD**, it is considered to
780 * be **ETH_P_8021Q**.807 * be **ETH_P_8021Q**.
781 *808 *
782 * A call to this helper is susceptible to change the underlaying809 * A call to this helper is susceptible to change the underlying
783 * packet buffer. Therefore, at load time, all checks on pointers810 * packet buffer. Therefore, at load time, all checks on pointers
784 * previously done by the verifier are invalidated and must be811 * previously done by the verifier are invalidated and must be
785 * performed again, if the helper is used in combination with812 * performed again, if the helper is used in combination with
@@ -791,7 +818,7 @@ union bpf_attr { · 5 unmodified lines
791 * Description818 * Description
792 * Pop a VLAN header from the packet associated to *skb*.819 * Pop a VLAN header from the packet associated to *skb*.
793 *820 *
794 * A call to this helper is susceptible to change the underlaying821 * A call to this helper is susceptible to change the underlying
795 * packet buffer. Therefore, at load time, all checks on pointers822 * packet buffer. Therefore, at load time, all checks on pointers
796 * previously done by the verifier are invalidated and must be823 * previously done by the verifier are invalidated and must be
797 * performed again, if the helper is used in combination with824 * performed again, if the helper is used in combination with
@@ -1141,7 +1168,7 @@ union bpf_attr { · 343 unmodified lines
1141 * All values for *flags* are reserved for future usage, and must1168 * All values for *flags* are reserved for future usage, and must
1142 * be left at zero.1169 * be left at zero.
1143 *1170 *
1144 * A call to this helper is susceptible to change the underlaying1171 * A call to this helper is susceptible to change the underlying
1145 * packet buffer. Therefore, at load time, all checks on pointers1172 * packet buffer. Therefore, at load time, all checks on pointers
1146 * previously done by the verifier are invalidated and must be1173 * previously done by the verifier are invalidated and must be
1147 * performed again, if the helper is used in combination with1174 * performed again, if the helper is used in combination with
@@ -1254,7 +1281,7 @@ union bpf_attr { · 106 unmodified lines
1254 * implicitly linearizes, unclones and drops offloads from the1281 * implicitly linearizes, unclones and drops offloads from the
1255 * *skb*.1282 * *skb*.
1256 *1283 *
1257 * A call to this helper is susceptible to change the underlaying1284 * A call to this helper is susceptible to change the underlying
1258 * packet buffer. Therefore, at load time, all checks on pointers1285 * packet buffer. Therefore, at load time, all checks on pointers
1259 * previously done by the verifier are invalidated and must be1286 * previously done by the verifier are invalidated and must be
1260 * performed again, if the helper is used in combination with1287 * performed again, if the helper is used in combination with
@@ -1290,7 +1317,7 @@ union bpf_attr { · 29 unmodified lines
1290 * **bpf_skb_pull_data()** to effectively unclone the *skb* from1317 * **bpf_skb_pull_data()** to effectively unclone the *skb* from
1291 * the very beginning in case it is indeed cloned.1318 * the very beginning in case it is indeed cloned.
1292 *1319 *
1293 * A call to this helper is susceptible to change the underlaying1320 * A call to this helper is susceptible to change the underlying
1294 * packet buffer. Therefore, at load time, all checks on pointers1321 * packet buffer. Therefore, at load time, all checks on pointers
1295 * previously done by the verifier are invalidated and must be1322 * previously done by the verifier are invalidated and must be
1296 * performed again, if the helper is used in combination with1323 * performed again, if the helper is used in combination with
@@ -1342,7 +1369,7 @@ union bpf_attr { · 45 unmodified lines
1342 * All values for *flags* are reserved for future usage, and must1369 * All values for *flags* are reserved for future usage, and must
1343 * be left at zero.1370 * be left at zero.
1344 *1371 *
1345 * A call to this helper is susceptible to change the underlaying1372 * A call to this helper is susceptible to change the underlying
1346 * packet buffer. Therefore, at load time, all checks on pointers1373 * packet buffer. Therefore, at load time, all checks on pointers
1347 * previously done by the verifier are invalidated and must be1374 * previously done by the verifier are invalidated and must be
1348 * performed again, if the helper is used in combination with1375 * performed again, if the helper is used in combination with
@@ -1357,7 +1384,7 @@ union bpf_attr { · 8 unmodified lines
1357 * can be used to prepare the packet for pushing or popping1384 * can be used to prepare the packet for pushing or popping
1358 * headers.1385 * headers.
1359 *1386 *
1360 * A call to this helper is susceptible to change the underlaying1387 * A call to this helper is susceptible to change the underlying
1361 * packet buffer. Therefore, at load time, all checks on pointers1388 * packet buffer. Therefore, at load time, all checks on pointers
1362 * previously done by the verifier are invalidated and must be1389 * previously done by the verifier are invalidated and must be
1363 * performed again, if the helper is used in combination with1390 * performed again, if the helper is used in combination with
@@ -1478,15 +1505,33 @@ union bpf_attr { · 114 unmodified lines
1478 * Grow or shrink the room for data in the packet associated to1505 * Grow or shrink the room for data in the packet associated to
1479 * *skb* by *len_diff*, and according to the selected *mode*.1506 * *skb* by *len_diff*, and according to the selected *mode*.
1480 *1507 *
1481 * There is a single supported mode at this time:1508 * There are two supported modes at this time:
1509 *
1510 * * **BPF_ADJ_ROOM_MAC**: Adjust room at the mac layer
1511 * (room space is added or removed below the layer 2 header).
1482 *1512 *
1483 * * **BPF_ADJ_ROOM_NET**: Adjust room at the network layer1513 * * **BPF_ADJ_ROOM_NET**: Adjust room at the network layer
1484 * (room space is added or removed below the layer 3 header).1514 * (room space is added or removed below the layer 3 header).
1485 *1515 *
1486 * All values for *flags* are reserved for future usage, and must1516 * The following flags are supported at this time:
1487 * be left at zero.1517 *
1518 * * **BPF_F_ADJ_ROOM_FIXED_GSO**: Do not adjust gso_size.
1519 * Adjusting mss in this way is not allowed for datagrams.
1520 *
1521 * * **BPF_F_ADJ_ROOM_ENCAP_L3_IPV4**,
1522 * **BPF_F_ADJ_ROOM_ENCAP_L3_IPV6**:
1523 * Any new space is reserved to hold a tunnel header.
1524 * Configure skb offsets and other fields accordingly.
1525 *
1526 * * **BPF_F_ADJ_ROOM_ENCAP_L4_GRE**,
1527 * **BPF_F_ADJ_ROOM_ENCAP_L4_UDP**:
1528 * Use with ENCAP_L3 flags to further specify the tunnel type.
1529 *
1530 * * **BPF_F_ADJ_ROOM_ENCAP_L2**\ (*len*):
1531 * Use with ENCAP_L3/L4 flags to further specify the tunnel
1532 * type; *len* is the length of the inner MAC header.
1488 *1533 *
1489 * A call to this helper is susceptible to change the underlaying1534 * A call to this helper is susceptible to change the underlying
1490 * packet buffer. Therefore, at load time, all checks on pointers1535 * packet buffer. Therefore, at load time, all checks on pointers
1491 * previously done by the verifier are invalidated and must be1536 * previously done by the verifier are invalidated and must be
1492 * performed again, if the helper is used in combination with1537 * performed again, if the helper is used in combination with
@@ -1565,7 +1610,7 @@ union bpf_attr { · 72 unmodified lines
1565 * more flexibility as the user is free to store whatever meta1610 * more flexibility as the user is free to store whatever meta
1566 * data they need.1611 * data they need.
1567 *1612 *
1568 * A call to this helper is susceptible to change the underlaying1613 * A call to this helper is susceptible to change the underlying
1569 * packet buffer. Therefore, at load time, all checks on pointers1614 * packet buffer. Therefore, at load time, all checks on pointers
1570 * previously done by the verifier are invalidated and must be1615 * previously done by the verifier are invalidated and must be
1571 * performed again, if the helper is used in combination with1616 * performed again, if the helper is used in combination with
@@ -1694,12 +1739,19 @@ union bpf_attr { · 122 unmodified lines
1694 * error if an eBPF program tries to set a callback that is not1739 * error if an eBPF program tries to set a callback that is not
1695 * supported in the current kernel.1740 * supported in the current kernel.
1696 *1741 *
1697 * The supported callback values that *argval* can combine are:1742 * *argval* is a flag array which can combine these flags:
1698 *1743 *
1699 * * **BPF_SOCK_OPS_RTO_CB_FLAG** (retransmission time out)1744 * * **BPF_SOCK_OPS_RTO_CB_FLAG** (retransmission time out)
1700 * * **BPF_SOCK_OPS_RETRANS_CB_FLAG** (retransmission)1745 * * **BPF_SOCK_OPS_RETRANS_CB_FLAG** (retransmission)
1701 * * **BPF_SOCK_OPS_STATE_CB_FLAG** (TCP state change)1746 * * **BPF_SOCK_OPS_STATE_CB_FLAG** (TCP state change)
1702 *1747 *
1748 * Therefore, this function can be used to clear a callback flag by
1749 * setting the appropriate bit to zero. e.g. to disable the RTO
1750 * callback:
1751 *
1752 * **bpf_sock_ops_cb_flags_set(bpf_sock,**
1753 * **bpf_sock->bpf_sock_ops_cb_flags & ~BPF_SOCK_OPS_RTO_CB_FLAG)**
1754 *
1703 * Here are some examples of where one could call such eBPF1755 * Here are some examples of where one could call such eBPF
1704 * program:1756 * program:
1705 *1757 *
@@ -1800,7 +1852,7 @@ union bpf_attr { · 94 unmodified lines
1800 * copied if necessary (i.e. if data was not linear and if start1852 * copied if necessary (i.e. if data was not linear and if start
1801 * and end pointers do not point to the same chunk).1853 * and end pointers do not point to the same chunk).
1802 *1854 *
1803 * A call to this helper is susceptible to change the underlaying1855 * A call to this helper is susceptible to change the underlying
1804 * packet buffer. Therefore, at load time, all checks on pointers1856 * packet buffer. Therefore, at load time, all checks on pointers
1805 * previously done by the verifier are invalidated and must be1857 * previously done by the verifier are invalidated and must be
1806 * performed again, if the helper is used in combination with1858 * performed again, if the helper is used in combination with
@@ -1834,7 +1886,7 @@ union bpf_attr { · 27 unmodified lines
1834 * only possible to shrink the packet as of this writing,1886 * only possible to shrink the packet as of this writing,
1835 * therefore *delta* must be a negative integer.1887 * therefore *delta* must be a negative integer.
1836 *1888 *
1837 * A call to this helper is susceptible to change the underlaying1889 * A call to this helper is susceptible to change the underlying
1838 * packet buffer. Therefore, at load time, all checks on pointers1890 * packet buffer. Therefore, at load time, all checks on pointers
1839 * previously done by the verifier are invalidated and must be1891 * previously done by the verifier are invalidated and must be
1840 * performed again, if the helper is used in combination with1892 * performed again, if the helper is used in combination with
@@ -2009,18 +2061,18 @@ union bpf_attr { · 168 unmodified lines
2009 * **BPF_LWT_ENCAP_IP**2061 * **BPF_LWT_ENCAP_IP**
2010 * IP encapsulation (GRE/GUE/IPIP/etc). The outer header2062 * IP encapsulation (GRE/GUE/IPIP/etc). The outer header
2011 * must be IPv4 or IPv6, followed by zero or more2063 * must be IPv4 or IPv6, followed by zero or more
2012 * additional headers, up to LWT_BPF_MAX_HEADROOM total2064 * additional headers, up to **LWT_BPF_MAX_HEADROOM**
2013 * bytes in all prepended headers. Please note that2065 * total bytes in all prepended headers. Please note that
2014 * if skb_is_gso(skb) is true, no more than two headers2066 * if **skb_is_gso**\ (*skb*) is true, no more than two
2015 * can be prepended, and the inner header, if present,2067 * headers can be prepended, and the inner header, if
2016 * should be either GRE or UDP/GUE.2068 * present, should be either GRE or UDP/GUE.
2017 *2069 *
2018 * BPF_LWT_ENCAP_SEG6*** types can be called by bpf programs of2070 * **BPF_LWT_ENCAP_SEG6**\ \* types can be called by BPF programs
2019 * type BPF_PROG_TYPE_LWT_IN; BPF_LWT_ENCAP_IP type can be called2071 * of type **BPF_PROG_TYPE_LWT_IN**; **BPF_LWT_ENCAP_IP** type can
2020 * by bpf programs of types BPF_PROG_TYPE_LWT_IN and2072 * be called by bpf programs of types **BPF_PROG_TYPE_LWT_IN** and
2021 * BPF_PROG_TYPE_LWT_XMIT.2073 * **BPF_PROG_TYPE_LWT_XMIT**.
2022 *2074 *
2023 * A call to this helper is susceptible to change the underlaying2075 * A call to this helper is susceptible to change the underlying
2024 * packet buffer. Therefore, at load time, all checks on pointers2076 * packet buffer. Therefore, at load time, all checks on pointers
2025 * previously done by the verifier are invalidated and must be2077 * previously done by the verifier are invalidated and must be
2026 * performed again, if the helper is used in combination with2078 * performed again, if the helper is used in combination with
@@ -2035,7 +2087,7 @@ union bpf_attr { · 8 unmodified lines
2035 * inside the outermost IPv6 Segment Routing Header can be2087 * inside the outermost IPv6 Segment Routing Header can be
2036 * modified through this helper.2088 * modified through this helper.
2037 *2089 *
2038 * A call to this helper is susceptible to change the underlaying2090 * A call to this helper is susceptible to change the underlying
2039 * packet buffer. Therefore, at load time, all checks on pointers2091 * packet buffer. Therefore, at load time, all checks on pointers
2040 * previously done by the verifier are invalidated and must be2092 * previously done by the verifier are invalidated and must be
2041 * performed again, if the helper is used in combination with2093 * performed again, if the helper is used in combination with
@@ -2051,7 +2103,7 @@ union bpf_attr { · 9 unmodified lines
2051 * after the segments are accepted. *delta* can be as well2103 * after the segments are accepted. *delta* can be as well
2052 * positive (growing) as negative (shrinking).2104 * positive (growing) as negative (shrinking).
2053 *2105 *
2054 * A call to this helper is susceptible to change the underlaying2106 * A call to this helper is susceptible to change the underlying
2055 * packet buffer. Therefore, at load time, all checks on pointers2107 * packet buffer. Therefore, at load time, all checks on pointers
2056 * previously done by the verifier are invalidated and must be2108 * previously done by the verifier are invalidated and must be
2057 * performed again, if the helper is used in combination with2109 * performed again, if the helper is used in combination with
@@ -2074,13 +2126,13 @@ union bpf_attr { · 16 unmodified lines
2074 * Type of *param*: **int**.2126 * Type of *param*: **int**.
2075 * **SEG6_LOCAL_ACTION_END_B6**2127 * **SEG6_LOCAL_ACTION_END_B6**
2076 * End.B6 action: Endpoint bound to an SRv6 policy.2128 * End.B6 action: Endpoint bound to an SRv6 policy.
2077 * Type of param: **struct ipv6_sr_hdr**.2129 * Type of *param*: **struct ipv6_sr_hdr**.
2078 * **SEG6_LOCAL_ACTION_END_B6_ENCAP**2130 * **SEG6_LOCAL_ACTION_END_B6_ENCAP**
2079 * End.B6.Encap action: Endpoint bound to an SRv62131 * End.B6.Encap action: Endpoint bound to an SRv6
2080 * encapsulation policy.2132 * encapsulation policy.
2081 * Type of param: **struct ipv6_sr_hdr**.2133 * Type of *param*: **struct ipv6_sr_hdr**.
2082 *2134 *
2083 * A call to this helper is susceptible to change the underlaying2135 * A call to this helper is susceptible to change the underlying
2084 * packet buffer. Therefore, at load time, all checks on pointers2136 * packet buffer. Therefore, at load time, all checks on pointers
2085 * previously done by the verifier are invalidated and must be2137 * previously done by the verifier are invalidated and must be
2086 * performed again, if the helper is used in combination with2138 * performed again, if the helper is used in combination with
@@ -2233,7 +2285,8 @@ union bpf_attr { · 146 unmodified lines
2233 * Return2285 * Return
2234 * Pointer to **struct bpf_sock**, or **NULL** in case of failure.2286 * Pointer to **struct bpf_sock**, or **NULL** in case of failure.
2235 * For sockets with reuseport option, the **struct bpf_sock**2287 * For sockets with reuseport option, the **struct bpf_sock**
2236 * result is from **reuse->socks**\ [] using the hash of the tuple.2288 * result is from *reuse*\ **->socks**\ [] using the hash of the
2289 * tuple.
2237 *2290 *
2238 * struct bpf_sock *bpf_sk_lookup_udp(void *ctx, struct bpf_sock_tuple *tuple, u32 tuple_size, u64 netns, u64 flags)2291 * struct bpf_sock *bpf_sk_lookup_udp(void *ctx, struct bpf_sock_tuple *tuple, u32 tuple_size, u64 netns, u64 flags)
2239 * Description2292 * Description
@@ -2269,7 +2322,8 @@ union bpf_attr { · 29 unmodified lines
2269 * Return2322 * Return
2270 * Pointer to **struct bpf_sock**, or **NULL** in case of failure.2323 * Pointer to **struct bpf_sock**, or **NULL** in case of failure.
2271 * For sockets with reuseport option, the **struct bpf_sock**2324 * For sockets with reuseport option, the **struct bpf_sock**
2272 * result is from **reuse->socks**\ [] using the hash of the tuple.2325 * result is from *reuse*\ **->socks**\ [] using the hash of the
2326 * tuple.
2273 *2327 *
2274 * int bpf_sk_release(struct bpf_sock *sock)2328 * int bpf_sk_release(struct bpf_sock *sock)
2275 * Description2329 * Description
@@ -2431,6 +2485,193 @@ union bpf_attr { · 155 unmodified lines
2431 * Return2485 * Return
2432 * A **struct bpf_sock** pointer on success, or **NULL** in2486 * A **struct bpf_sock** pointer on success, or **NULL** in
2433 * case of failure.2487 * case of failure.
2488 *
2489 * struct bpf_sock *bpf_skc_lookup_tcp(void *ctx, struct bpf_sock_tuple *tuple, u32 tuple_size, u64 netns, u64 flags)
2490 * Description
2491 * Look for TCP socket matching *tuple*, optionally in a child
2492 * network namespace *netns*. The return value must be checked,
2493 * and if non-**NULL**, released via **bpf_sk_release**\ ().
2494 *
2495 * This function is identical to **bpf_sk_lookup_tcp**\ (), except
2496 * that it also returns timewait or request sockets. Use
2497 * **bpf_sk_fullsock**\ () or **bpf_tcp_sock**\ () to access the
2498 * full structure.
2499 *
2500 * This helper is available only if the kernel was compiled with
2501 * **CONFIG_NET** configuration option.
2502 * Return
2503 * Pointer to **struct bpf_sock**, or **NULL** in case of failure.
2504 * For sockets with reuseport option, the **struct bpf_sock**
2505 * result is from *reuse*\ **->socks**\ [] using the hash of the
2506 * tuple.
2507 *
2508 * int bpf_tcp_check_syncookie(struct bpf_sock *sk, void *iph, u32 iph_len, struct tcphdr *th, u32 th_len)
2509 * Description
2510 * Check whether *iph* and *th* contain a valid SYN cookie ACK for
2511 * the listening socket in *sk*.
2512 *
2513 * *iph* points to the start of the IPv4 or IPv6 header, while
2514 * *iph_len* contains **sizeof**\ (**struct iphdr**) or
2515 * **sizeof**\ (**struct ip6hdr**).
2516 *
2517 * *th* points to the start of the TCP header, while *th_len*
2518 * contains **sizeof**\ (**struct tcphdr**).
2519 *
2520 * Return
2521 * 0 if *iph* and *th* are a valid SYN cookie ACK, or a negative
2522 * error otherwise.
2523 *
2524 * int bpf_sysctl_get_name(struct bpf_sysctl *ctx, char *buf, size_t buf_len, u64 flags)
2525 * Description
2526 * Get name of sysctl in /proc/sys/ and copy it into provided by
2527 * program buffer *buf* of size *buf_len*.
2528 *
2529 * The buffer is always NUL terminated, unless it's zero-sized.
2530 *
2531 * If *flags* is zero, full name (e.g. "net/ipv4/tcp_mem") is
2532 * copied. Use **BPF_F_SYSCTL_BASE_NAME** flag to copy base name
2533 * only (e.g. "tcp_mem").
2534 * Return
2535 * Number of character copied (not including the trailing NUL).
2536 *
2537 * **-E2BIG** if the buffer wasn't big enough (*buf* will contain
2538 * truncated name in this case).
2539 *
2540 * int bpf_sysctl_get_current_value(struct bpf_sysctl *ctx, char *buf, size_t buf_len)
2541 * Description
2542 * Get current value of sysctl as it is presented in /proc/sys
2543 * (incl. newline, etc), and copy it as a string into provided
2544 * by program buffer *buf* of size *buf_len*.
2545 *
2546 * The whole value is copied, no matter what file position user
2547 * space issued e.g. sys_read at.
2548 *
2549 * The buffer is always NUL terminated, unless it's zero-sized.
2550 * Return
2551 * Number of character copied (not including the trailing NUL).
2552 *
2553 * **-E2BIG** if the buffer wasn't big enough (*buf* will contain
2554 * truncated name in this case).
2555 *
2556 * **-EINVAL** if current value was unavailable, e.g. because
2557 * sysctl is uninitialized and read returns -EIO for it.
2558 *
2559 * int bpf_sysctl_get_new_value(struct bpf_sysctl *ctx, char *buf, size_t buf_len)
2560 * Description
2561 * Get new value being written by user space to sysctl (before
2562 * the actual write happens) and copy it as a string into
2563 * provided by program buffer *buf* of size *buf_len*.
2564 *
2565 * User space may write new value at file position > 0.
2566 *
2567 * The buffer is always NUL terminated, unless it's zero-sized.
2568 * Return
2569 * Number of character copied (not including the trailing NUL).
2570 *
2571 * **-E2BIG** if the buffer wasn't big enough (*buf* will contain
2572 * truncated name in this case).
2573 *
2574 * **-EINVAL** if sysctl is being read.
2575 *
2576 * int bpf_sysctl_set_new_value(struct bpf_sysctl *ctx, const char *buf, size_t buf_len)
2577 * Description
2578 * Override new value being written by user space to sysctl with
2579 * value provided by program in buffer *buf* of size *buf_len*.
2580 *
2581 * *buf* should contain a string in same form as provided by user
2582 * space on sysctl write.
2583 *
2584 * User space may write new value at file position > 0. To override
2585 * the whole sysctl value file position should be set to zero.
2586 * Return
2587 * 0 on success.
2588 *
2589 * **-E2BIG** if the *buf_len* is too big.
2590 *
2591 * **-EINVAL** if sysctl is being read.
2592 *
2593 * int bpf_strtol(const char *buf, size_t buf_len, u64 flags, long *res)
2594 * Description
2595 * Convert the initial part of the string from buffer *buf* of
2596 * size *buf_len* to a long integer according to the given base
2597 * and save the result in *res*.
2598 *
2599 * The string may begin with an arbitrary amount of white space
2600 * (as determined by **isspace**\ (3)) followed by a single
2601 * optional '**-**' sign.
2602 *
2603 * Five least significant bits of *flags* encode base, other bits
2604 * are currently unused.
2605 *
2606 * Base must be either 8, 10, 16 or 0 to detect it automatically
2607 * similar to user space **strtol**\ (3).
2608 * Return
2609 * Number of characters consumed on success. Must be positive but
2610 * no more than *buf_len*.
2611 *
2612 * **-EINVAL** if no valid digits were found or unsupported base
2613 * was provided.
2614 *
2615 * **-ERANGE** if resulting value was out of range.
2616 *
2617 * int bpf_strtoul(const char *buf, size_t buf_len, u64 flags, unsigned long *res)
2618 * Description
2619 * Convert the initial part of the string from buffer *buf* of
2620 * size *buf_len* to an unsigned long integer according to the
2621 * given base and save the result in *res*.
2622 *
2623 * The string may begin with an arbitrary amount of white space
2624 * (as determined by **isspace**\ (3)).
2625 *
2626 * Five least significant bits of *flags* encode base, other bits
2627 * are currently unused.
2628 *
2629 * Base must be either 8, 10, 16 or 0 to detect it automatically
2630 * similar to user space **strtoul**\ (3).
2631 * Return
2632 * Number of characters consumed on success. Must be positive but
2633 * no more than *buf_len*.
2634 *
2635 * **-EINVAL** if no valid digits were found or unsupported base
2636 * was provided.
2637 *
2638 * **-ERANGE** if resulting value was out of range.
2639 *
2640 * void *bpf_sk_storage_get(struct bpf_map *map, struct bpf_sock *sk, void *value, u64 flags)
2641 * Description
2642 * Get a bpf-local-storage from a *sk*.
2643 *
2644 * Logically, it could be thought of getting the value from
2645 * a *map* with *sk* as the **key**. From this
2646 * perspective, the usage is not much different from
2647 * **bpf_map_lookup_elem**\ (*map*, **&**\ *sk*) except this
2648 * helper enforces the key must be a full socket and the map must
2649 * be a **BPF_MAP_TYPE_SK_STORAGE** also.
2650 *
2651 * Underneath, the value is stored locally at *sk* instead of
2652 * the *map*. The *map* is used as the bpf-local-storage
2653 * "type". The bpf-local-storage "type" (i.e. the *map*) is
2654 * searched against all bpf-local-storages residing at *sk*.
2655 *
2656 * An optional *flags* (**BPF_SK_STORAGE_GET_F_CREATE**) can be
2657 * used such that a new bpf-local-storage will be
2658 * created if one does not exist. *value* can be used
2659 * together with **BPF_SK_STORAGE_GET_F_CREATE** to specify
2660 * the initial value of a bpf-local-storage. If *value* is
2661 * **NULL**, the new bpf-local-storage will be zero initialized.
2662 * Return
2663 * A bpf-local-storage pointer is returned on success.
2664 *
2665 * **NULL** if not found or there was an error in adding
2666 * a new bpf-local-storage.
2667 *
2668 * int bpf_sk_storage_delete(struct bpf_map *map, struct bpf_sock *sk)
2669 * Description
2670 * Delete a bpf-local-storage from a *sk*.
2671 * Return
2672 * 0 on success.
2673 *
2674 * **-ENOENT** if the bpf-local-storage cannot be found.
2434 */2675 */
2435#define __BPF_FUNC_MAPPER(FN) \2676#define __BPF_FUNC_MAPPER(FN) \
2436 FN(unspec), \2677 FN(unspec), \
@@ -2531,7 +2772,17 @@ union bpf_attr { · 94 unmodified lines
2531 FN(sk_fullsock), \2772 FN(sk_fullsock), \
2532 FN(tcp_sock), \2773 FN(tcp_sock), \
2533 FN(skb_ecn_set_ce), \2774 FN(skb_ecn_set_ce), \
2534 FN(get_listener_sock),2775 FN(get_listener_sock), \
2776 FN(skc_lookup_tcp), \
2777 FN(tcp_check_syncookie), \
2778 FN(sysctl_get_name), \
2779 FN(sysctl_get_current_value), \
2780 FN(sysctl_get_new_value), \
2781 FN(sysctl_set_new_value), \
2782 FN(strtol), \
2783 FN(strtoul), \
2784 FN(sk_storage_get), \
2785 FN(sk_storage_delete),
2535 2786
2536/* integer value in 'imm' field of BPF_CALL instruction selects which helper2787/* integer value in 'imm' field of BPF_CALL instruction selects which helper
2537 * function eBPF program intends to call2788 * function eBPF program intends to call
@@ -2590,9 +2841,30 @@ enum bpf_func_id { · 52 unmodified lines
2590/* Current network namespace */2841/* Current network namespace */
2591#define BPF_F_CURRENT_NETNS (-1L)2842#define BPF_F_CURRENT_NETNS (-1L)
2592 2843
2844/* BPF_FUNC_skb_adjust_room flags. */
2845#define BPF_F_ADJ_ROOM_FIXED_GSO (1ULL << 0)
2846
2847#define BPF_ADJ_ROOM_ENCAP_L2_MASK 0xff
2848#define BPF_ADJ_ROOM_ENCAP_L2_SHIFT 56
2849
2850#define BPF_F_ADJ_ROOM_ENCAP_L3_IPV4 (1ULL << 1)
2851#define BPF_F_ADJ_ROOM_ENCAP_L3_IPV6 (1ULL << 2)
2852#define BPF_F_ADJ_ROOM_ENCAP_L4_GRE (1ULL << 3)
2853#define BPF_F_ADJ_ROOM_ENCAP_L4_UDP (1ULL << 4)
2854#define BPF_F_ADJ_ROOM_ENCAP_L2(len) (((__u64)len & \
2855 BPF_ADJ_ROOM_ENCAP_L2_MASK) \
2856 << BPF_ADJ_ROOM_ENCAP_L2_SHIFT)
2857
2858/* BPF_FUNC_sysctl_get_name flags. */
2859#define BPF_F_SYSCTL_BASE_NAME (1ULL << 0)
2860
2861/* BPF_FUNC_sk_storage_get flags */
2862#define BPF_SK_STORAGE_GET_F_CREATE (1ULL << 0)
2863
2593/* Mode for BPF_FUNC_skb_adjust_room helper. */2864/* Mode for BPF_FUNC_skb_adjust_room helper. */
2594enum bpf_adj_room_mode {2865enum bpf_adj_room_mode {
2595 BPF_ADJ_ROOM_NET,2866 BPF_ADJ_ROOM_NET,
2867 BPF_ADJ_ROOM_MAC,
2596};2868};
2597 2869
2598/* Mode for BPF_FUNC_skb_load_bytes_relative helper. */2870/* Mode for BPF_FUNC_skb_load_bytes_relative helper. */
@@ -3218,4 +3490,14 @@ struct bpf_line_info { · 619 unmodified lines
3218struct bpf_spin_lock {3490struct bpf_spin_lock {
3219 __u32 val;3491 __u32 val;
3220};3492};
3493
3494struct bpf_sysctl {
3495 __u32 write; /* Sysctl is being read (= 0) or written (= 1).
3496 * Allows 1,2,4-byte read, but no write.
3497 */
3498 __u32 file_pos; /* Sysctl file position to read from, write to.
3499 * Allows 1,2,4-byte read an 4-byte write.
3500 */
3501};
3502
3221#endif /* _UAPI__LINUX_BPF_H__ */3503#endif /* _UAPI__LINUX_BPF_H__ */
include/uapi/linux/btf.h+28−4
@@ -39,11 +39,11 @@ struct btf_type { · 38 unmodified lines
39 * struct, union and fwd39 * struct, union and fwd
40 */40 */
41 __u32 info;41 __u32 info;
42 /* "size" is used by INT, ENUM, STRUCT and UNION.42 /* "size" is used by INT, ENUM, STRUCT, UNION and DATASEC.
43 * "size" tells the size of the type it is describing.43 * "size" tells the size of the type it is describing.
44 *44 *
45 * "type" is used by PTR, TYPEDEF, VOLATILE, CONST, RESTRICT,45 * "type" is used by PTR, TYPEDEF, VOLATILE, CONST, RESTRICT,
46 * FUNC and FUNC_PROTO.46 * FUNC, FUNC_PROTO and VAR.
47 * "type" is a type_id referring to another type.47 * "type" is a type_id referring to another type.
48 */48 */
49 union {49 union {
@@ -70,8 +70,10 @@ struct btf_type { · 20 unmodified lines
70#define BTF_KIND_RESTRICT 11 /* Restrict */70#define BTF_KIND_RESTRICT 11 /* Restrict */
71#define BTF_KIND_FUNC 12 /* Function */71#define BTF_KIND_FUNC 12 /* Function */
72#define BTF_KIND_FUNC_PROTO 13 /* Function Proto */72#define BTF_KIND_FUNC_PROTO 13 /* Function Proto */
73#define BTF_KIND_MAX 1373#define BTF_KIND_VAR 14 /* Variable */
74#define NR_BTF_KINDS 1474#define BTF_KIND_DATASEC 15 /* Section */
75#define BTF_KIND_MAX BTF_KIND_DATASEC
76#define NR_BTF_KINDS (BTF_KIND_MAX + 1)
75 77
76/* For some specific BTF_KIND, "struct btf_type" is immediately78/* For some specific BTF_KIND, "struct btf_type" is immediately
77 * followed by extra data.79 * followed by extra data.
@@ -138,4 +140,26 @@ struct btf_param { · 60 unmodified lines
138 __u32 type;140 __u32 type;
139};141};
140 142
143enum {
144 BTF_VAR_STATIC = 0,
145 BTF_VAR_GLOBAL_ALLOCATED,
146};
147
148/* BTF_KIND_VAR is followed by a single "struct btf_var" to describe
149 * additional information related to the variable such as its linkage.
150 */
151struct btf_var {
152 __u32 linkage;
153};
154
155/* BTF_KIND_DATASEC is followed by multiple "struct btf_var_secinfo"
156 * to describe all BTF_KIND_VAR types it contains along with it's
157 * in-section offset as well as size.
158 */
159struct btf_var_secinfo {
160 __u32 type;
161 __u32 offset;
162 __u32 size;
163};
164
141#endif /* _UAPI__LINUX_BTF_H__ */165#endif /* _UAPI__LINUX_BTF_H__ */
include/uapi/linux/btrfs_tree.h+2−0
@@ -307,6 +307,8 @@ · 306 unmodified lines
307 *307 *
308 * Used by:308 * Used by:
309 * struct btrfs_dir_item.type309 * struct btrfs_dir_item.type
310 *
311 * Values 0..7 must match common file type values in fs_types.h.
310 */312 */
311#define BTRFS_FT_UNKNOWN 0313#define BTRFS_FT_UNKNOWN 0
312#define BTRFS_FT_REG_FILE 1314#define BTRFS_FT_REG_FILE 1
include/uapi/linux/elf-em.h+6−0
@@ -34,14 +34,20 @@ · 33 unmodified lines
34#define EM_M32R 88 /* Renesas M32R */34#define EM_M32R 88 /* Renesas M32R */
35#define EM_MN10300 89 /* Panasonic/MEI MN10300, AM33 */35#define EM_MN10300 89 /* Panasonic/MEI MN10300, AM33 */
36#define EM_OPENRISC 92 /* OpenRISC 32-bit embedded processor */36#define EM_OPENRISC 92 /* OpenRISC 32-bit embedded processor */
37#define EM_ARCOMPACT 93 /* ARCompact processor */
37#define EM_XTENSA 94 /* Tensilica Xtensa Architecture */38#define EM_XTENSA 94 /* Tensilica Xtensa Architecture */
38#define EM_BLACKFIN 106 /* ADI Blackfin Processor */39#define EM_BLACKFIN 106 /* ADI Blackfin Processor */
40#define EM_UNICORE 110 /* UniCore-32 */
39#define EM_ALTERA_NIOS2 113 /* Altera Nios II soft-core processor */41#define EM_ALTERA_NIOS2 113 /* Altera Nios II soft-core processor */
40#define EM_TI_C6000 140 /* TI C6X DSPs */42#define EM_TI_C6000 140 /* TI C6X DSPs */
43#define EM_HEXAGON 164 /* QUALCOMM Hexagon */
44#define EM_NDS32 167 /* Andes Technology compact code size
45 embedded RISC processor family */
41#define EM_AARCH64 183 /* ARM 64 bit */46#define EM_AARCH64 183 /* ARM 64 bit */
42#define EM_TILEPRO 188 /* Tilera TILEPro */47#define EM_TILEPRO 188 /* Tilera TILEPro */
43#define EM_MICROBLAZE 189 /* Xilinx MicroBlaze */48#define EM_MICROBLAZE 189 /* Xilinx MicroBlaze */
44#define EM_TILEGX 191 /* Tilera TILE-Gx */49#define EM_TILEGX 191 /* Tilera TILE-Gx */
50#define EM_ARCV2 195 /* ARCv2 Cores */
45#define EM_RISCV 243 /* RISC-V */51#define EM_RISCV 243 /* RISC-V */
46#define EM_BPF 247 /* Linux BPF - in-kernel virtual machine */52#define EM_BPF 247 /* Linux BPF - in-kernel virtual machine */
47#define EM_CSKY 252 /* C-SKY */53#define EM_CSKY 252 /* C-SKY */
include/uapi/linux/ethtool.h+11−0
@@ -252,9 +252,17 @@ struct ethtool_tunable { · 251 unmodified lines
252#define DOWNSHIFT_DEV_DEFAULT_COUNT 0xff252#define DOWNSHIFT_DEV_DEFAULT_COUNT 0xff
253#define DOWNSHIFT_DEV_DISABLE 0253#define DOWNSHIFT_DEV_DISABLE 0
254 254
255/* Time in msecs after which link is reported as down
256 * 0 = lowest time supported by the PHY
257 * 0xff = off, link down detection according to standard
258 */
259#define ETHTOOL_PHY_FAST_LINK_DOWN_ON 0
260#define ETHTOOL_PHY_FAST_LINK_DOWN_OFF 0xff
261
255enum phy_tunable_id {262enum phy_tunable_id {
256 ETHTOOL_PHY_ID_UNSPEC,263 ETHTOOL_PHY_ID_UNSPEC,
257 ETHTOOL_PHY_DOWNSHIFT,264 ETHTOOL_PHY_DOWNSHIFT,
265 ETHTOOL_PHY_FAST_LINK_DOWN,
258 /*266 /*
259 * Add your fresh new phy tunable attribute above and remember to update267 * Add your fresh new phy tunable attribute above and remember to update
260 * phy_tunable_strings[] in net/core/ethtool.c268 * phy_tunable_strings[] in net/core/ethtool.c
@@ -1704,6 +1712,9 @@ static inline int ethtool_validate_duplex(__u8 duplex) · 1443 unmodified lines
1704#define ETH_MODULE_SFF_8436 0x41712#define ETH_MODULE_SFF_8436 0x4
1705#define ETH_MODULE_SFF_8436_LEN 2561713#define ETH_MODULE_SFF_8436_LEN 256
1706 1714
1715#define ETH_MODULE_SFF_8636_MAX_LEN 640
1716#define ETH_MODULE_SFF_8436_MAX_LEN 640
1717
1707/* Reset flags */1718/* Reset flags */
1708/* The reset() operation must clear the flags for the components which1719/* The reset() operation must clear the flags for the components which
1709 * were actually reset. On successful return, the flags indicate the1720 * were actually reset. On successful return, the flags indicate the
include/uapi/linux/fcntl.h+2−0
@@ -91,5 +91,7 @@ · 90 unmodified lines
91#define AT_STATX_FORCE_SYNC 0x2000 /* - Force the attributes to be sync'd with the server */91#define AT_STATX_FORCE_SYNC 0x2000 /* - Force the attributes to be sync'd with the server */
92#define AT_STATX_DONT_SYNC 0x4000 /* - Don't sync attributes with the server */92#define AT_STATX_DONT_SYNC 0x4000 /* - Don't sync attributes with the server */
93 93
94#define AT_RECURSIVE 0x8000 /* Apply to the entire subtree */
95
94 96
95#endif /* _UAPI_LINUX_FCNTL_H */97#endif /* _UAPI_LINUX_FCNTL_H */
include/uapi/linux/fou.h+6−0
@@ -16,6 +16,12 @@ enum { · 15 unmodified lines
16 FOU_ATTR_IPPROTO, /* u8 */16 FOU_ATTR_IPPROTO, /* u8 */
17 FOU_ATTR_TYPE, /* u8 */17 FOU_ATTR_TYPE, /* u8 */
18 FOU_ATTR_REMCSUM_NOPARTIAL, /* flag */18 FOU_ATTR_REMCSUM_NOPARTIAL, /* flag */
19 FOU_ATTR_LOCAL_V4, /* u32 */
20 FOU_ATTR_LOCAL_V6, /* in6_addr */
21 FOU_ATTR_PEER_V4, /* u32 */
22 FOU_ATTR_PEER_V6, /* in6_addr */
23 FOU_ATTR_PEER_PORT, /* u16 */
24 FOU_ATTR_IFINDEX, /* s32 */
19 25
20 __FOU_ATTR_MAX,26 __FOU_ATTR_MAX,
21};27};
include/uapi/linux/fs.h+3−0
@@ -320,6 +320,9 @@ struct fscrypt_key { · 319 unmodified lines
320#define SYNC_FILE_RANGE_WAIT_BEFORE 1320#define SYNC_FILE_RANGE_WAIT_BEFORE 1
321#define SYNC_FILE_RANGE_WRITE 2321#define SYNC_FILE_RANGE_WRITE 2
322#define SYNC_FILE_RANGE_WAIT_AFTER 4322#define SYNC_FILE_RANGE_WAIT_AFTER 4
323#define SYNC_FILE_RANGE_WRITE_AND_WAIT (SYNC_FILE_RANGE_WRITE | \
324 SYNC_FILE_RANGE_WAIT_BEFORE | \
325 SYNC_FILE_RANGE_WAIT_AFTER)
323 326
324/*327/*
325 * Flags for preadv2/pwritev2:328 * Flags for preadv2/pwritev2:
include/uapi/linux/fuse.h+20−2
@@ -44,6 +44,7 @@ · 43 unmodified lines
44 * - add lock_owner field to fuse_setattr_in, fuse_read_in and fuse_write_in44 * - add lock_owner field to fuse_setattr_in, fuse_read_in and fuse_write_in
45 * - add blksize field to fuse_attr45 * - add blksize field to fuse_attr
46 * - add file flags field to fuse_read_in and fuse_write_in46 * - add file flags field to fuse_read_in and fuse_write_in
47 * - Add ATIME_NOW and MTIME_NOW flags to fuse_setattr_in
47 *48 *
48 * 7.1049 * 7.10
49 * - add nonseekable open flag50 * - add nonseekable open flag
@@ -54,7 +55,7 @@ · 4 unmodified lines
54 * - add POLL message and NOTIFY_POLL notification55 * - add POLL message and NOTIFY_POLL notification
55 *56 *
56 * 7.1257 * 7.12
57 * - add umask flag to input argument of open, mknod and mkdir58 * - add umask flag to input argument of create, mknod and mkdir
58 * - add notification messages for invalidation of inodes and59 * - add notification messages for invalidation of inodes and
59 * directory entries60 * directory entries
60 *61 *
@@ -125,6 +126,10 @@ · 64 unmodified lines
125 *126 *
126 * 7.29127 * 7.29
127 * - add FUSE_NO_OPENDIR_SUPPORT flag128 * - add FUSE_NO_OPENDIR_SUPPORT flag
129 *
130 * 7.30
131 * - add FUSE_EXPLICIT_INVAL_DATA
132 * - add FUSE_IOCTL_COMPAT_X32
128 */133 */
129 134
130#ifndef _LINUX_FUSE_H135#ifndef _LINUX_FUSE_H
@@ -160,7 +165,7 @@ · 29 unmodified lines
160#define FUSE_KERNEL_VERSION 7165#define FUSE_KERNEL_VERSION 7
161 166
162/** Minor version number of this interface */167/** Minor version number of this interface */
163#define FUSE_KERNEL_MINOR_VERSION 29168#define FUSE_KERNEL_MINOR_VERSION 30
164 169
165/** The node ID of the root inode */170/** The node ID of the root inode */
166#define FUSE_ROOT_ID 1171#define FUSE_ROOT_ID 1
@@ -229,11 +234,13 @@ struct fuse_file_lock { · 62 unmodified lines
229 * FOPEN_KEEP_CACHE: don't invalidate the data cache on open234 * FOPEN_KEEP_CACHE: don't invalidate the data cache on open
230 * FOPEN_NONSEEKABLE: the file is not seekable235 * FOPEN_NONSEEKABLE: the file is not seekable
231 * FOPEN_CACHE_DIR: allow caching this directory236 * FOPEN_CACHE_DIR: allow caching this directory
237 * FOPEN_STREAM: the file is stream-like (no file position at all)
232 */238 */
233#define FOPEN_DIRECT_IO (1 << 0)239#define FOPEN_DIRECT_IO (1 << 0)
234#define FOPEN_KEEP_CACHE (1 << 1)240#define FOPEN_KEEP_CACHE (1 << 1)
235#define FOPEN_NONSEEKABLE (1 << 2)241#define FOPEN_NONSEEKABLE (1 << 2)
236#define FOPEN_CACHE_DIR (1 << 3)242#define FOPEN_CACHE_DIR (1 << 3)
243#define FOPEN_STREAM (1 << 4)
237 244
238/**245/**
239 * INIT request/reply flags246 * INIT request/reply flags
@@ -263,6 +270,7 @@ struct fuse_file_lock { · 23 unmodified lines
263 * FUSE_MAX_PAGES: init_out.max_pages contains the max number of req pages270 * FUSE_MAX_PAGES: init_out.max_pages contains the max number of req pages
264 * FUSE_CACHE_SYMLINKS: cache READLINK responses271 * FUSE_CACHE_SYMLINKS: cache READLINK responses
265 * FUSE_NO_OPENDIR_SUPPORT: kernel supports zero-message opendir272 * FUSE_NO_OPENDIR_SUPPORT: kernel supports zero-message opendir
273 * FUSE_EXPLICIT_INVAL_DATA: only invalidate cached pages on explicit request
266 */274 */
267#define FUSE_ASYNC_READ (1 << 0)275#define FUSE_ASYNC_READ (1 << 0)
268#define FUSE_POSIX_LOCKS (1 << 1)276#define FUSE_POSIX_LOCKS (1 << 1)
@@ -289,6 +297,7 @@ struct fuse_file_lock { · 20 unmodified lines
289#define FUSE_MAX_PAGES (1 << 22)297#define FUSE_MAX_PAGES (1 << 22)
290#define FUSE_CACHE_SYMLINKS (1 << 23)298#define FUSE_CACHE_SYMLINKS (1 << 23)
291#define FUSE_NO_OPENDIR_SUPPORT (1 << 24)299#define FUSE_NO_OPENDIR_SUPPORT (1 << 24)
300#define FUSE_EXPLICIT_INVAL_DATA (1 << 25)
292 301
293/**302/**
294 * CUSE INIT request/reply flags303 * CUSE INIT request/reply flags
@@ -335,6 +344,7 @@ struct fuse_file_lock { · 40 unmodified lines
335 * FUSE_IOCTL_RETRY: retry with new iovecs344 * FUSE_IOCTL_RETRY: retry with new iovecs
336 * FUSE_IOCTL_32BIT: 32bit ioctl345 * FUSE_IOCTL_32BIT: 32bit ioctl
337 * FUSE_IOCTL_DIR: is a directory346 * FUSE_IOCTL_DIR: is a directory
347 * FUSE_IOCTL_COMPAT_X32: x32 compat ioctl on 64bit machine (64bit time_t)
338 *348 *
339 * FUSE_IOCTL_MAX_IOV: maximum of in_iovecs + out_iovecs349 * FUSE_IOCTL_MAX_IOV: maximum of in_iovecs + out_iovecs
340 */350 */
@@ -343,6 +353,7 @@ struct fuse_file_lock { · 2 unmodified lines
343#define FUSE_IOCTL_RETRY (1 << 2)353#define FUSE_IOCTL_RETRY (1 << 2)
344#define FUSE_IOCTL_32BIT (1 << 3)354#define FUSE_IOCTL_32BIT (1 << 3)
345#define FUSE_IOCTL_DIR (1 << 4)355#define FUSE_IOCTL_DIR (1 << 4)
356#define FUSE_IOCTL_COMPAT_X32 (1 << 5)
346 357
347#define FUSE_IOCTL_MAX_IOV 256358#define FUSE_IOCTL_MAX_IOV 256
348 359
@@ -353,6 +364,13 @@ struct fuse_file_lock { · 4 unmodified lines
353 */364 */
354#define FUSE_POLL_SCHEDULE_NOTIFY (1 << 0)365#define FUSE_POLL_SCHEDULE_NOTIFY (1 << 0)
355 366
367/**
368 * Fsync flags
369 *
370 * FUSE_FSYNC_FDATASYNC: Sync data only, not metadata
371 */
372#define FUSE_FSYNC_FDATASYNC (1 << 0)
373
356enum fuse_opcode {374enum fuse_opcode {
357 FUSE_LOOKUP = 1,375 FUSE_LOOKUP = 1,
358 FUSE_FORGET = 2, /* no reply */376 FUSE_FORGET = 2, /* no reply */
include/uapi/linux/icmpv6.h+4−0
@@ -90,6 +90,8 @@ struct icmp6hdr { · 89 unmodified lines
90#define ICMPV6_TIME_EXCEED 390#define ICMPV6_TIME_EXCEED 3
91#define ICMPV6_PARAMPROB 491#define ICMPV6_PARAMPROB 4
92 92
93#define ICMPV6_ERRMSG_MAX 127
94
93#define ICMPV6_INFOMSG_MASK 0x8095#define ICMPV6_INFOMSG_MASK 0x80
94 96
95#define ICMPV6_ECHO_REQUEST 12897#define ICMPV6_ECHO_REQUEST 128
@@ -110,6 +112,8 @@ struct icmp6hdr { · 14 unmodified lines
110 112
111#define ICMPV6_MRDISC_ADV 151113#define ICMPV6_MRDISC_ADV 151
112 114
115#define ICMPV6_MSG_MAX 255
116
113/*117/*
114 * Codes for Destination Unreachable118 * Codes for Destination Unreachable
115 */119 */
include/uapi/linux/if_ether.h+1−0
@@ -109,6 +109,7 @@ · 108 unmodified lines
109#define ETH_P_QINQ2 0x9200 /* deprecated QinQ VLAN [ NOT AN OFFICIALLY REGISTERED ID ] */109#define ETH_P_QINQ2 0x9200 /* deprecated QinQ VLAN [ NOT AN OFFICIALLY REGISTERED ID ] */
110#define ETH_P_QINQ3 0x9300 /* deprecated QinQ VLAN [ NOT AN OFFICIALLY REGISTERED ID ] */110#define ETH_P_QINQ3 0x9300 /* deprecated QinQ VLAN [ NOT AN OFFICIALLY REGISTERED ID ] */
111#define ETH_P_EDSA 0xDADA /* Ethertype DSA [ NOT AN OFFICIALLY REGISTERED ID ] */111#define ETH_P_EDSA 0xDADA /* Ethertype DSA [ NOT AN OFFICIALLY REGISTERED ID ] */
112#define ETH_P_DSA_8021Q 0xDADB /* Fake VLAN Header for DSA [ NOT AN OFFICIALLY REGISTERED ID ] */
112#define ETH_P_IFE 0xED3E /* ForCES inter-FE LFB type */113#define ETH_P_IFE 0xED3E /* ForCES inter-FE LFB type */
113#define ETH_P_AF_IUCV 0xFBFB /* IBM af_iucv [ NOT AN OFFICIALLY REGISTERED ID ] */114#define ETH_P_AF_IUCV 0xFBFB /* IBM af_iucv [ NOT AN OFFICIALLY REGISTERED ID ] */
114 115
include/uapi/linux/if_tun.h+1−0
@@ -60,6 +60,7 @@ · 59 unmodified lines
60#define TUNSETSTEERINGEBPF _IOR('T', 224, int)60#define TUNSETSTEERINGEBPF _IOR('T', 224, int)
61#define TUNSETFILTEREBPF _IOR('T', 225, int)61#define TUNSETFILTEREBPF _IOR('T', 225, int)
62#define TUNSETCARRIER _IOW('T', 226, int)62#define TUNSETCARRIER _IOW('T', 226, int)
63#define TUNGETDEVNETNS _IO('T', 227)
63 64
64/* TUNSETIFF ifr flags */65/* TUNSETIFF ifr flags */
65#define IFF_TUN 0x000166#define IFF_TUN 0x0001
include/uapi/linux/if_vlan.h+5−4
@@ -32,10 +32,11 @@ enum vlan_ioctl_cmds { · 31 unmodified lines
32};32};
33 33
34enum vlan_flags {34enum vlan_flags {
35 VLAN_FLAG_REORDER_HDR = 0x1,35 VLAN_FLAG_REORDER_HDR = 0x1,
36 VLAN_FLAG_GVRP = 0x2,36 VLAN_FLAG_GVRP = 0x2,
37 VLAN_FLAG_LOOSE_BINDING = 0x4,37 VLAN_FLAG_LOOSE_BINDING = 0x4,
38 VLAN_FLAG_MVRP = 0x8,38 VLAN_FLAG_MVRP = 0x8,
39 VLAN_FLAG_BRIDGE_BINDING = 0x10,
39};40};
40 41
41enum vlan_name_types {42enum vlan_name_types {
include/uapi/linux/input-event-codes.h+5−2
@@ -439,10 +439,12 @@ · 438 unmodified lines
439#define KEY_TITLE 0x171439#define KEY_TITLE 0x171
440#define KEY_SUBTITLE 0x172440#define KEY_SUBTITLE 0x172
441#define KEY_ANGLE 0x173441#define KEY_ANGLE 0x173
442#define KEY_ZOOM 0x174442#define KEY_FULL_SCREEN 0x174 /* AC View Toggle */
443#define KEY_ZOOM KEY_FULL_SCREEN
443#define KEY_MODE 0x175444#define KEY_MODE 0x175
444#define KEY_KEYBOARD 0x176445#define KEY_KEYBOARD 0x176
445#define KEY_SCREEN 0x177446#define KEY_ASPECT_RATIO 0x177 /* HUTRR37: Aspect */
447#define KEY_SCREEN KEY_ASPECT_RATIO
446#define KEY_PC 0x178 /* Media Select Computer */448#define KEY_PC 0x178 /* Media Select Computer */
447#define KEY_TV 0x179 /* Media Select TV */449#define KEY_TV 0x179 /* Media Select TV */
448#define KEY_TV2 0x17a /* Media Select Cable */450#define KEY_TV2 0x17a /* Media Select Cable */
@@ -604,6 +606,7 @@ · 155 unmodified lines
604#define KEY_SCREENSAVER 0x245 /* AL Screen Saver */606#define KEY_SCREENSAVER 0x245 /* AL Screen Saver */
605#define KEY_VOICECOMMAND 0x246 /* Listening Voice Command */607#define KEY_VOICECOMMAND 0x246 /* Listening Voice Command */
606#define KEY_ASSISTANT 0x247 /* AL Context-aware desktop assistant */608#define KEY_ASSISTANT 0x247 /* AL Context-aware desktop assistant */
609#define KEY_KBD_LAYOUT_NEXT 0x248 /* AC Next Keyboard Layout Select */
607 610
608#define KEY_BRIGHTNESS_MIN 0x250 /* Set Brightness to Minimum */611#define KEY_BRIGHTNESS_MIN 0x250 /* Set Brightness to Minimum */
609#define KEY_BRIGHTNESS_MAX 0x251 /* Set Brightness to Maximum */612#define KEY_BRIGHTNESS_MAX 0x251 /* Set Brightness to Maximum */
include/uapi/linux/io_uring.h+5−0
@@ -26,6 +26,7 @@ struct io_uring_sqe { · 25 unmodified lines
26 __kernel_rwf_t rw_flags;26 __kernel_rwf_t rw_flags;
27 __u32 fsync_flags;27 __u32 fsync_flags;
28 __u16 poll_events;28 __u16 poll_events;
29 __u32 sync_range_flags;
29 };30 };
30 __u64 user_data; /* data to be passed back at completion time */31 __u64 user_data; /* data to be passed back at completion time */
31 union {32 union {
@@ -38,6 +39,7 @@ struct io_uring_sqe { · 6 unmodified lines
38 * sqe->flags39 * sqe->flags
39 */40 */
40#define IOSQE_FIXED_FILE (1U << 0) /* use fixed fileset */41#define IOSQE_FIXED_FILE (1U << 0) /* use fixed fileset */
42#define IOSQE_IO_DRAIN (1U << 1) /* issue after inflight IO */
41 43
42/*44/*
43 * io_uring_setup() flags45 * io_uring_setup() flags
@@ -54,6 +56,7 @@ struct io_uring_sqe { · 10 unmodified lines
54#define IORING_OP_WRITE_FIXED 556#define IORING_OP_WRITE_FIXED 5
55#define IORING_OP_POLL_ADD 657#define IORING_OP_POLL_ADD 6
56#define IORING_OP_POLL_REMOVE 758#define IORING_OP_POLL_REMOVE 7
59#define IORING_OP_SYNC_FILE_RANGE 8
57 60
58/*61/*
59 * sqe->fsync_flags62 * sqe->fsync_flags
@@ -133,5 +136,7 @@ struct io_uring_params { · 73 unmodified lines
133#define IORING_UNREGISTER_BUFFERS 1136#define IORING_UNREGISTER_BUFFERS 1
134#define IORING_REGISTER_FILES 2137#define IORING_REGISTER_FILES 2
135#define IORING_UNREGISTER_FILES 3138#define IORING_UNREGISTER_FILES 3
139#define IORING_REGISTER_EVENTFD 4
140#define IORING_UNREGISTER_EVENTFD 5
136 141
137#endif142#endif
include/uapi/linux/ip_vs.h+11−0
@@ -124,6 +124,13 @@ · 123 unmodified lines
124 124
125#define IP_VS_PEDATA_MAXLEN 255125#define IP_VS_PEDATA_MAXLEN 255
126 126
127/* Tunnel types */
128enum {
129 IP_VS_CONN_F_TUNNEL_TYPE_IPIP = 0, /* IPIP */
130 IP_VS_CONN_F_TUNNEL_TYPE_GUE, /* GUE */
131 IP_VS_CONN_F_TUNNEL_TYPE_MAX,
132};
133
127/*134/*
128 * The struct ip_vs_service_user and struct ip_vs_dest_user are135 * The struct ip_vs_service_user and struct ip_vs_dest_user are
129 * used to set IPVS rules through setsockopt.136 * used to set IPVS rules through setsockopt.
@@ -392,6 +399,10 @@ enum { · 262 unmodified lines
392 399
393 IPVS_DEST_ATTR_STATS64, /* nested attribute for dest stats */400 IPVS_DEST_ATTR_STATS64, /* nested attribute for dest stats */
394 401
402 IPVS_DEST_ATTR_TUN_TYPE, /* tunnel type */
403
404 IPVS_DEST_ATTR_TUN_PORT, /* tunnel port */
405
395 __IPVS_DEST_ATTR_MAX,406 __IPVS_DEST_ATTR_MAX,
396};407};
397 408
include/uapi/linux/kvm.h+13−2
@@ -986,8 +986,13 @@ struct kvm_ppc_resize_hpt { · 985 unmodified lines
986#define KVM_CAP_HYPERV_ENLIGHTENED_VMCS 163986#define KVM_CAP_HYPERV_ENLIGHTENED_VMCS 163
987#define KVM_CAP_EXCEPTION_PAYLOAD 164987#define KVM_CAP_EXCEPTION_PAYLOAD 164
988#define KVM_CAP_ARM_VM_IPA_SIZE 165988#define KVM_CAP_ARM_VM_IPA_SIZE 165
989#define KVM_CAP_MANUAL_DIRTY_LOG_PROTECT 166989#define KVM_CAP_MANUAL_DIRTY_LOG_PROTECT 166 /* Obsolete */
990#define KVM_CAP_HYPERV_CPUID 167990#define KVM_CAP_HYPERV_CPUID 167
991#define KVM_CAP_MANUAL_DIRTY_LOG_PROTECT2 168
992#define KVM_CAP_PPC_IRQ_XIVE 169
993#define KVM_CAP_ARM_SVE 170
994#define KVM_CAP_ARM_PTRAUTH_ADDRESS 171
995#define KVM_CAP_ARM_PTRAUTH_GENERIC 172
991 996
992#ifdef KVM_CAP_IRQ_ROUTING997#ifdef KVM_CAP_IRQ_ROUTING
993 998
@@ -1145,6 +1150,7 @@ struct kvm_dirty_tlb { · 151 unmodified lines
1145#define KVM_REG_SIZE_U256 0x0050000000000000ULL1150#define KVM_REG_SIZE_U256 0x0050000000000000ULL
1146#define KVM_REG_SIZE_U512 0x0060000000000000ULL1151#define KVM_REG_SIZE_U512 0x0060000000000000ULL
1147#define KVM_REG_SIZE_U1024 0x0070000000000000ULL1152#define KVM_REG_SIZE_U1024 0x0070000000000000ULL
1153#define KVM_REG_SIZE_U2048 0x0080000000000000ULL
1148 1154
1149struct kvm_reg_list {1155struct kvm_reg_list {
1150 __u64 n; /* number of regs */1156 __u64 n; /* number of regs */
@@ -1211,6 +1217,8 @@ enum kvm_device_type { · 60 unmodified lines
1211#define KVM_DEV_TYPE_ARM_VGIC_V3 KVM_DEV_TYPE_ARM_VGIC_V31217#define KVM_DEV_TYPE_ARM_VGIC_V3 KVM_DEV_TYPE_ARM_VGIC_V3
1212 KVM_DEV_TYPE_ARM_VGIC_ITS,1218 KVM_DEV_TYPE_ARM_VGIC_ITS,
1213#define KVM_DEV_TYPE_ARM_VGIC_ITS KVM_DEV_TYPE_ARM_VGIC_ITS1219#define KVM_DEV_TYPE_ARM_VGIC_ITS KVM_DEV_TYPE_ARM_VGIC_ITS
1220 KVM_DEV_TYPE_XIVE,
1221#define KVM_DEV_TYPE_XIVE KVM_DEV_TYPE_XIVE
1214 KVM_DEV_TYPE_MAX,1222 KVM_DEV_TYPE_MAX,
1215};1223};
1216 1224
@@ -1434,12 +1442,15 @@ struct kvm_enc_region { · 217 unmodified lines
1434#define KVM_GET_NESTED_STATE _IOWR(KVMIO, 0xbe, struct kvm_nested_state)1442#define KVM_GET_NESTED_STATE _IOWR(KVMIO, 0xbe, struct kvm_nested_state)
1435#define KVM_SET_NESTED_STATE _IOW(KVMIO, 0xbf, struct kvm_nested_state)1443#define KVM_SET_NESTED_STATE _IOW(KVMIO, 0xbf, struct kvm_nested_state)
1436 1444
1437/* Available with KVM_CAP_MANUAL_DIRTY_LOG_PROTECT */1445/* Available with KVM_CAP_MANUAL_DIRTY_LOG_PROTECT_2 */
1438#define KVM_CLEAR_DIRTY_LOG _IOWR(KVMIO, 0xc0, struct kvm_clear_dirty_log)1446#define KVM_CLEAR_DIRTY_LOG _IOWR(KVMIO, 0xc0, struct kvm_clear_dirty_log)
1439 1447
1440/* Available with KVM_CAP_HYPERV_CPUID */1448/* Available with KVM_CAP_HYPERV_CPUID */
1441#define KVM_GET_SUPPORTED_HV_CPUID _IOWR(KVMIO, 0xc1, struct kvm_cpuid2)1449#define KVM_GET_SUPPORTED_HV_CPUID _IOWR(KVMIO, 0xc1, struct kvm_cpuid2)
1442 1450
1451/* Available with KVM_CAP_ARM_SVE */
1452#define KVM_ARM_VCPU_FINALIZE _IOW(KVMIO, 0xc2, int)
1453
1443/* Secure Encrypted Virtualization command */1454/* Secure Encrypted Virtualization command */
1444enum sev_cmd_id {1455enum sev_cmd_id {
1445 /* Guest initialization commands */1456 /* Guest initialization commands */
include/uapi/linux/lirc.h+2−0
@@ -195,6 +195,7 @@ struct lirc_scancode { · 194 unmodified lines
195 * @RC_PROTO_RCMM12: RC-MM protocol 12 bits195 * @RC_PROTO_RCMM12: RC-MM protocol 12 bits
196 * @RC_PROTO_RCMM24: RC-MM protocol 24 bits196 * @RC_PROTO_RCMM24: RC-MM protocol 24 bits
197 * @RC_PROTO_RCMM32: RC-MM protocol 32 bits197 * @RC_PROTO_RCMM32: RC-MM protocol 32 bits
198 * @RC_PROTO_XBOX_DVD: Xbox DVD Movie Playback Kit protocol
198 */199 */
199enum rc_proto {200enum rc_proto {
200 RC_PROTO_UNKNOWN = 0,201 RC_PROTO_UNKNOWN = 0,
@@ -224,6 +225,7 @@ enum rc_proto { · 23 unmodified lines
224 RC_PROTO_RCMM12 = 24,225 RC_PROTO_RCMM12 = 24,
225 RC_PROTO_RCMM24 = 25,226 RC_PROTO_RCMM24 = 25,
226 RC_PROTO_RCMM32 = 26,227 RC_PROTO_RCMM32 = 26,
228 RC_PROTO_XBOX_DVD = 27,
227};229};
228 230
229#endif231#endif
include/uapi/linux/media-bus-format.h+2−1
@@ -34,7 +34,7 @@ · 33 unmodified lines
34 34
35#define MEDIA_BUS_FMT_FIXED 0x000135#define MEDIA_BUS_FMT_FIXED 0x0001
36 36
37/* RGB - next is 0x101b */37/* RGB - next is 0x101c */
38#define MEDIA_BUS_FMT_RGB444_1X12 0x101638#define MEDIA_BUS_FMT_RGB444_1X12 0x1016
39#define MEDIA_BUS_FMT_RGB444_2X8_PADHI_BE 0x100139#define MEDIA_BUS_FMT_RGB444_2X8_PADHI_BE 0x1001
40#define MEDIA_BUS_FMT_RGB444_2X8_PADHI_LE 0x100240#define MEDIA_BUS_FMT_RGB444_2X8_PADHI_LE 0x1002
@@ -50,6 +50,7 @@ · 9 unmodified lines
50#define MEDIA_BUS_FMT_RGB666_1X24_CPADHI 0x101550#define MEDIA_BUS_FMT_RGB666_1X24_CPADHI 0x1015
51#define MEDIA_BUS_FMT_RGB666_1X7X3_SPWG 0x101051#define MEDIA_BUS_FMT_RGB666_1X7X3_SPWG 0x1010
52#define MEDIA_BUS_FMT_BGR888_1X24 0x101352#define MEDIA_BUS_FMT_BGR888_1X24 0x1013
53#define MEDIA_BUS_FMT_BGR888_3X8 0x101b
53#define MEDIA_BUS_FMT_GBR888_1X24 0x101454#define MEDIA_BUS_FMT_GBR888_1X24 0x1014
54#define MEDIA_BUS_FMT_RGB888_1X24 0x100a55#define MEDIA_BUS_FMT_RGB888_1X24 0x100a
55#define MEDIA_BUS_FMT_RGB888_2X12_BE 0x100b56#define MEDIA_BUS_FMT_RGB888_2X12_BE 0x100b
include/uapi/linux/media.h+15−10
@@ -262,6 +262,11 @@ struct media_links_enum { · 261 unmodified lines
262#define MEDIA_INTF_T_V4L_SWRADIO (MEDIA_INTF_T_V4L_BASE + 4)262#define MEDIA_INTF_T_V4L_SWRADIO (MEDIA_INTF_T_V4L_BASE + 4)
263#define MEDIA_INTF_T_V4L_TOUCH (MEDIA_INTF_T_V4L_BASE + 5)263#define MEDIA_INTF_T_V4L_TOUCH (MEDIA_INTF_T_V4L_BASE + 5)
264 264
265#define MEDIA_INTF_T_ALSA_BASE 0x00000300
266#define MEDIA_INTF_T_ALSA_PCM_CAPTURE (MEDIA_INTF_T_ALSA_BASE)
267#define MEDIA_INTF_T_ALSA_PCM_PLAYBACK (MEDIA_INTF_T_ALSA_BASE + 1)
268#define MEDIA_INTF_T_ALSA_CONTROL (MEDIA_INTF_T_ALSA_BASE + 2)
269
265#if defined(__KERNEL__)270#if defined(__KERNEL__)
266 271
267/*272/*
@@ -413,19 +418,19 @@ struct media_v2_topology { · 145 unmodified lines
413#define MEDIA_ENT_F_DTV_DECODER MEDIA_ENT_F_DV_DECODER418#define MEDIA_ENT_F_DTV_DECODER MEDIA_ENT_F_DV_DECODER
414 419
415/*420/*
416 * There is still no ALSA support in the media controller. These421 * There is still no full ALSA support in the media controller. These
417 * defines should not have been added and we leave them here only422 * defines should not have been added and we leave them here only
418 * in case some application tries to use these defines.423 * in case some application tries to use these defines.
424 *
425 * The ALSA defines that are in use have been moved into __KERNEL__
426 * scope. As support gets added to these interface types, they should
427 * be moved into __KERNEL__ scope with the code that uses them.
419 */428 */
420#define MEDIA_INTF_T_ALSA_BASE 0x00000300429#define MEDIA_INTF_T_ALSA_COMPRESS (MEDIA_INTF_T_ALSA_BASE + 3)
421#define MEDIA_INTF_T_ALSA_PCM_CAPTURE (MEDIA_INTF_T_ALSA_BASE)430#define MEDIA_INTF_T_ALSA_RAWMIDI (MEDIA_INTF_T_ALSA_BASE + 4)
422#define MEDIA_INTF_T_ALSA_PCM_PLAYBACK (MEDIA_INTF_T_ALSA_BASE + 1)431#define MEDIA_INTF_T_ALSA_HWDEP (MEDIA_INTF_T_ALSA_BASE + 5)
423#define MEDIA_INTF_T_ALSA_CONTROL (MEDIA_INTF_T_ALSA_BASE + 2)432#define MEDIA_INTF_T_ALSA_SEQUENCER (MEDIA_INTF_T_ALSA_BASE + 6)
424#define MEDIA_INTF_T_ALSA_COMPRESS (MEDIA_INTF_T_ALSA_BASE + 3)433#define MEDIA_INTF_T_ALSA_TIMER (MEDIA_INTF_T_ALSA_BASE + 7)
425#define MEDIA_INTF_T_ALSA_RAWMIDI (MEDIA_INTF_T_ALSA_BASE + 4)
426#define MEDIA_INTF_T_ALSA_HWDEP (MEDIA_INTF_T_ALSA_BASE + 5)
427#define MEDIA_INTF_T_ALSA_SEQUENCER (MEDIA_INTF_T_ALSA_BASE + 6)
428#define MEDIA_INTF_T_ALSA_TIMER (MEDIA_INTF_T_ALSA_BASE + 7)
429 434
430/* Obsolete symbol for media_version, no longer used in the kernel */435/* Obsolete symbol for media_version, no longer used in the kernel */
431#define MEDIA_API_VERSION ((0 << 16) | (1 << 8) | 0)436#define MEDIA_API_VERSION ((0 << 16) | (1 << 8) | 0)
include/uapi/linux/mei.h+3−64
@@ -1,70 +1,9 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/******************************************************************************2/*
3 * Copyright(c) 2003-2015 Intel Corporation. All rights reserved.
3 * Intel Management Engine Interface (Intel MEI) Linux driver4 * Intel Management Engine Interface (Intel MEI) Linux driver
4 * Intel MEI Interface Header5 * Intel MEI Interface Header
5 *6 */
6 * This file is provided under a dual BSD/GPLv2 license. When using or
7 * redistributing this file, you may do so under either license.
8 *
9 * GPL LICENSE SUMMARY
10 *
11 * Copyright(c) 2003 - 2012 Intel Corporation. All rights reserved.
12 *
13 * This program is free software; you can redistribute it and/or modify
14 * it under the terms of version 2 of the GNU General Public License as
15 * published by the Free Software Foundation.
16 *
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110,
25 * USA
26 *
27 * The full GNU General Public License is included in this distribution
28 * in the file called LICENSE.GPL.
29 *
30 * Contact Information:
31 * Intel Corporation.
32 * linux-mei@linux.intel.com
33 * http://www.intel.com
34 *
35 * BSD LICENSE
36 *
37 * Copyright(c) 2003 - 2012 Intel Corporation. All rights reserved.
38 * All rights reserved.
39 *
40 * Redistribution and use in source and binary forms, with or without
41 * modification, are permitted provided that the following conditions
42 * are met:
43 *
44 * * Redistributions of source code must retain the above copyright
45 * notice, this list of conditions and the following disclaimer.
46 * * Redistributions in binary form must reproduce the above copyright
47 * notice, this list of conditions and the following disclaimer in
48 * the documentation and/or other materials provided with the
49 * distribution.
50 * * Neither the name Intel Corporation nor the names of its
51 * contributors may be used to endorse or promote products derived
52 * from this software without specific prior written permission.
53 *
54 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
55 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
56 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
57 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
58 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
59 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
60 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
61 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
62 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
63 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
64 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
65 *
66 *****************************************************************************/
67
68#ifndef _LINUX_MEI_H7#ifndef _LINUX_MEI_H
69#define _LINUX_MEI_H8#define _LINUX_MEI_H
70 9
include/uapi/linux/mount.h+62−0
@@ -55,4 +55,66 @@ · 54 unmodified lines
55#define MS_MGC_VAL 0xC0ED000055#define MS_MGC_VAL 0xC0ED0000
56#define MS_MGC_MSK 0xffff000056#define MS_MGC_MSK 0xffff0000
57 57
58/*
59 * open_tree() flags.
60 */
61#define OPEN_TREE_CLONE 1 /* Clone the target tree and attach the clone */
62#define OPEN_TREE_CLOEXEC O_CLOEXEC /* Close the file on execve() */
63
64/*
65 * move_mount() flags.
66 */
67#define MOVE_MOUNT_F_SYMLINKS 0x00000001 /* Follow symlinks on from path */
68#define MOVE_MOUNT_F_AUTOMOUNTS 0x00000002 /* Follow automounts on from path */
69#define MOVE_MOUNT_F_EMPTY_PATH 0x00000004 /* Empty from path permitted */
70#define MOVE_MOUNT_T_SYMLINKS 0x00000010 /* Follow symlinks on to path */
71#define MOVE_MOUNT_T_AUTOMOUNTS 0x00000020 /* Follow automounts on to path */
72#define MOVE_MOUNT_T_EMPTY_PATH 0x00000040 /* Empty to path permitted */
73#define MOVE_MOUNT__MASK 0x00000077
74
75/*
76 * fsopen() flags.
77 */
78#define FSOPEN_CLOEXEC 0x00000001
79
80/*
81 * fspick() flags.
82 */
83#define FSPICK_CLOEXEC 0x00000001
84#define FSPICK_SYMLINK_NOFOLLOW 0x00000002
85#define FSPICK_NO_AUTOMOUNT 0x00000004
86#define FSPICK_EMPTY_PATH 0x00000008
87
88/*
89 * The type of fsconfig() call made.
90 */
91enum fsconfig_command {
92 FSCONFIG_SET_FLAG = 0, /* Set parameter, supplying no value */
93 FSCONFIG_SET_STRING = 1, /* Set parameter, supplying a string value */
94 FSCONFIG_SET_BINARY = 2, /* Set parameter, supplying a binary blob value */
95 FSCONFIG_SET_PATH = 3, /* Set parameter, supplying an object by path */
96 FSCONFIG_SET_PATH_EMPTY = 4, /* Set parameter, supplying an object by (empty) path */
97 FSCONFIG_SET_FD = 5, /* Set parameter, supplying an object by fd */
98 FSCONFIG_CMD_CREATE = 6, /* Invoke superblock creation */
99 FSCONFIG_CMD_RECONFIGURE = 7, /* Invoke superblock reconfiguration */
100};
101
102/*
103 * fsmount() flags.
104 */
105#define FSMOUNT_CLOEXEC 0x00000001
106
107/*
108 * Mount attributes.
109 */
110#define MOUNT_ATTR_RDONLY 0x00000001 /* Mount read-only */
111#define MOUNT_ATTR_NOSUID 0x00000002 /* Ignore suid and sgid bits */
112#define MOUNT_ATTR_NODEV 0x00000004 /* Disallow access to device special files */
113#define MOUNT_ATTR_NOEXEC 0x00000008 /* Disallow program execution */
114#define MOUNT_ATTR__ATIME 0x00000070 /* Setting on how atime should be updated */
115#define MOUNT_ATTR_RELATIME 0x00000000 /* - Update atime relative to mtime/ctime. */
116#define MOUNT_ATTR_NOATIME 0x00000010 /* - Do not update access times. */
117#define MOUNT_ATTR_STRICTATIME 0x00000020 /* - Always perform atime updates */
118#define MOUNT_ATTR_NODIRATIME 0x00000080 /* Do not update directory access times */
119
58#endif /* _UAPI_LINUX_MOUNT_H */120#endif /* _UAPI_LINUX_MOUNT_H */
include/uapi/linux/netfilter/nf_tables.h+9−3
@@ -966,7 +966,7 @@ enum nft_socket_keys { · 965 unmodified lines
966 * @NFT_CT_DST_IP: conntrack layer 3 protocol destination (IPv4 address)966 * @NFT_CT_DST_IP: conntrack layer 3 protocol destination (IPv4 address)
967 * @NFT_CT_SRC_IP6: conntrack layer 3 protocol source (IPv6 address)967 * @NFT_CT_SRC_IP6: conntrack layer 3 protocol source (IPv6 address)
968 * @NFT_CT_DST_IP6: conntrack layer 3 protocol destination (IPv6 address)968 * @NFT_CT_DST_IP6: conntrack layer 3 protocol destination (IPv6 address)
969 * @NFT_CT_TIMEOUT: connection tracking timeout policy assigned to conntrack969 * @NFT_CT_ID: conntrack id
970 */970 */
971enum nft_ct_keys {971enum nft_ct_keys {
972 NFT_CT_STATE,972 NFT_CT_STATE,
@@ -992,7 +992,7 @@ enum nft_ct_keys { · 19 unmodified lines
992 NFT_CT_DST_IP,992 NFT_CT_DST_IP,
993 NFT_CT_SRC_IP6,993 NFT_CT_SRC_IP6,
994 NFT_CT_DST_IP6,994 NFT_CT_DST_IP6,
995 NFT_CT_TIMEOUT,995 NFT_CT_ID,
996 __NFT_CT_MAX996 __NFT_CT_MAX
997};997};
998#define NFT_CT_MAX (__NFT_CT_MAX - 1)998#define NFT_CT_MAX (__NFT_CT_MAX - 1)
@@ -1136,7 +1136,7 @@ enum nft_log_level { · 137 unmodified lines
1136 NFT_LOGLEVEL_AUDIT,1136 NFT_LOGLEVEL_AUDIT,
1137 __NFT_LOGLEVEL_MAX1137 __NFT_LOGLEVEL_MAX
1138};1138};
1139#define NFT_LOGLEVEL_MAX (__NFT_LOGLEVEL_MAX + 1)1139#define NFT_LOGLEVEL_MAX (__NFT_LOGLEVEL_MAX - 1)
1140 1140
1141/**1141/**
1142 * enum nft_queue_attributes - nf_tables queue expression netlink attributes1142 * enum nft_queue_attributes - nf_tables queue expression netlink attributes
@@ -1522,15 +1522,21 @@ enum nft_flowtable_hook_attributes { · 379 unmodified lines
1522 *1522 *
1523 * @NFTA_OSF_DREG: destination register (NLA_U32: nft_registers)1523 * @NFTA_OSF_DREG: destination register (NLA_U32: nft_registers)
1524 * @NFTA_OSF_TTL: Value of the TTL osf option (NLA_U8)1524 * @NFTA_OSF_TTL: Value of the TTL osf option (NLA_U8)
1525 * @NFTA_OSF_FLAGS: flags (NLA_U32)
1525 */1526 */
1526enum nft_osf_attributes {1527enum nft_osf_attributes {
1527 NFTA_OSF_UNSPEC,1528 NFTA_OSF_UNSPEC,
1528 NFTA_OSF_DREG,1529 NFTA_OSF_DREG,
1529 NFTA_OSF_TTL,1530 NFTA_OSF_TTL,
1531 NFTA_OSF_FLAGS,
1530 __NFTA_OSF_MAX,1532 __NFTA_OSF_MAX,
1531};1533};
1532#define NFTA_OSF_MAX (__NFTA_OSF_MAX - 1)1534#define NFTA_OSF_MAX (__NFTA_OSF_MAX - 1)
1533 1535
1536enum nft_osf_flags {
1537 NFT_OSF_F_VERSION = (1 << 0),
1538};
1539
1534/**1540/**
1535 * enum nft_device_attributes - nf_tables device netlink attributes1541 * enum nft_device_attributes - nf_tables device netlink attributes
1536 *1542 *
include/uapi/linux/nfs_mount.h+0−9
@@ -66,13 +66,4 @@ struct nfs_mount_data { · 65 unmodified lines
66#define NFS_MOUNT_UNSHARED 0x8000 /* 5 */66#define NFS_MOUNT_UNSHARED 0x8000 /* 5 */
67#define NFS_MOUNT_FLAGMASK 0xFFFF67#define NFS_MOUNT_FLAGMASK 0xFFFF
68 68
69/* The following are for internal use only */
70#define NFS_MOUNT_LOOKUP_CACHE_NONEG 0x10000
71#define NFS_MOUNT_LOOKUP_CACHE_NONE 0x20000
72#define NFS_MOUNT_NORESVPORT 0x40000
73#define NFS_MOUNT_LEGACY_INTERFACE 0x80000
74
75#define NFS_MOUNT_LOCAL_FLOCK 0x100000
76#define NFS_MOUNT_LOCAL_FCNTL 0x200000
77
78#endif69#endif
include/uapi/linux/nfsd/cld.h+1−0
@@ -36,6 +36,7 @@ enum cld_command { · 35 unmodified lines
36 Cld_Remove, /* remove record of this cm_id */36 Cld_Remove, /* remove record of this cm_id */
37 Cld_Check, /* is this cm_id allowed? */37 Cld_Check, /* is this cm_id allowed? */
38 Cld_GraceDone, /* grace period is complete */38 Cld_GraceDone, /* grace period is complete */
39 Cld_GraceStart,
39};40};
40 41
41/* representation of long-form NFSv4 client ID */42/* representation of long-form NFSv4 client ID */
include/uapi/linux/nl80211.h+84−2
@@ -11,7 +11,7 @@ · 10 unmodified lines
11 * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com>11 * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com>
12 * Copyright 2008 Colin McCabe <colin@cozybit.com>12 * Copyright 2008 Colin McCabe <colin@cozybit.com>
13 * Copyright 2015-2017 Intel Deutschland GmbH13 * Copyright 2015-2017 Intel Deutschland GmbH
14 * Copyright (C) 2018 Intel Corporation14 * Copyright (C) 2018-2019 Intel Corporation
15 *15 *
16 * Permission to use, copy, modify, and/or distribute this software for any16 * Permission to use, copy, modify, and/or distribute this software for any
17 * purpose with or without fee is hereby granted, provided that the above17 * purpose with or without fee is hereby granted, provided that the above
@@ -1065,6 +1065,26 @@ · 1047 unmodified lines
1065 * indicated by %NL80211_ATTR_WIPHY_FREQ and other attributes1065 * indicated by %NL80211_ATTR_WIPHY_FREQ and other attributes
1066 * determining the width and type.1066 * determining the width and type.
1067 *1067 *
1068 * @NL80211_CMD_UPDATE_OWE_INFO: This interface allows the host driver to
1069 * offload OWE processing to user space. This intends to support
1070 * OWE AKM by the host drivers that implement SME but rely
1071 * on the user space for the cryptographic/DH IE processing in AP mode.
1072 *
1073 * @NL80211_CMD_PROBE_MESH_LINK: The requirement for mesh link metric
1074 * refreshing, is that from one mesh point we be able to send some data
1075 * frames to other mesh points which are not currently selected as a
1076 * primary traffic path, but which are only 1 hop away. The absence of
1077 * the primary path to the chosen node makes it necessary to apply some
1078 * form of marking on a chosen packet stream so that the packets can be
1079 * properly steered to the selected node for testing, and not by the
1080 * regular mesh path lookup. Further, the packets must be of type data
1081 * so that the rate control (often embedded in firmware) is used for
1082 * rate selection.
1083 *
1084 * Here attribute %NL80211_ATTR_MAC is used to specify connected mesh
1085 * peer MAC address and %NL80211_ATTR_FRAME is used to specify the frame
1086 * content. The frame is ethernet data.
1087 *
1068 * @NL80211_CMD_MAX: highest used command number1088 * @NL80211_CMD_MAX: highest used command number
1069 * @__NL80211_CMD_AFTER_LAST: internal use1089 * @__NL80211_CMD_AFTER_LAST: internal use
1070 */1090 */
@@ -1285,6 +1305,10 @@ enum nl80211_commands { · 214 unmodified lines
1285 1305
1286 NL80211_CMD_NOTIFY_RADAR,1306 NL80211_CMD_NOTIFY_RADAR,
1287 1307
1308 NL80211_CMD_UPDATE_OWE_INFO,
1309
1310 NL80211_CMD_PROBE_MESH_LINK,
1311
1288 /* add new commands above here */1312 /* add new commands above here */
1289 1313
1290 /* used to define NL80211_CMD_MAX below */1314 /* used to define NL80211_CMD_MAX below */
@@ -2308,6 +2332,15 @@ enum nl80211_commands { · 1017 unmodified lines
2308 * @NL80211_ATTR_AIRTIME_WEIGHT: Station's weight when scheduled by the airtime2332 * @NL80211_ATTR_AIRTIME_WEIGHT: Station's weight when scheduled by the airtime
2309 * scheduler.2333 * scheduler.
2310 *2334 *
2335 * @NL80211_ATTR_STA_TX_POWER_SETTING: Transmit power setting type (u8) for
2336 * station associated with the AP. See &enum nl80211_tx_power_setting for
2337 * possible values.
2338 * @NL80211_ATTR_STA_TX_POWER: Transmit power level (s16) in dBm units. This
2339 * allows to set Tx power for a station. If this attribute is not included,
2340 * the default per-interface tx power setting will be overriding. Driver
2341 * should be picking up the lowest tx power, either tx power per-interface
2342 * or per-station.
2343 *
2311 * @NUM_NL80211_ATTR: total number of nl80211_attrs available2344 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
2312 * @NL80211_ATTR_MAX: highest attribute number currently defined2345 * @NL80211_ATTR_MAX: highest attribute number currently defined
2313 * @__NL80211_ATTR_AFTER_LAST: internal use2346 * @__NL80211_ATTR_AFTER_LAST: internal use
@@ -2758,6 +2791,8 @@ enum nl80211_attrs { · 444 unmodified lines
2758 NL80211_ATTR_PEER_MEASUREMENTS,2791 NL80211_ATTR_PEER_MEASUREMENTS,
2759 2792
2760 NL80211_ATTR_AIRTIME_WEIGHT,2793 NL80211_ATTR_AIRTIME_WEIGHT,
2794 NL80211_ATTR_STA_TX_POWER_SETTING,
2795 NL80211_ATTR_STA_TX_POWER,
2761 2796
2762 /* add attributes here, update the policy in nl80211.c */2797 /* add attributes here, update the policy in nl80211.c */
2763 2798
@@ -2802,7 +2837,7 @@ enum nl80211_attrs { · 38 unmodified lines
2802 2837
2803#define NL80211_MAX_SUPP_RATES 322838#define NL80211_MAX_SUPP_RATES 32
2804#define NL80211_MAX_SUPP_HT_RATES 772839#define NL80211_MAX_SUPP_HT_RATES 77
2805#define NL80211_MAX_SUPP_REG_RULES 642840#define NL80211_MAX_SUPP_REG_RULES 128
2806#define NL80211_TKIP_DATA_OFFSET_ENCR_KEY 02841#define NL80211_TKIP_DATA_OFFSET_ENCR_KEY 0
2807#define NL80211_TKIP_DATA_OFFSET_TX_MIC_KEY 162842#define NL80211_TKIP_DATA_OFFSET_TX_MIC_KEY 16
2808#define NL80211_TKIP_DATA_OFFSET_RX_MIC_KEY 242843#define NL80211_TKIP_DATA_OFFSET_RX_MIC_KEY 24
@@ -3139,6 +3174,7 @@ enum nl80211_sta_bss_param { · 330 unmodified lines
3139 * @NL80211_STA_INFO_TX_DURATION: aggregate PPDU duration for all frames3174 * @NL80211_STA_INFO_TX_DURATION: aggregate PPDU duration for all frames
3140 * sent to the station (u64, usec)3175 * sent to the station (u64, usec)
3141 * @NL80211_STA_INFO_AIRTIME_WEIGHT: current airtime weight for station (u16)3176 * @NL80211_STA_INFO_AIRTIME_WEIGHT: current airtime weight for station (u16)
3177 * @NL80211_STA_INFO_AIRTIME_LINK_METRIC: airtime link metric for mesh station
3142 * @__NL80211_STA_INFO_AFTER_LAST: internal3178 * @__NL80211_STA_INFO_AFTER_LAST: internal
3143 * @NL80211_STA_INFO_MAX: highest possible station info attribute3179 * @NL80211_STA_INFO_MAX: highest possible station info attribute
3144 */3180 */
@@ -3184,6 +3220,7 @@ enum nl80211_sta_info { · 39 unmodified lines
3184 NL80211_STA_INFO_CONNECTED_TO_GATE,3220 NL80211_STA_INFO_CONNECTED_TO_GATE,
3185 NL80211_STA_INFO_TX_DURATION,3221 NL80211_STA_INFO_TX_DURATION,
3186 NL80211_STA_INFO_AIRTIME_WEIGHT,3222 NL80211_STA_INFO_AIRTIME_WEIGHT,
3223 NL80211_STA_INFO_AIRTIME_LINK_METRIC,
3187 3224
3188 /* keep last */3225 /* keep last */
3189 __NL80211_STA_INFO_AFTER_LAST,3226 __NL80211_STA_INFO_AFTER_LAST,
@@ -3638,6 +3675,14 @@ enum nl80211_reg_rule_attr { · 448 unmodified lines
3638 * value as specified by &struct nl80211_bss_select_rssi_adjust.3675 * value as specified by &struct nl80211_bss_select_rssi_adjust.
3639 * @NL80211_SCHED_SCAN_MATCH_ATTR_BSSID: BSSID to be used for matching3676 * @NL80211_SCHED_SCAN_MATCH_ATTR_BSSID: BSSID to be used for matching
3640 * (this cannot be used together with SSID).3677 * (this cannot be used together with SSID).
3678 * @NL80211_SCHED_SCAN_MATCH_PER_BAND_RSSI: Nested attribute that carries the
3679 * band specific minimum rssi thresholds for the bands defined in
3680 * enum nl80211_band. The minimum rssi threshold value(s32) specific to a
3681 * band shall be encapsulated in attribute with type value equals to one
3682 * of the NL80211_BAND_* defined in enum nl80211_band. For example, the
3683 * minimum rssi threshold value for 2.4GHZ band shall be encapsulated
3684 * within an attribute of type NL80211_BAND_2GHZ. And one or more of such
3685 * attributes will be nested within this attribute.
3641 * @NL80211_SCHED_SCAN_MATCH_ATTR_MAX: highest scheduled scan filter3686 * @NL80211_SCHED_SCAN_MATCH_ATTR_MAX: highest scheduled scan filter
3642 * attribute number currently defined3687 * attribute number currently defined
3643 * @__NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST: internal use3688 * @__NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST: internal use
@@ -3650,6 +3695,7 @@ enum nl80211_sched_scan_match_attr { · 6 unmodified lines
3650 NL80211_SCHED_SCAN_MATCH_ATTR_RELATIVE_RSSI,3695 NL80211_SCHED_SCAN_MATCH_ATTR_RELATIVE_RSSI,
3651 NL80211_SCHED_SCAN_MATCH_ATTR_RSSI_ADJUST,3696 NL80211_SCHED_SCAN_MATCH_ATTR_RSSI_ADJUST,
3652 NL80211_SCHED_SCAN_MATCH_ATTR_BSSID,3697 NL80211_SCHED_SCAN_MATCH_ATTR_BSSID,
3698 NL80211_SCHED_SCAN_MATCH_PER_BAND_RSSI,
3653 3699
3654 /* keep last */3700 /* keep last */
3655 __NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST,3701 __NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST,
@@ -4134,6 +4180,27 @@ enum nl80211_channel_type { · 478 unmodified lines
4134 NL80211_CHAN_HT40PLUS4180 NL80211_CHAN_HT40PLUS
4135};4181};
4136 4182
4183/**
4184 * enum nl80211_key_mode - Key mode
4185 *
4186 * @NL80211_KEY_RX_TX: (Default)
4187 * Key can be used for Rx and Tx immediately
4188 *
4189 * The following modes can only be selected for unicast keys and when the
4190 * driver supports @NL80211_EXT_FEATURE_EXT_KEY_ID:
4191 *
4192 * @NL80211_KEY_NO_TX: Only allowed in combination with @NL80211_CMD_NEW_KEY:
4193 * Unicast key can only be used for Rx, Tx not allowed, yet
4194 * @NL80211_KEY_SET_TX: Only allowed in combination with @NL80211_CMD_SET_KEY:
4195 * The unicast key identified by idx and mac is cleared for Tx and becomes
4196 * the preferred Tx key for the station.
4197 */
4198enum nl80211_key_mode {
4199 NL80211_KEY_RX_TX,
4200 NL80211_KEY_NO_TX,
4201 NL80211_KEY_SET_TX
4202};
4203
4137/**4204/**
4138 * enum nl80211_chan_width - channel width definitions4205 * enum nl80211_chan_width - channel width definitions
4139 *4206 *
@@ -4377,6 +4444,9 @@ enum nl80211_key_default_types { · 237 unmodified lines
4377 * @NL80211_KEY_DEFAULT_TYPES: A nested attribute containing flags4444 * @NL80211_KEY_DEFAULT_TYPES: A nested attribute containing flags
4378 * attributes, specifying what a key should be set as default as.4445 * attributes, specifying what a key should be set as default as.
4379 * See &enum nl80211_key_default_types.4446 * See &enum nl80211_key_default_types.
4447 * @NL80211_KEY_MODE: the mode from enum nl80211_key_mode.
4448 * Defaults to @NL80211_KEY_RX_TX.
4449 *
4380 * @__NL80211_KEY_AFTER_LAST: internal4450 * @__NL80211_KEY_AFTER_LAST: internal
4381 * @NL80211_KEY_MAX: highest key attribute4451 * @NL80211_KEY_MAX: highest key attribute
4382 */4452 */
@@ -4390,6 +4460,7 @@ enum nl80211_key_attributes { · 7 unmodified lines
4390 NL80211_KEY_DEFAULT_MGMT,4460 NL80211_KEY_DEFAULT_MGMT,
4391 NL80211_KEY_TYPE,4461 NL80211_KEY_TYPE,
4392 NL80211_KEY_DEFAULT_TYPES,4462 NL80211_KEY_DEFAULT_TYPES,
4463 NL80211_KEY_MODE,
4393 4464
4394 /* keep last */4465 /* keep last */
4395 __NL80211_KEY_AFTER_LAST,4466 __NL80211_KEY_AFTER_LAST,
@@ -5335,6 +5406,8 @@ enum nl80211_feature_flags { · 939 unmodified lines
5335 * able to rekey an in-use key correctly. Userspace must not rekey PTK keys5406 * able to rekey an in-use key correctly. Userspace must not rekey PTK keys
5336 * if this flag is not set. Ignoring this can leak clear text packets and/or5407 * if this flag is not set. Ignoring this can leak clear text packets and/or
5337 * freeze the connection.5408 * freeze the connection.
5409 * @NL80211_EXT_FEATURE_EXT_KEY_ID: Driver supports "Extended Key ID for
5410 * Individually Addressed Frames" from IEEE802.11-2016.
5338 *5411 *
5339 * @NL80211_EXT_FEATURE_AIRTIME_FAIRNESS: Driver supports getting airtime5412 * @NL80211_EXT_FEATURE_AIRTIME_FAIRNESS: Driver supports getting airtime
5340 * fairness for transmitted packets and has enabled airtime fairness5413 * fairness for transmitted packets and has enabled airtime fairness
@@ -5343,6 +5416,12 @@ enum nl80211_feature_flags { · 2 unmodified lines
5343 * @NL80211_EXT_FEATURE_AP_PMKSA_CACHING: Driver/device supports PMKSA caching5416 * @NL80211_EXT_FEATURE_AP_PMKSA_CACHING: Driver/device supports PMKSA caching
5344 * (set/del PMKSA operations) in AP mode.5417 * (set/del PMKSA operations) in AP mode.
5345 *5418 *
5419 * @NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD: Driver supports
5420 * filtering of sched scan results using band specific RSSI thresholds.
5421 *
5422 * @NL80211_EXT_FEATURE_STA_TX_PWR: This driver supports controlling tx power
5423 * to a station.
5424 *
5346 * @NUM_NL80211_EXT_FEATURES: number of extended features.5425 * @NUM_NL80211_EXT_FEATURES: number of extended features.
5347 * @MAX_NL80211_EXT_FEATURES: highest extended feature index.5426 * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
5348 */5427 */
@@ -5384,6 +5463,9 @@ enum nl80211_ext_feature_index { · 35 unmodified lines
5384 NL80211_EXT_FEATURE_ENABLE_FTM_RESPONDER,5463 NL80211_EXT_FEATURE_ENABLE_FTM_RESPONDER,
5385 NL80211_EXT_FEATURE_AIRTIME_FAIRNESS,5464 NL80211_EXT_FEATURE_AIRTIME_FAIRNESS,
5386 NL80211_EXT_FEATURE_AP_PMKSA_CACHING,5465 NL80211_EXT_FEATURE_AP_PMKSA_CACHING,
5466 NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD,
5467 NL80211_EXT_FEATURE_EXT_KEY_ID,
5468 NL80211_EXT_FEATURE_STA_TX_PWR,
5387 5469
5388 /* add new features before the definition below */5470 /* add new features before the definition below */
5389 NUM_NL80211_EXT_FEATURES,5471 NUM_NL80211_EXT_FEATURES,
include/uapi/linux/openvswitch.h+46−0
@@ -364,6 +364,7 @@ enum ovs_tunnel_key_attr { · 363 unmodified lines
364 OVS_TUNNEL_KEY_ATTR_IPV6_DST, /* struct in6_addr dst IPv6 address. */364 OVS_TUNNEL_KEY_ATTR_IPV6_DST, /* struct in6_addr dst IPv6 address. */
365 OVS_TUNNEL_KEY_ATTR_PAD,365 OVS_TUNNEL_KEY_ATTR_PAD,
366 OVS_TUNNEL_KEY_ATTR_ERSPAN_OPTS, /* struct erspan_metadata */366 OVS_TUNNEL_KEY_ATTR_ERSPAN_OPTS, /* struct erspan_metadata */
367 OVS_TUNNEL_KEY_ATTR_IPV4_INFO_BRIDGE, /* No argument. IPV4_INFO_BRIDGE mode.*/
367 __OVS_TUNNEL_KEY_ATTR_MAX368 __OVS_TUNNEL_KEY_ATTR_MAX
368};369};
369 370
@@ -734,6 +735,7 @@ struct ovs_action_hash { · 364 unmodified lines
734 * be received on NFNLGRP_CONNTRACK_NEW and NFNLGRP_CONNTRACK_DESTROY groups,735 * be received on NFNLGRP_CONNTRACK_NEW and NFNLGRP_CONNTRACK_DESTROY groups,
735 * respectively. Remaining bits control the changes for which an event is736 * respectively. Remaining bits control the changes for which an event is
736 * delivered on the NFNLGRP_CONNTRACK_UPDATE group.737 * delivered on the NFNLGRP_CONNTRACK_UPDATE group.
738 * @OVS_CT_ATTR_TIMEOUT: Variable length string defining conntrack timeout.
737 */739 */
738enum ovs_ct_attr {740enum ovs_ct_attr {
739 OVS_CT_ATTR_UNSPEC,741 OVS_CT_ATTR_UNSPEC,
@@ -746,6 +748,8 @@ enum ovs_ct_attr { · 6 unmodified lines
746 OVS_CT_ATTR_NAT, /* Nested OVS_NAT_ATTR_* */748 OVS_CT_ATTR_NAT, /* Nested OVS_NAT_ATTR_* */
747 OVS_CT_ATTR_FORCE_COMMIT, /* No argument */749 OVS_CT_ATTR_FORCE_COMMIT, /* No argument */
748 OVS_CT_ATTR_EVENTMASK, /* u32 mask of IPCT_* events. */750 OVS_CT_ATTR_EVENTMASK, /* u32 mask of IPCT_* events. */
751 OVS_CT_ATTR_TIMEOUT, /* Associate timeout with this connection for
752 * fine-grain timeout tuning. */
749 __OVS_CT_ATTR_MAX753 __OVS_CT_ATTR_MAX
750};754};
751 755
@@ -798,6 +802,44 @@ struct ovs_action_push_eth { · 46 unmodified lines
798 struct ovs_key_ethernet addresses;802 struct ovs_key_ethernet addresses;
799};803};
800 804
805/*
806 * enum ovs_check_pkt_len_attr - Attributes for %OVS_ACTION_ATTR_CHECK_PKT_LEN.
807 *
808 * @OVS_CHECK_PKT_LEN_ATTR_PKT_LEN: u16 Packet length to check for.
809 * @OVS_CHECK_PKT_LEN_ATTR_ACTIONS_IF_GREATER: Nested OVS_ACTION_ATTR_*
810 * actions to apply if the packer length is greater than the specified
811 * length in the attr - OVS_CHECK_PKT_LEN_ATTR_PKT_LEN.
812 * @OVS_CHECK_PKT_LEN_ATTR_ACTIONS_IF_LESS_EQUAL - Nested OVS_ACTION_ATTR_*
813 * actions to apply if the packer length is lesser or equal to the specified
814 * length in the attr - OVS_CHECK_PKT_LEN_ATTR_PKT_LEN.
815 */
816enum ovs_check_pkt_len_attr {
817 OVS_CHECK_PKT_LEN_ATTR_UNSPEC,
818 OVS_CHECK_PKT_LEN_ATTR_PKT_LEN,
819 OVS_CHECK_PKT_LEN_ATTR_ACTIONS_IF_GREATER,
820 OVS_CHECK_PKT_LEN_ATTR_ACTIONS_IF_LESS_EQUAL,
821 __OVS_CHECK_PKT_LEN_ATTR_MAX,
822
823#ifdef __KERNEL__
824 OVS_CHECK_PKT_LEN_ATTR_ARG /* struct check_pkt_len_arg */
825#endif
826};
827
828#define OVS_CHECK_PKT_LEN_ATTR_MAX (__OVS_CHECK_PKT_LEN_ATTR_MAX - 1)
829
830#ifdef __KERNEL__
831struct check_pkt_len_arg {
832 u16 pkt_len; /* Same value as OVS_CHECK_PKT_LEN_ATTR_PKT_LEN'. */
833 bool exec_for_greater; /* When true, actions in IF_GREATER will
834 * not change flow keys. False otherwise.
835 */
836 bool exec_for_lesser_equal; /* When true, actions in IF_LESS_EQUAL
837 * will not change flow keys. False
838 * otherwise.
839 */
840};
841#endif
842
801/**843/**
802 * enum ovs_action_attr - Action types.844 * enum ovs_action_attr - Action types.
803 *845 *
@@ -842,6 +884,9 @@ struct ovs_action_push_eth { · 38 unmodified lines
842 * packet, or modify the packet (e.g., change the DSCP field).884 * packet, or modify the packet (e.g., change the DSCP field).
843 * @OVS_ACTION_ATTR_CLONE: make a copy of the packet and execute a list of885 * @OVS_ACTION_ATTR_CLONE: make a copy of the packet and execute a list of
844 * actions without affecting the original packet and key.886 * actions without affecting the original packet and key.
887 * @OVS_ACTION_ATTR_CHECK_PKT_LEN: Check the packet length and execute a set
888 * of actions if greater than the specified packet length, else execute
889 * another set of actions.
845 *890 *
846 * Only a single header can be set with a single %OVS_ACTION_ATTR_SET. Not all891 * Only a single header can be set with a single %OVS_ACTION_ATTR_SET. Not all
847 * fields within a header are modifiable, e.g. the IPv4 protocol and fragment892 * fields within a header are modifiable, e.g. the IPv4 protocol and fragment
@@ -876,6 +921,7 @@ enum ovs_action_attr { · 28 unmodified lines
876 OVS_ACTION_ATTR_POP_NSH, /* No argument. */921 OVS_ACTION_ATTR_POP_NSH, /* No argument. */
877 OVS_ACTION_ATTR_METER, /* u32 meter ID. */922 OVS_ACTION_ATTR_METER, /* u32 meter ID. */
878 OVS_ACTION_ATTR_CLONE, /* Nested OVS_CLONE_ATTR_*. */923 OVS_ACTION_ATTR_CLONE, /* Nested OVS_CLONE_ATTR_*. */
924 OVS_ACTION_ATTR_CHECK_PKT_LEN, /* Nested OVS_CHECK_PKT_LEN_ATTR_*. */
879 925
880 __OVS_ACTION_ATTR_MAX, /* Nothing past this will be accepted926 __OVS_ACTION_ATTR_MAX, /* Nothing past this will be accepted
881 * from userspace. */927 * from userspace. */
include/uapi/linux/pci_regs.h+71−67
@@ -1,7 +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/*2/*
3 * pci_regs.h
4 *
5 * PCI standard defines3 * PCI standard defines
6 * Copyright 1994, Drew Eckhardt4 * Copyright 1994, Drew Eckhardt
7 * Copyright 1997--1999 Martin Mares <mj@ucw.cz>5 * Copyright 1997--1999 Martin Mares <mj@ucw.cz>
@@ -15,7 +13,7 @@ · 7 unmodified lines
15 * PCI System Design Guide13 * PCI System Design Guide
16 *14 *
17 * For HyperTransport information, please consult the following manuals15 * For HyperTransport information, please consult the following manuals
18 * from http://www.hypertransport.org16 * from http://www.hypertransport.org :
19 *17 *
20 * The HyperTransport I/O Link Specification18 * The HyperTransport I/O Link Specification
21 */19 */
@@ -301,7 +299,7 @@ · 279 unmodified lines
301#define PCI_SID_ESR_FIC 0x20 /* First In Chassis Flag */299#define PCI_SID_ESR_FIC 0x20 /* First In Chassis Flag */
302#define PCI_SID_CHASSIS_NR 3 /* Chassis Number */300#define PCI_SID_CHASSIS_NR 3 /* Chassis Number */
303 301
304/* Message Signalled Interrupts registers */302/* Message Signalled Interrupt registers */
305 303
306#define PCI_MSI_FLAGS 2 /* Message Control */304#define PCI_MSI_FLAGS 2 /* Message Control */
307#define PCI_MSI_FLAGS_ENABLE 0x0001 /* MSI feature enabled */305#define PCI_MSI_FLAGS_ENABLE 0x0001 /* MSI feature enabled */
@@ -319,7 +317,7 @@ · 11 unmodified lines
319#define PCI_MSI_MASK_64 16 /* Mask bits register for 64-bit devices */317#define PCI_MSI_MASK_64 16 /* Mask bits register for 64-bit devices */
320#define PCI_MSI_PENDING_64 20 /* Pending intrs for 64-bit devices */318#define PCI_MSI_PENDING_64 20 /* Pending intrs for 64-bit devices */
321 319
322/* MSI-X registers */320/* MSI-X registers (in MSI-X capability) */
323#define PCI_MSIX_FLAGS 2 /* Message Control */321#define PCI_MSIX_FLAGS 2 /* Message Control */
324#define PCI_MSIX_FLAGS_QSIZE 0x07FF /* Table size */322#define PCI_MSIX_FLAGS_QSIZE 0x07FF /* Table size */
325#define PCI_MSIX_FLAGS_MASKALL 0x4000 /* Mask all vectors for this function */323#define PCI_MSIX_FLAGS_MASKALL 0x4000 /* Mask all vectors for this function */
@@ -333,13 +331,13 @@ · 7 unmodified lines
333#define PCI_MSIX_FLAGS_BIRMASK PCI_MSIX_PBA_BIR /* deprecated */331#define PCI_MSIX_FLAGS_BIRMASK PCI_MSIX_PBA_BIR /* deprecated */
334#define PCI_CAP_MSIX_SIZEOF 12 /* size of MSIX registers */332#define PCI_CAP_MSIX_SIZEOF 12 /* size of MSIX registers */
335 333
336/* MSI-X Table entry format */334/* MSI-X Table entry format (in memory mapped by a BAR) */
337#define PCI_MSIX_ENTRY_SIZE 16335#define PCI_MSIX_ENTRY_SIZE 16
338#define PCI_MSIX_ENTRY_LOWER_ADDR 0336#define PCI_MSIX_ENTRY_LOWER_ADDR 0 /* Message Address */
339#define PCI_MSIX_ENTRY_UPPER_ADDR 4337#define PCI_MSIX_ENTRY_UPPER_ADDR 4 /* Message Upper Address */
340#define PCI_MSIX_ENTRY_DATA 8338#define PCI_MSIX_ENTRY_DATA 8 /* Message Data */
341#define PCI_MSIX_ENTRY_VECTOR_CTRL 12339#define PCI_MSIX_ENTRY_VECTOR_CTRL 12 /* Vector Control */
342#define PCI_MSIX_ENTRY_CTRL_MASKBIT 1340#define PCI_MSIX_ENTRY_CTRL_MASKBIT 0x00000001
343 341
344/* CompactPCI Hotswap Register */342/* CompactPCI Hotswap Register */
345 343
@@ -372,6 +370,12 @@ · 26 unmodified lines
372#define PCI_EA_FIRST_ENT_BRIDGE 8 /* First EA Entry for Bridges */370#define PCI_EA_FIRST_ENT_BRIDGE 8 /* First EA Entry for Bridges */
373#define PCI_EA_ES 0x00000007 /* Entry Size */371#define PCI_EA_ES 0x00000007 /* Entry Size */
374#define PCI_EA_BEI 0x000000f0 /* BAR Equivalent Indicator */372#define PCI_EA_BEI 0x000000f0 /* BAR Equivalent Indicator */
373
374/* EA fixed Secondary and Subordinate bus numbers for Bridge */
375#define PCI_EA_SEC_BUS_MASK 0xff
376#define PCI_EA_SUB_BUS_MASK 0xff00
377#define PCI_EA_SUB_BUS_SHIFT 8
378
375/* 0-5 map to BARs 0-5 respectively */379/* 0-5 map to BARs 0-5 respectively */
376#define PCI_EA_BEI_BAR0 0380#define PCI_EA_BEI_BAR0 0
377#define PCI_EA_BEI_BAR5 5381#define PCI_EA_BEI_BAR5 5
@@ -465,19 +469,19 @@ · 87 unmodified lines
465/* PCI Express capability registers */469/* PCI Express capability registers */
466 470
467#define PCI_EXP_FLAGS 2 /* Capabilities register */471#define PCI_EXP_FLAGS 2 /* Capabilities register */
468#define PCI_EXP_FLAGS_VERS 0x000f /* Capability version */472#define PCI_EXP_FLAGS_VERS 0x000f /* Capability version */
469#define PCI_EXP_FLAGS_TYPE 0x00f0 /* Device/Port type */473#define PCI_EXP_FLAGS_TYPE 0x00f0 /* Device/Port type */
470#define PCI_EXP_TYPE_ENDPOINT 0x0 /* Express Endpoint */474#define PCI_EXP_TYPE_ENDPOINT 0x0 /* Express Endpoint */
471#define PCI_EXP_TYPE_LEG_END 0x1 /* Legacy Endpoint */475#define PCI_EXP_TYPE_LEG_END 0x1 /* Legacy Endpoint */
472#define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */476#define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */
473#define PCI_EXP_TYPE_UPSTREAM 0x5 /* Upstream Port */477#define PCI_EXP_TYPE_UPSTREAM 0x5 /* Upstream Port */
474#define PCI_EXP_TYPE_DOWNSTREAM 0x6 /* Downstream Port */478#define PCI_EXP_TYPE_DOWNSTREAM 0x6 /* Downstream Port */
475#define PCI_EXP_TYPE_PCI_BRIDGE 0x7 /* PCIe to PCI/PCI-X Bridge */479#define PCI_EXP_TYPE_PCI_BRIDGE 0x7 /* PCIe to PCI/PCI-X Bridge */
476#define PCI_EXP_TYPE_PCIE_BRIDGE 0x8 /* PCI/PCI-X to PCIe Bridge */480#define PCI_EXP_TYPE_PCIE_BRIDGE 0x8 /* PCI/PCI-X to PCIe Bridge */
477#define PCI_EXP_TYPE_RC_END 0x9 /* Root Complex Integrated Endpoint */481#define PCI_EXP_TYPE_RC_END 0x9 /* Root Complex Integrated Endpoint */
478#define PCI_EXP_TYPE_RC_EC 0xa /* Root Complex Event Collector */482#define PCI_EXP_TYPE_RC_EC 0xa /* Root Complex Event Collector */
479#define PCI_EXP_FLAGS_SLOT 0x0100 /* Slot implemented */483#define PCI_EXP_FLAGS_SLOT 0x0100 /* Slot implemented */
480#define PCI_EXP_FLAGS_IRQ 0x3e00 /* Interrupt message number */484#define PCI_EXP_FLAGS_IRQ 0x3e00 /* Interrupt message number */
481#define PCI_EXP_DEVCAP 4 /* Device capabilities */485#define PCI_EXP_DEVCAP 4 /* Device capabilities */
482#define PCI_EXP_DEVCAP_PAYLOAD 0x00000007 /* Max_Payload_Size */486#define PCI_EXP_DEVCAP_PAYLOAD 0x00000007 /* Max_Payload_Size */
483#define PCI_EXP_DEVCAP_PHANTOM 0x00000018 /* Phantom functions */487#define PCI_EXP_DEVCAP_PHANTOM 0x00000018 /* Phantom functions */
@@ -616,8 +620,8 @@ · 132 unmodified lines
616#define PCI_EXP_RTCAP 30 /* Root Capabilities */620#define PCI_EXP_RTCAP 30 /* Root Capabilities */
617#define PCI_EXP_RTCAP_CRSVIS 0x0001 /* CRS Software Visibility capability */621#define PCI_EXP_RTCAP_CRSVIS 0x0001 /* CRS Software Visibility capability */
618#define PCI_EXP_RTSTA 32 /* Root Status */622#define PCI_EXP_RTSTA 32 /* Root Status */
619#define PCI_EXP_RTSTA_PME 0x00010000 /* PME status */623#define PCI_EXP_RTSTA_PME 0x00010000 /* PME status */
620#define PCI_EXP_RTSTA_PENDING 0x00020000 /* PME pending */624#define PCI_EXP_RTSTA_PENDING 0x00020000 /* PME pending */
621/*625/*
622 * The Device Capabilities 2, Device Status 2, Device Control 2,626 * The Device Capabilities 2, Device Status 2, Device Control 2,
623 * Link Capabilities 2, Link Status 2, Link Control 2,627 * Link Capabilities 2, Link Status 2, Link Control 2,
@@ -637,13 +641,13 @@ · 13 unmodified lines
637#define PCI_EXP_DEVCAP2_OBFF_MASK 0x000c0000 /* OBFF support mechanism */641#define PCI_EXP_DEVCAP2_OBFF_MASK 0x000c0000 /* OBFF support mechanism */
638#define PCI_EXP_DEVCAP2_OBFF_MSG 0x00040000 /* New message signaling */642#define PCI_EXP_DEVCAP2_OBFF_MSG 0x00040000 /* New message signaling */
639#define PCI_EXP_DEVCAP2_OBFF_WAKE 0x00080000 /* Re-use WAKE# for OBFF */643#define PCI_EXP_DEVCAP2_OBFF_WAKE 0x00080000 /* Re-use WAKE# for OBFF */
640#define PCI_EXP_DEVCAP2_EE_PREFIX 0x00200000 /* End-End TLP Prefix */644#define PCI_EXP_DEVCAP2_EE_PREFIX 0x00200000 /* End-End TLP Prefix */
641#define PCI_EXP_DEVCTL2 40 /* Device Control 2 */645#define PCI_EXP_DEVCTL2 40 /* Device Control 2 */
642#define PCI_EXP_DEVCTL2_COMP_TIMEOUT 0x000f /* Completion Timeout Value */646#define PCI_EXP_DEVCTL2_COMP_TIMEOUT 0x000f /* Completion Timeout Value */
643#define PCI_EXP_DEVCTL2_COMP_TMOUT_DIS 0x0010 /* Completion Timeout Disable */647#define PCI_EXP_DEVCTL2_COMP_TMOUT_DIS 0x0010 /* Completion Timeout Disable */
644#define PCI_EXP_DEVCTL2_ARI 0x0020 /* Alternative Routing-ID */648#define PCI_EXP_DEVCTL2_ARI 0x0020 /* Alternative Routing-ID */
645#define PCI_EXP_DEVCTL2_ATOMIC_REQ 0x0040 /* Set Atomic requests */649#define PCI_EXP_DEVCTL2_ATOMIC_REQ 0x0040 /* Set Atomic requests */
646#define PCI_EXP_DEVCTL2_ATOMIC_EGRESS_BLOCK 0x0080 /* Block atomic egress */650#define PCI_EXP_DEVCTL2_ATOMIC_EGRESS_BLOCK 0x0080 /* Block atomic egress */
647#define PCI_EXP_DEVCTL2_IDO_REQ_EN 0x0100 /* Allow IDO for requests */651#define PCI_EXP_DEVCTL2_IDO_REQ_EN 0x0100 /* Allow IDO for requests */
648#define PCI_EXP_DEVCTL2_IDO_CMP_EN 0x0200 /* Allow IDO for completions */652#define PCI_EXP_DEVCTL2_IDO_CMP_EN 0x0200 /* Allow IDO for completions */
649#define PCI_EXP_DEVCTL2_LTR_EN 0x0400 /* Enable LTR mechanism */653#define PCI_EXP_DEVCTL2_LTR_EN 0x0400 /* Enable LTR mechanism */
@@ -659,11 +663,11 @@ · 9 unmodified lines
659#define PCI_EXP_LNKCAP2_SLS_16_0GB 0x00000010 /* Supported Speed 16GT/s */663#define PCI_EXP_LNKCAP2_SLS_16_0GB 0x00000010 /* Supported Speed 16GT/s */
660#define PCI_EXP_LNKCAP2_CROSSLINK 0x00000100 /* Crosslink supported */664#define PCI_EXP_LNKCAP2_CROSSLINK 0x00000100 /* Crosslink supported */
661#define PCI_EXP_LNKCTL2 48 /* Link Control 2 */665#define PCI_EXP_LNKCTL2 48 /* Link Control 2 */
662#define PCI_EXP_LNKCTL2_TLS 0x000f666#define PCI_EXP_LNKCTL2_TLS 0x000f
663#define PCI_EXP_LNKCTL2_TLS_2_5GT 0x0001 /* Supported Speed 2.5GT/s */667#define PCI_EXP_LNKCTL2_TLS_2_5GT 0x0001 /* Supported Speed 2.5GT/s */
664#define PCI_EXP_LNKCTL2_TLS_5_0GT 0x0002 /* Supported Speed 5GT/s */668#define PCI_EXP_LNKCTL2_TLS_5_0GT 0x0002 /* Supported Speed 5GT/s */
665#define PCI_EXP_LNKCTL2_TLS_8_0GT 0x0003 /* Supported Speed 8GT/s */669#define PCI_EXP_LNKCTL2_TLS_8_0GT 0x0003 /* Supported Speed 8GT/s */
666#define PCI_EXP_LNKCTL2_TLS_16_0GT 0x0004 /* Supported Speed 16GT/s */670#define PCI_EXP_LNKCTL2_TLS_16_0GT 0x0004 /* Supported Speed 16GT/s */
667#define PCI_EXP_LNKSTA2 50 /* Link Status 2 */671#define PCI_EXP_LNKSTA2 50 /* Link Status 2 */
668#define PCI_CAP_EXP_ENDPOINT_SIZEOF_V2 52 /* v2 endpoints with link end here */672#define PCI_CAP_EXP_ENDPOINT_SIZEOF_V2 52 /* v2 endpoints with link end here */
669#define PCI_EXP_SLTCAP2 52 /* Slot Capabilities 2 */673#define PCI_EXP_SLTCAP2 52 /* Slot Capabilities 2 */
@@ -752,18 +756,18 @@ · 82 unmodified lines
752#define PCI_ERR_CAP_ECRC_CHKE 0x00000100 /* ECRC Check Enable */756#define PCI_ERR_CAP_ECRC_CHKE 0x00000100 /* ECRC Check Enable */
753#define PCI_ERR_HEADER_LOG 28 /* Header Log Register (16 bytes) */757#define PCI_ERR_HEADER_LOG 28 /* Header Log Register (16 bytes) */
754#define PCI_ERR_ROOT_COMMAND 44 /* Root Error Command */758#define PCI_ERR_ROOT_COMMAND 44 /* Root Error Command */
755#define PCI_ERR_ROOT_CMD_COR_EN 0x00000001 /* Correctable Err Reporting Enable */759#define PCI_ERR_ROOT_CMD_COR_EN 0x00000001 /* Correctable Err Reporting Enable */
756#define PCI_ERR_ROOT_CMD_NONFATAL_EN 0x00000002 /* Non-Fatal Err Reporting Enable */760#define PCI_ERR_ROOT_CMD_NONFATAL_EN 0x00000002 /* Non-Fatal Err Reporting Enable */
757#define PCI_ERR_ROOT_CMD_FATAL_EN 0x00000004 /* Fatal Err Reporting Enable */761#define PCI_ERR_ROOT_CMD_FATAL_EN 0x00000004 /* Fatal Err Reporting Enable */
758#define PCI_ERR_ROOT_STATUS 48762#define PCI_ERR_ROOT_STATUS 48
759#define PCI_ERR_ROOT_COR_RCV 0x00000001 /* ERR_COR Received */763#define PCI_ERR_ROOT_COR_RCV 0x00000001 /* ERR_COR Received */
760#define PCI_ERR_ROOT_MULTI_COR_RCV 0x00000002 /* Multiple ERR_COR */764#define PCI_ERR_ROOT_MULTI_COR_RCV 0x00000002 /* Multiple ERR_COR */
761#define PCI_ERR_ROOT_UNCOR_RCV 0x00000004 /* ERR_FATAL/NONFATAL */765#define PCI_ERR_ROOT_UNCOR_RCV 0x00000004 /* ERR_FATAL/NONFATAL */
762#define PCI_ERR_ROOT_MULTI_UNCOR_RCV 0x00000008 /* Multiple FATAL/NONFATAL */766#define PCI_ERR_ROOT_MULTI_UNCOR_RCV 0x00000008 /* Multiple FATAL/NONFATAL */
763#define PCI_ERR_ROOT_FIRST_FATAL 0x00000010 /* First UNC is Fatal */767#define PCI_ERR_ROOT_FIRST_FATAL 0x00000010 /* First UNC is Fatal */
764#define PCI_ERR_ROOT_NONFATAL_RCV 0x00000020 /* Non-Fatal Received */768#define PCI_ERR_ROOT_NONFATAL_RCV 0x00000020 /* Non-Fatal Received */
765#define PCI_ERR_ROOT_FATAL_RCV 0x00000040 /* Fatal Received */769#define PCI_ERR_ROOT_FATAL_RCV 0x00000040 /* Fatal Received */
766#define PCI_ERR_ROOT_AER_IRQ 0xf8000000 /* Advanced Error Interrupt Message Number */770#define PCI_ERR_ROOT_AER_IRQ 0xf8000000 /* Advanced Error Interrupt Message Number */
767#define PCI_ERR_ROOT_ERR_SRC 52 /* Error Source Identification */771#define PCI_ERR_ROOT_ERR_SRC 52 /* Error Source Identification */
768 772
769/* Virtual Channel */773/* Virtual Channel */
@@ -875,12 +879,12 @@ · 105 unmodified lines
875 879
876/* Page Request Interface */880/* Page Request Interface */
877#define PCI_PRI_CTRL 0x04 /* PRI control register */881#define PCI_PRI_CTRL 0x04 /* PRI control register */
878#define PCI_PRI_CTRL_ENABLE 0x01 /* Enable */882#define PCI_PRI_CTRL_ENABLE 0x0001 /* Enable */
879#define PCI_PRI_CTRL_RESET 0x02 /* Reset */883#define PCI_PRI_CTRL_RESET 0x0002 /* Reset */
880#define PCI_PRI_STATUS 0x06 /* PRI status register */884#define PCI_PRI_STATUS 0x06 /* PRI status register */
881#define PCI_PRI_STATUS_RF 0x001 /* Response Failure */885#define PCI_PRI_STATUS_RF 0x0001 /* Response Failure */
882#define PCI_PRI_STATUS_UPRGI 0x002 /* Unexpected PRG index */886#define PCI_PRI_STATUS_UPRGI 0x0002 /* Unexpected PRG index */
883#define PCI_PRI_STATUS_STOPPED 0x100 /* PRI Stopped */887#define PCI_PRI_STATUS_STOPPED 0x0100 /* PRI Stopped */
884#define PCI_PRI_STATUS_PASID 0x8000 /* PRG Response PASID Required */888#define PCI_PRI_STATUS_PASID 0x8000 /* PRG Response PASID Required */
885#define PCI_PRI_MAX_REQ 0x08 /* PRI max reqs supported */889#define PCI_PRI_MAX_REQ 0x08 /* PRI max reqs supported */
886#define PCI_PRI_ALLOC_REQ 0x0c /* PRI max reqs allowed */890#define PCI_PRI_ALLOC_REQ 0x0c /* PRI max reqs allowed */
@@ -898,16 +902,16 @@ · 11 unmodified lines
898 902
899/* Single Root I/O Virtualization */903/* Single Root I/O Virtualization */
900#define PCI_SRIOV_CAP 0x04 /* SR-IOV Capabilities */904#define PCI_SRIOV_CAP 0x04 /* SR-IOV Capabilities */
901#define PCI_SRIOV_CAP_VFM 0x01 /* VF Migration Capable */905#define PCI_SRIOV_CAP_VFM 0x00000001 /* VF Migration Capable */
902#define PCI_SRIOV_CAP_INTR(x) ((x) >> 21) /* Interrupt Message Number */906#define PCI_SRIOV_CAP_INTR(x) ((x) >> 21) /* Interrupt Message Number */
903#define PCI_SRIOV_CTRL 0x08 /* SR-IOV Control */907#define PCI_SRIOV_CTRL 0x08 /* SR-IOV Control */
904#define PCI_SRIOV_CTRL_VFE 0x01 /* VF Enable */908#define PCI_SRIOV_CTRL_VFE 0x0001 /* VF Enable */
905#define PCI_SRIOV_CTRL_VFM 0x02 /* VF Migration Enable */909#define PCI_SRIOV_CTRL_VFM 0x0002 /* VF Migration Enable */
906#define PCI_SRIOV_CTRL_INTR 0x04 /* VF Migration Interrupt Enable */910#define PCI_SRIOV_CTRL_INTR 0x0004 /* VF Migration Interrupt Enable */
907#define PCI_SRIOV_CTRL_MSE 0x08 /* VF Memory Space Enable */911#define PCI_SRIOV_CTRL_MSE 0x0008 /* VF Memory Space Enable */
908#define PCI_SRIOV_CTRL_ARI 0x10 /* ARI Capable Hierarchy */912#define PCI_SRIOV_CTRL_ARI 0x0010 /* ARI Capable Hierarchy */
909#define PCI_SRIOV_STATUS 0x0a /* SR-IOV Status */913#define PCI_SRIOV_STATUS 0x0a /* SR-IOV Status */
910#define PCI_SRIOV_STATUS_VFM 0x01 /* VF Migration Status */914#define PCI_SRIOV_STATUS_VFM 0x0001 /* VF Migration Status */
911#define PCI_SRIOV_INITIAL_VF 0x0c /* Initial VFs */915#define PCI_SRIOV_INITIAL_VF 0x0c /* Initial VFs */
912#define PCI_SRIOV_TOTAL_VF 0x0e /* Total VFs */916#define PCI_SRIOV_TOTAL_VF 0x0e /* Total VFs */
913#define PCI_SRIOV_NUM_VF 0x10 /* Number of VFs */917#define PCI_SRIOV_NUM_VF 0x10 /* Number of VFs */
@@ -937,13 +941,13 @@ · 23 unmodified lines
937 941
938/* Access Control Service */942/* Access Control Service */
939#define PCI_ACS_CAP 0x04 /* ACS Capability Register */943#define PCI_ACS_CAP 0x04 /* ACS Capability Register */
940#define PCI_ACS_SV 0x01 /* Source Validation */944#define PCI_ACS_SV 0x0001 /* Source Validation */
941#define PCI_ACS_TB 0x02 /* Translation Blocking */945#define PCI_ACS_TB 0x0002 /* Translation Blocking */
942#define PCI_ACS_RR 0x04 /* P2P Request Redirect */946#define PCI_ACS_RR 0x0004 /* P2P Request Redirect */
943#define PCI_ACS_CR 0x08 /* P2P Completion Redirect */947#define PCI_ACS_CR 0x0008 /* P2P Completion Redirect */
944#define PCI_ACS_UF 0x10 /* Upstream Forwarding */948#define PCI_ACS_UF 0x0010 /* Upstream Forwarding */
945#define PCI_ACS_EC 0x20 /* P2P Egress Control */949#define PCI_ACS_EC 0x0020 /* P2P Egress Control */
946#define PCI_ACS_DT 0x40 /* Direct Translated P2P */950#define PCI_ACS_DT 0x0040 /* Direct Translated P2P */
947#define PCI_ACS_EGRESS_BITS 0x05 /* ACS Egress Control Vector Size */951#define PCI_ACS_EGRESS_BITS 0x05 /* ACS Egress Control Vector Size */
948#define PCI_ACS_CTRL 0x06 /* ACS Control Register */952#define PCI_ACS_CTRL 0x06 /* ACS Control Register */
949#define PCI_ACS_EGRESS_CTL_V 0x08 /* ACS Egress Control Vector */953#define PCI_ACS_EGRESS_CTL_V 0x08 /* ACS Egress Control Vector */
@@ -993,9 +997,9 @@ · 43 unmodified lines
993#define PCI_EXP_DPC_CAP_DL_ACTIVE 0x1000 /* ERR_COR signal on DL_Active supported */997#define PCI_EXP_DPC_CAP_DL_ACTIVE 0x1000 /* ERR_COR signal on DL_Active supported */
994 998
995#define PCI_EXP_DPC_CTL 6 /* DPC control */999#define PCI_EXP_DPC_CTL 6 /* DPC control */
996#define PCI_EXP_DPC_CTL_EN_FATAL 0x0001 /* Enable trigger on ERR_FATAL message */1000#define PCI_EXP_DPC_CTL_EN_FATAL 0x0001 /* Enable trigger on ERR_FATAL message */
997#define PCI_EXP_DPC_CTL_EN_NONFATAL 0x0002 /* Enable trigger on ERR_NONFATAL message */1001#define PCI_EXP_DPC_CTL_EN_NONFATAL 0x0002 /* Enable trigger on ERR_NONFATAL message */
998#define PCI_EXP_DPC_CTL_INT_EN 0x0008 /* DPC Interrupt Enable */1002#define PCI_EXP_DPC_CTL_INT_EN 0x0008 /* DPC Interrupt Enable */
999 1003
1000#define PCI_EXP_DPC_STATUS 8 /* DPC Status */1004#define PCI_EXP_DPC_STATUS 8 /* DPC Status */
1001#define PCI_EXP_DPC_STATUS_TRIGGER 0x0001 /* Trigger Status */1005#define PCI_EXP_DPC_STATUS_TRIGGER 0x0001 /* Trigger Status */
include/uapi/linux/pkt_sched.h+13−0
@@ -1148,6 +1148,16 @@ enum { · 1147 unmodified lines
1148 1148
1149#define TCA_TAPRIO_SCHED_MAX (__TCA_TAPRIO_SCHED_MAX - 1)1149#define TCA_TAPRIO_SCHED_MAX (__TCA_TAPRIO_SCHED_MAX - 1)
1150 1150
1151/* The format for the admin sched (dump only):
1152 * [TCA_TAPRIO_SCHED_ADMIN_SCHED]
1153 * [TCA_TAPRIO_ATTR_SCHED_BASE_TIME]
1154 * [TCA_TAPRIO_ATTR_SCHED_ENTRY_LIST]
1155 * [TCA_TAPRIO_ATTR_SCHED_ENTRY]
1156 * [TCA_TAPRIO_ATTR_SCHED_ENTRY_CMD]
1157 * [TCA_TAPRIO_ATTR_SCHED_ENTRY_GATES]
1158 * [TCA_TAPRIO_ATTR_SCHED_ENTRY_INTERVAL]
1159 */
1160
1151enum {1161enum {
1152 TCA_TAPRIO_ATTR_UNSPEC,1162 TCA_TAPRIO_ATTR_UNSPEC,
1153 TCA_TAPRIO_ATTR_PRIOMAP, /* struct tc_mqprio_qopt */1163 TCA_TAPRIO_ATTR_PRIOMAP, /* struct tc_mqprio_qopt */
@@ -1156,6 +1166,9 @@ enum { · 2 unmodified lines
1156 TCA_TAPRIO_ATTR_SCHED_SINGLE_ENTRY, /* single entry */1166 TCA_TAPRIO_ATTR_SCHED_SINGLE_ENTRY, /* single entry */
1157 TCA_TAPRIO_ATTR_SCHED_CLOCKID, /* s32 */1167 TCA_TAPRIO_ATTR_SCHED_CLOCKID, /* s32 */
1158 TCA_TAPRIO_PAD,1168 TCA_TAPRIO_PAD,
1169 TCA_TAPRIO_ATTR_ADMIN_SCHED, /* The admin sched, only used in dump */
1170 TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME, /* s64 */
1171 TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME_EXTENSION, /* s64 */
1159 __TCA_TAPRIO_ATTR_MAX,1172 __TCA_TAPRIO_ATTR_MAX,
1160};1173};
1161 1174
include/uapi/linux/psci.h+7−0
@@ -49,8 +49,11 @@ · 48 unmodified lines
49 49
50#define PSCI_1_0_FN_PSCI_FEATURES PSCI_0_2_FN(10)50#define PSCI_1_0_FN_PSCI_FEATURES PSCI_0_2_FN(10)
51#define PSCI_1_0_FN_SYSTEM_SUSPEND PSCI_0_2_FN(14)51#define PSCI_1_0_FN_SYSTEM_SUSPEND PSCI_0_2_FN(14)
52#define PSCI_1_0_FN_SET_SUSPEND_MODE PSCI_0_2_FN(15)
53#define PSCI_1_1_FN_SYSTEM_RESET2 PSCI_0_2_FN(18)
52 54
53#define PSCI_1_0_FN64_SYSTEM_SUSPEND PSCI_0_2_FN64(14)55#define PSCI_1_0_FN64_SYSTEM_SUSPEND PSCI_0_2_FN64(14)
56#define PSCI_1_1_FN64_SYSTEM_RESET2 PSCI_0_2_FN64(18)
54 57
55/* PSCI v0.2 power state encoding for CPU_SUSPEND function */58/* PSCI v0.2 power state encoding for CPU_SUSPEND function */
56#define PSCI_0_2_POWER_STATE_ID_MASK 0xffff59#define PSCI_0_2_POWER_STATE_ID_MASK 0xffff
@@ -97,6 +100,10 @@ · 40 unmodified lines
97#define PSCI_1_0_FEATURES_CPU_SUSPEND_PF_MASK \100#define PSCI_1_0_FEATURES_CPU_SUSPEND_PF_MASK \
98 (0x1 << PSCI_1_0_FEATURES_CPU_SUSPEND_PF_SHIFT)101 (0x1 << PSCI_1_0_FEATURES_CPU_SUSPEND_PF_SHIFT)
99 102
103#define PSCI_1_0_OS_INITIATED BIT(0)
104#define PSCI_1_0_SUSPEND_MODE_PC 0
105#define PSCI_1_0_SUSPEND_MODE_OSI 1
106
100/* PSCI return values (inclusive of all PSCI versions) */107/* PSCI return values (inclusive of all PSCI versions) */
101#define PSCI_RET_SUCCESS 0108#define PSCI_RET_SUCCESS 0
102#define PSCI_RET_NOT_SUPPORTED -1109#define PSCI_RET_NOT_SUPPORTED -1
include/uapi/linux/psp-sev.h+14−4
@@ -6,8 +6,7 @@ · 5 unmodified lines
6 *6 *
7 * Author: Brijesh Singh <brijesh.singh@amd.com>7 * Author: Brijesh Singh <brijesh.singh@amd.com>
8 *8 *
9 * SEV spec 0.14 is available at:9 * SEV API specification is available at: https://developer.amd.com/sev/
10 * http://support.amd.com/TechDocs/55766_SEV-KM%20API_Specification.pdf
11 *10 *
12 * This program is free software; you can redistribute it and/or modify11 * This program is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License version 2 as12 * it under the terms of the GNU General Public License version 2 as
@@ -30,7 +29,8 @@ enum { · 16 unmodified lines
30 SEV_PDH_GEN,29 SEV_PDH_GEN,
31 SEV_PDH_CERT_EXPORT,30 SEV_PDH_CERT_EXPORT,
32 SEV_PEK_CERT_IMPORT,31 SEV_PEK_CERT_IMPORT,
33 SEV_GET_ID,32 SEV_GET_ID, /* This command is deprecated, use SEV_GET_ID2 */
33 SEV_GET_ID2,
34 34
35 SEV_MAX,35 SEV_MAX,
36};36};
@@ -125,7 +125,7 @@ struct sev_user_data_pdh_cert_export { · 88 unmodified lines
125} __packed;125} __packed;
126 126
127/**127/**
128 * struct sev_user_data_get_id - GET_ID command parameters128 * struct sev_user_data_get_id - GET_ID command parameters (deprecated)
129 *129 *
130 * @socket1: Buffer to pass unique ID of first socket130 * @socket1: Buffer to pass unique ID of first socket
131 * @socket2: Buffer to pass unique ID of second socket131 * @socket2: Buffer to pass unique ID of second socket
@@ -135,6 +135,16 @@ struct sev_user_data_get_id { · 3 unmodified lines
135 __u8 socket2[64]; /* Out */135 __u8 socket2[64]; /* Out */
136} __packed;136} __packed;
137 137
138/**
139 * struct sev_user_data_get_id2 - GET_ID command parameters
140 * @address: Buffer to store unique ID
141 * @length: length of the unique ID
142 */
143struct sev_user_data_get_id2 {
144 __u64 address; /* In */
145 __u32 length; /* In/Out */
146} __packed;
147
138/**148/**
139 * struct sev_issue_cmd - SEV ioctl parameters149 * struct sev_issue_cmd - SEV ioctl parameters
140 *150 *
include/uapi/linux/sched.h+1−0
@@ -10,6 +10,7 @@ · 9 unmodified lines
10#define CLONE_FS 0x00000200 /* set if fs info shared between processes */10#define CLONE_FS 0x00000200 /* set if fs info shared between processes */
11#define CLONE_FILES 0x00000400 /* set if open files shared between processes */11#define CLONE_FILES 0x00000400 /* set if open files shared between processes */
12#define CLONE_SIGHAND 0x00000800 /* set if signal handlers and blocked signals shared */12#define CLONE_SIGHAND 0x00000800 /* set if signal handlers and blocked signals shared */
13#define CLONE_PIDFD 0x00001000 /* set if a pidfd should be placed in parent */
13#define CLONE_PTRACE 0x00002000 /* set if we want to let tracing continue on the child too */14#define CLONE_PTRACE 0x00002000 /* set if we want to let tracing continue on the child too */
14#define CLONE_VFORK 0x00004000 /* set if the parent wants the child to wake it up on mm_release */15#define CLONE_VFORK 0x00004000 /* set if the parent wants the child to wake it up on mm_release */
15#define CLONE_PARENT 0x00008000 /* set if we want to have the same parent as the cloner */16#define CLONE_PARENT 0x00008000 /* set if we want to have the same parent as the cloner */
include/uapi/linux/sed-opal.h+1−10
@@ -5,15 +5,6 @@ · 4 unmodified lines
5 * Authors:5 * Authors:
6 * Rafael Antognolli <rafael.antognolli@intel.com>6 * Rafael Antognolli <rafael.antognolli@intel.com>
7 * Scott Bauer <scott.bauer@intel.com>7 * Scott Bauer <scott.bauer@intel.com>
8 *
9 * This program is free software; you can redistribute it and/or modify it
10 * under the terms and conditions of the GNU General Public License,
11 * version 2, as published by the Free Software Foundation.
12 *
13 * This program is distributed in the hope it will be useful, but WITHOUT
14 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
15 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
16 * more details.
17 */8 */
18 9
19#ifndef _UAPI_SED_OPAL_H10#ifndef _UAPI_SED_OPAL_H
@@ -58,7 +49,7 @@ struct opal_key { · 38 unmodified lines
58struct opal_lr_act {49struct opal_lr_act {
59 struct opal_key key;50 struct opal_key key;
60 __u32 sum;51 __u32 sum;
61 __u8 num_lrs;52 __u8 num_lrs;
62 __u8 lr[OPAL_MAX_LRS];53 __u8 lr[OPAL_MAX_LRS];
63 __u8 align[2]; /* Align to 8 byte boundary */54 __u8 align[2]; /* Align to 8 byte boundary */
64};55};
include/uapi/linux/serial_core.h+6−0
@@ -287,4 +287,10 @@ · 286 unmodified lines
287/* RDA UART */287/* RDA UART */
288#define PORT_RDA 118288#define PORT_RDA 118
289 289
290/* Socionext Milbeaut UART */
291#define PORT_MLB_USIO 119
292
293/* SiFive UART */
294#define PORT_SIFIVE_V0 120
295
290#endif /* _UAPILINUX_SERIAL_CORE_H */296#endif /* _UAPILINUX_SERIAL_CORE_H */
include/uapi/linux/sockios.h+21−0
@@ -19,6 +19,7 @@ · 18 unmodified lines
19#ifndef _LINUX_SOCKIOS_H19#ifndef _LINUX_SOCKIOS_H
20#define _LINUX_SOCKIOS_H20#define _LINUX_SOCKIOS_H
21 21
22#include <asm/bitsperlong.h>
22#include <asm/sockios.h>23#include <asm/sockios.h>
23 24
24/* Linux-specific socket ioctls */25/* Linux-specific socket ioctls */
@@ -27,6 +28,26 @@ · 2 unmodified lines
27 28
28#define SOCK_IOC_TYPE 0x8929#define SOCK_IOC_TYPE 0x89
29 30
31/*
32 * the timeval/timespec data structure layout is defined by libc,
33 * so we need to cover both possible versions on 32-bit.
34 */
35/* Get stamp (timeval) */
36#define SIOCGSTAMP_NEW _IOR(SOCK_IOC_TYPE, 0x06, long long[2])
37/* Get stamp (timespec) */
38#define SIOCGSTAMPNS_NEW _IOR(SOCK_IOC_TYPE, 0x07, long long[2])
39
40#if __BITS_PER_LONG == 64 || (defined(__x86_64__) && defined(__ILP32__))
41/* on 64-bit and x32, avoid the ?: operator */
42#define SIOCGSTAMP SIOCGSTAMP_OLD
43#define SIOCGSTAMPNS SIOCGSTAMPNS_OLD
44#else
45#define SIOCGSTAMP ((sizeof(struct timeval)) == 8 ? \
46 SIOCGSTAMP_OLD : SIOCGSTAMP_NEW)
47#define SIOCGSTAMPNS ((sizeof(struct timespec)) == 8 ? \
48 SIOCGSTAMPNS_OLD : SIOCGSTAMPNS_NEW)
49#endif
50
30/* Routing table calls. */51/* Routing table calls. */
31#define SIOCADDRT 0x890B /* add routing table entry */52#define SIOCADDRT 0x890B /* add routing table entry */
32#define SIOCDELRT 0x890C /* delete routing table entry */53#define SIOCDELRT 0x890C /* delete routing table entry */
include/uapi/linux/spi/spidev.h+5−1
@@ -66,6 +66,9 @@ · 65 unmodified lines
66 * @delay_usecs: If nonzero, how long to delay after the last bit transfer66 * @delay_usecs: If nonzero, how long to delay after the last bit transfer
67 * before optionally deselecting the device before the next transfer.67 * before optionally deselecting the device before the next transfer.
68 * @cs_change: True to deselect device before starting the next transfer.68 * @cs_change: True to deselect device before starting the next transfer.
69 * @word_delay_usecs: If nonzero, how long to wait between words within one
70 * transfer. This property needs explicit support in the SPI controller,
71 * otherwise it is silently ignored.
69 *72 *
70 * This structure is mapped directly to the kernel spi_transfer structure;73 * This structure is mapped directly to the kernel spi_transfer structure;
71 * the fields have the same meanings, except of course that the pointers74 * the fields have the same meanings, except of course that the pointers
@@ -100,7 +103,8 @@ struct spi_ioc_transfer { · 28 unmodified lines
100 __u8 cs_change;103 __u8 cs_change;
101 __u8 tx_nbits;104 __u8 tx_nbits;
102 __u8 rx_nbits;105 __u8 rx_nbits;
103 __u16 pad;106 __u8 word_delay_usecs;
107 __u8 pad;
104 108
105 /* If the contents of 'struct spi_ioc_transfer' ever change109 /* If the contents of 'struct spi_ioc_transfer' ever change
106 * incompatibly, then the ioctl number (currently 0) must change;110 * incompatibly, then the ioctl number (currently 0) must change;
include/uapi/linux/switchtec_ioctl.h+12−1
@@ -50,7 +50,7 @@ struct switchtec_ioctl_flash_part_info { · 49 unmodified lines
50 __u32 active;50 __u32 active;
51};51};
52 52
53struct switchtec_ioctl_event_summary {53struct switchtec_ioctl_event_summary_legacy {
54 __u64 global;54 __u64 global;
55 __u64 part_bitmap;55 __u64 part_bitmap;
56 __u32 local_part;56 __u32 local_part;
@@ -59,6 +59,15 @@ struct switchtec_ioctl_event_summary { · 2 unmodified lines
59 __u32 pff[48];59 __u32 pff[48];
60};60};
61 61
62struct switchtec_ioctl_event_summary {
63 __u64 global;
64 __u64 part_bitmap;
65 __u32 local_part;
66 __u32 padding;
67 __u32 part[48];
68 __u32 pff[255];
69};
70
62#define SWITCHTEC_IOCTL_EVENT_STACK_ERROR 071#define SWITCHTEC_IOCTL_EVENT_STACK_ERROR 0
63#define SWITCHTEC_IOCTL_EVENT_PPU_ERROR 172#define SWITCHTEC_IOCTL_EVENT_PPU_ERROR 1
64#define SWITCHTEC_IOCTL_EVENT_ISP_ERROR 273#define SWITCHTEC_IOCTL_EVENT_ISP_ERROR 2
@@ -127,6 +136,8 @@ struct switchtec_ioctl_pff_port { · 62 unmodified lines
127 _IOWR('W', 0x41, struct switchtec_ioctl_flash_part_info)136 _IOWR('W', 0x41, struct switchtec_ioctl_flash_part_info)
128#define SWITCHTEC_IOCTL_EVENT_SUMMARY \137#define SWITCHTEC_IOCTL_EVENT_SUMMARY \
129 _IOR('W', 0x42, struct switchtec_ioctl_event_summary)138 _IOR('W', 0x42, struct switchtec_ioctl_event_summary)
139#define SWITCHTEC_IOCTL_EVENT_SUMMARY_LEGACY \
140 _IOR('W', 0x42, struct switchtec_ioctl_event_summary_legacy)
130#define SWITCHTEC_IOCTL_EVENT_CTL \141#define SWITCHTEC_IOCTL_EVENT_CTL \
131 _IOWR('W', 0x43, struct switchtec_ioctl_event_ctl)142 _IOWR('W', 0x43, struct switchtec_ioctl_event_ctl)
132#define SWITCHTEC_IOCTL_PFF_TO_PORT \143#define SWITCHTEC_IOCTL_PFF_TO_PORT \
include/uapi/linux/tcp.h+27−0
@@ -160,15 +160,42 @@ enum { · 159 unmodified lines
160#define TCPI_OPT_ECN_SEEN 16 /* we received at least one packet with ECT */160#define TCPI_OPT_ECN_SEEN 16 /* we received at least one packet with ECT */
161#define TCPI_OPT_SYN_DATA 32 /* SYN-ACK acked data in SYN sent or rcvd */161#define TCPI_OPT_SYN_DATA 32 /* SYN-ACK acked data in SYN sent or rcvd */
162 162
163/*
164 * Sender's congestion state indicating normal or abnormal situations
165 * in the last round of packets sent. The state is driven by the ACK
166 * information and timer events.
167 */
163enum tcp_ca_state {168enum tcp_ca_state {
169 /*
170 * Nothing bad has been observed recently.
171 * No apparent reordering, packet loss, or ECN marks.
172 */
164 TCP_CA_Open = 0,173 TCP_CA_Open = 0,
165#define TCPF_CA_Open (1<<TCP_CA_Open)174#define TCPF_CA_Open (1<<TCP_CA_Open)
175 /*
176 * The sender enters disordered state when it has received DUPACKs or
177 * SACKs in the last round of packets sent. This could be due to packet
178 * loss or reordering but needs further information to confirm packets
179 * have been lost.
180 */
166 TCP_CA_Disorder = 1,181 TCP_CA_Disorder = 1,
167#define TCPF_CA_Disorder (1<<TCP_CA_Disorder)182#define TCPF_CA_Disorder (1<<TCP_CA_Disorder)
183 /*
184 * The sender enters Congestion Window Reduction (CWR) state when it
185 * has received ACKs with ECN-ECE marks, or has experienced congestion
186 * or packet discard on the sender host (e.g. qdisc).
187 */
168 TCP_CA_CWR = 2,188 TCP_CA_CWR = 2,
169#define TCPF_CA_CWR (1<<TCP_CA_CWR)189#define TCPF_CA_CWR (1<<TCP_CA_CWR)
190 /*
191 * The sender is in fast recovery and retransmitting lost packets,
192 * typically triggered by ACK events.
193 */
170 TCP_CA_Recovery = 3,194 TCP_CA_Recovery = 3,
171#define TCPF_CA_Recovery (1<<TCP_CA_Recovery)195#define TCPF_CA_Recovery (1<<TCP_CA_Recovery)
196 /*
197 * The sender is in loss recovery triggered by retransmission timeout.
198 */
172 TCP_CA_Loss = 4199 TCP_CA_Loss = 4
173#define TCPF_CA_Loss (1<<TCP_CA_Loss)200#define TCPF_CA_Loss (1<<TCP_CA_Loss)
174};201};
include/uapi/linux/tipc.h+1−0
@@ -190,6 +190,7 @@ struct sockaddr_tipc { · 189 unmodified lines
190#define TIPC_MCAST_REPLICAST 134 /* Default: TIPC selects. No arg */190#define TIPC_MCAST_REPLICAST 134 /* Default: TIPC selects. No arg */
191#define TIPC_GROUP_JOIN 135 /* Takes struct tipc_group_req* */191#define TIPC_GROUP_JOIN 135 /* Takes struct tipc_group_req* */
192#define TIPC_GROUP_LEAVE 136 /* No argument */192#define TIPC_GROUP_LEAVE 136 /* No argument */
193#define TIPC_SOCK_RECVQ_USED 137 /* Default: none (read only) */
193 194
194/*195/*
195 * Flag values196 * Flag values
include/uapi/linux/tipc_netlink.h+2−0
@@ -281,6 +281,8 @@ enum { · 280 unmodified lines
281 TIPC_NLA_PROP_TOL, /* u32 */281 TIPC_NLA_PROP_TOL, /* u32 */
282 TIPC_NLA_PROP_WIN, /* u32 */282 TIPC_NLA_PROP_WIN, /* u32 */
283 TIPC_NLA_PROP_MTU, /* u32 */283 TIPC_NLA_PROP_MTU, /* u32 */
284 TIPC_NLA_PROP_BROADCAST, /* u32 */
285 TIPC_NLA_PROP_BROADCAST_RATIO, /* u32 */
284 286
285 __TIPC_NLA_PROP_MAX,287 __TIPC_NLA_PROP_MAX,
286 TIPC_NLA_PROP_MAX = __TIPC_NLA_PROP_MAX - 1288 TIPC_NLA_PROP_MAX = __TIPC_NLA_PROP_MAX - 1
include/uapi/linux/tls.h+15−0
@@ -70,6 +70,13 @@ · 69 unmodified lines
70#define TLS_CIPHER_AES_GCM_256_TAG_SIZE 1670#define TLS_CIPHER_AES_GCM_256_TAG_SIZE 16
71#define TLS_CIPHER_AES_GCM_256_REC_SEQ_SIZE 871#define TLS_CIPHER_AES_GCM_256_REC_SEQ_SIZE 8
72 72
73#define TLS_CIPHER_AES_CCM_128 53
74#define TLS_CIPHER_AES_CCM_128_IV_SIZE 8
75#define TLS_CIPHER_AES_CCM_128_KEY_SIZE 16
76#define TLS_CIPHER_AES_CCM_128_SALT_SIZE 4
77#define TLS_CIPHER_AES_CCM_128_TAG_SIZE 16
78#define TLS_CIPHER_AES_CCM_128_REC_SEQ_SIZE 8
79
73#define TLS_SET_RECORD_TYPE 180#define TLS_SET_RECORD_TYPE 1
74#define TLS_GET_RECORD_TYPE 281#define TLS_GET_RECORD_TYPE 2
75 82
@@ -94,4 +101,12 @@ struct tls12_crypto_info_aes_gcm_256 { · 18 unmodified lines
94 unsigned char rec_seq[TLS_CIPHER_AES_GCM_256_REC_SEQ_SIZE];101 unsigned char rec_seq[TLS_CIPHER_AES_GCM_256_REC_SEQ_SIZE];
95};102};
96 103
104struct tls12_crypto_info_aes_ccm_128 {
105 struct tls_crypto_info info;
106 unsigned char iv[TLS_CIPHER_AES_CCM_128_IV_SIZE];
107 unsigned char key[TLS_CIPHER_AES_CCM_128_KEY_SIZE];
108 unsigned char salt[TLS_CIPHER_AES_CCM_128_SALT_SIZE];
109 unsigned char rec_seq[TLS_CIPHER_AES_CCM_128_REC_SEQ_SIZE];
110};
111
97#endif /* _UAPI_LINUX_TLS_H */112#endif /* _UAPI_LINUX_TLS_H */
include/uapi/linux/v4l2-controls.h+8−0
@@ -404,6 +404,10 @@ enum v4l2_mpeg_video_multi_slice_mode { · 403 unmodified lines
404#define V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (V4L2_CID_MPEG_BASE+228)404#define V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (V4L2_CID_MPEG_BASE+228)
405#define V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (V4L2_CID_MPEG_BASE+229)405#define V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (V4L2_CID_MPEG_BASE+229)
406 406
407/* CIDs for the FWHT codec as used by the vicodec driver. */
408#define V4L2_CID_FWHT_I_FRAME_QP (V4L2_CID_MPEG_BASE + 290)
409#define V4L2_CID_FWHT_P_FRAME_QP (V4L2_CID_MPEG_BASE + 291)
410
407#define V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP (V4L2_CID_MPEG_BASE+300)411#define V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP (V4L2_CID_MPEG_BASE+300)
408#define V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP (V4L2_CID_MPEG_BASE+301)412#define V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP (V4L2_CID_MPEG_BASE+301)
409#define V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP (V4L2_CID_MPEG_BASE+302)413#define V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP (V4L2_CID_MPEG_BASE+302)
@@ -535,6 +539,10 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type { · 125 unmodified lines
535#define V4L2_CID_MPEG_VIDEO_H264_HIERARCHICAL_CODING_LAYER_QP (V4L2_CID_MPEG_BASE+382)539#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)540#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)541#define V4L2_CID_MPEG_VIDEO_H264_CHROMA_QP_INDEX_OFFSET (V4L2_CID_MPEG_BASE+384)
542#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MIN_QP (V4L2_CID_MPEG_BASE+385)
543#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_MAX_QP (V4L2_CID_MPEG_BASE+386)
544#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MIN_QP (V4L2_CID_MPEG_BASE+387)
545#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_MAX_QP (V4L2_CID_MPEG_BASE+388)
538#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (V4L2_CID_MPEG_BASE+400)546#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP (V4L2_CID_MPEG_BASE+400)
539#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (V4L2_CID_MPEG_BASE+401)547#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP (V4L2_CID_MPEG_BASE+401)
540#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (V4L2_CID_MPEG_BASE+402)548#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP (V4L2_CID_MPEG_BASE+402)
include/uapi/linux/vfio.h+4−0
@@ -353,6 +353,10 @@ struct vfio_region_gfx_edid { · 352 unmodified lines
353#define VFIO_DEVICE_GFX_LINK_STATE_DOWN 2353#define VFIO_DEVICE_GFX_LINK_STATE_DOWN 2
354};354};
355 355
356#define VFIO_REGION_TYPE_CCW (2)
357/* ccw sub-types */
358#define VFIO_REGION_SUBTYPE_CCW_ASYNC_CMD (1)
359
356/*360/*
357 * 10de vendor sub-type361 * 10de vendor sub-type
358 *362 *
include/uapi/linux/vfio_ccw.h+12−0
@@ -12,6 +12,7 @@ · 11 unmodified lines
12 12
13#include <linux/types.h>13#include <linux/types.h>
14 14
15/* used for START SUBCHANNEL, always present */
15struct ccw_io_region {16struct ccw_io_region {
16#define ORB_AREA_SIZE 1217#define ORB_AREA_SIZE 12
17 __u8 orb_area[ORB_AREA_SIZE];18 __u8 orb_area[ORB_AREA_SIZE];
@@ -22,4 +23,15 @@ struct ccw_io_region { · 4 unmodified lines
22 __u32 ret_code;23 __u32 ret_code;
23} __packed;24} __packed;
24 25
26/*
27 * used for processing commands that trigger asynchronous actions
28 * Note: this is controlled by a capability
29 */
30#define VFIO_CCW_ASYNC_CMD_HSCH (1 << 0)
31#define VFIO_CCW_ASYNC_CMD_CSCH (1 << 1)
32struct ccw_cmd_region {
33 __u32 command;
34 __u32 ret_code;
35} __packed;
36
25#endif37#endif
include/uapi/linux/videodev2.h+17−0
@@ -514,9 +514,21 @@ struct v4l2_pix_format { · 513 unmodified lines
514#define V4L2_PIX_FMT_RGB444 v4l2_fourcc('R', '4', '4', '4') /* 16 xxxxrrrr ggggbbbb */514#define V4L2_PIX_FMT_RGB444 v4l2_fourcc('R', '4', '4', '4') /* 16 xxxxrrrr ggggbbbb */
515#define V4L2_PIX_FMT_ARGB444 v4l2_fourcc('A', 'R', '1', '2') /* 16 aaaarrrr ggggbbbb */515#define V4L2_PIX_FMT_ARGB444 v4l2_fourcc('A', 'R', '1', '2') /* 16 aaaarrrr ggggbbbb */
516#define V4L2_PIX_FMT_XRGB444 v4l2_fourcc('X', 'R', '1', '2') /* 16 xxxxrrrr ggggbbbb */516#define V4L2_PIX_FMT_XRGB444 v4l2_fourcc('X', 'R', '1', '2') /* 16 xxxxrrrr ggggbbbb */
517#define V4L2_PIX_FMT_RGBA444 v4l2_fourcc('R', 'A', '1', '2') /* 16 rrrrgggg bbbbaaaa */
518#define V4L2_PIX_FMT_RGBX444 v4l2_fourcc('R', 'X', '1', '2') /* 16 rrrrgggg bbbbxxxx */
519#define V4L2_PIX_FMT_ABGR444 v4l2_fourcc('A', 'B', '1', '2') /* 16 aaaabbbb ggggrrrr */
520#define V4L2_PIX_FMT_XBGR444 v4l2_fourcc('X', 'B', '1', '2') /* 16 xxxxbbbb ggggrrrr */
521#define V4L2_PIX_FMT_BGRA444 v4l2_fourcc('B', 'A', '1', '2') /* 16 bbbbgggg rrrraaaa */
522#define V4L2_PIX_FMT_BGRX444 v4l2_fourcc('B', 'X', '1', '2') /* 16 bbbbgggg rrrrxxxx */
517#define V4L2_PIX_FMT_RGB555 v4l2_fourcc('R', 'G', 'B', 'O') /* 16 RGB-5-5-5 */523#define V4L2_PIX_FMT_RGB555 v4l2_fourcc('R', 'G', 'B', 'O') /* 16 RGB-5-5-5 */
518#define V4L2_PIX_FMT_ARGB555 v4l2_fourcc('A', 'R', '1', '5') /* 16 ARGB-1-5-5-5 */524#define V4L2_PIX_FMT_ARGB555 v4l2_fourcc('A', 'R', '1', '5') /* 16 ARGB-1-5-5-5 */
519#define V4L2_PIX_FMT_XRGB555 v4l2_fourcc('X', 'R', '1', '5') /* 16 XRGB-1-5-5-5 */525#define V4L2_PIX_FMT_XRGB555 v4l2_fourcc('X', 'R', '1', '5') /* 16 XRGB-1-5-5-5 */
526#define V4L2_PIX_FMT_RGBA555 v4l2_fourcc('R', 'A', '1', '5') /* 16 RGBA-5-5-5-1 */
527#define V4L2_PIX_FMT_RGBX555 v4l2_fourcc('R', 'X', '1', '5') /* 16 RGBX-5-5-5-1 */
528#define V4L2_PIX_FMT_ABGR555 v4l2_fourcc('A', 'B', '1', '5') /* 16 ABGR-1-5-5-5 */
529#define V4L2_PIX_FMT_XBGR555 v4l2_fourcc('X', 'B', '1', '5') /* 16 XBGR-1-5-5-5 */
530#define V4L2_PIX_FMT_BGRA555 v4l2_fourcc('B', 'A', '1', '5') /* 16 BGRA-5-5-5-1 */
531#define V4L2_PIX_FMT_BGRX555 v4l2_fourcc('B', 'X', '1', '5') /* 16 BGRX-5-5-5-1 */
520#define V4L2_PIX_FMT_RGB565 v4l2_fourcc('R', 'G', 'B', 'P') /* 16 RGB-5-6-5 */532#define V4L2_PIX_FMT_RGB565 v4l2_fourcc('R', 'G', 'B', 'P') /* 16 RGB-5-6-5 */
521#define V4L2_PIX_FMT_RGB555X v4l2_fourcc('R', 'G', 'B', 'Q') /* 16 RGB-5-5-5 BE */533#define V4L2_PIX_FMT_RGB555X v4l2_fourcc('R', 'G', 'B', 'Q') /* 16 RGB-5-5-5 BE */
522#define V4L2_PIX_FMT_ARGB555X v4l2_fourcc_be('A', 'R', '1', '5') /* 16 ARGB-5-5-5 BE */534#define V4L2_PIX_FMT_ARGB555X v4l2_fourcc_be('A', 'R', '1', '5') /* 16 ARGB-5-5-5 BE */
@@ -528,7 +540,11 @@ struct v4l2_pix_format { · 5 unmodified lines
528#define V4L2_PIX_FMT_BGR32 v4l2_fourcc('B', 'G', 'R', '4') /* 32 BGR-8-8-8-8 */540#define V4L2_PIX_FMT_BGR32 v4l2_fourcc('B', 'G', 'R', '4') /* 32 BGR-8-8-8-8 */
529#define V4L2_PIX_FMT_ABGR32 v4l2_fourcc('A', 'R', '2', '4') /* 32 BGRA-8-8-8-8 */541#define V4L2_PIX_FMT_ABGR32 v4l2_fourcc('A', 'R', '2', '4') /* 32 BGRA-8-8-8-8 */
530#define V4L2_PIX_FMT_XBGR32 v4l2_fourcc('X', 'R', '2', '4') /* 32 BGRX-8-8-8-8 */542#define V4L2_PIX_FMT_XBGR32 v4l2_fourcc('X', 'R', '2', '4') /* 32 BGRX-8-8-8-8 */
543#define V4L2_PIX_FMT_BGRA32 v4l2_fourcc('R', 'A', '2', '4') /* 32 ABGR-8-8-8-8 */
544#define V4L2_PIX_FMT_BGRX32 v4l2_fourcc('R', 'X', '2', '4') /* 32 XBGR-8-8-8-8 */
531#define V4L2_PIX_FMT_RGB32 v4l2_fourcc('R', 'G', 'B', '4') /* 32 RGB-8-8-8-8 */545#define V4L2_PIX_FMT_RGB32 v4l2_fourcc('R', 'G', 'B', '4') /* 32 RGB-8-8-8-8 */
546#define V4L2_PIX_FMT_RGBA32 v4l2_fourcc('A', 'B', '2', '4') /* 32 RGBA-8-8-8-8 */
547#define V4L2_PIX_FMT_RGBX32 v4l2_fourcc('X', 'B', '2', '4') /* 32 RGBX-8-8-8-8 */
532#define V4L2_PIX_FMT_ARGB32 v4l2_fourcc('B', 'A', '2', '4') /* 32 ARGB-8-8-8-8 */548#define V4L2_PIX_FMT_ARGB32 v4l2_fourcc('B', 'A', '2', '4') /* 32 ARGB-8-8-8-8 */
533#define V4L2_PIX_FMT_XRGB32 v4l2_fourcc('B', 'X', '2', '4') /* 32 XRGB-8-8-8-8 */549#define V4L2_PIX_FMT_XRGB32 v4l2_fourcc('B', 'X', '2', '4') /* 32 XRGB-8-8-8-8 */
534 550
@@ -669,6 +685,7 @@ struct v4l2_pix_format { · 134 unmodified lines
669#define V4L2_PIX_FMT_VP9 v4l2_fourcc('V', 'P', '9', '0') /* VP9 */685#define V4L2_PIX_FMT_VP9 v4l2_fourcc('V', 'P', '9', '0') /* VP9 */
670#define V4L2_PIX_FMT_HEVC v4l2_fourcc('H', 'E', 'V', 'C') /* HEVC aka H.265 */686#define V4L2_PIX_FMT_HEVC v4l2_fourcc('H', 'E', 'V', 'C') /* HEVC aka H.265 */
671#define V4L2_PIX_FMT_FWHT v4l2_fourcc('F', 'W', 'H', 'T') /* Fast Walsh Hadamard Transform (vicodec) */687#define V4L2_PIX_FMT_FWHT v4l2_fourcc('F', 'W', 'H', 'T') /* Fast Walsh Hadamard Transform (vicodec) */
688#define V4L2_PIX_FMT_FWHT_STATELESS v4l2_fourcc('S', 'F', 'W', 'H') /* Stateless FWHT (vicodec) */
672 689
673/* Vendor-specific formats */690/* Vendor-specific formats */
674#define V4L2_PIX_FMT_CPIA1 v4l2_fourcc('C', 'P', 'I', 'A') /* cpia1 YUV */691#define V4L2_PIX_FMT_CPIA1 v4l2_fourcc('C', 'P', 'I', 'A') /* cpia1 YUV */
include/uapi/misc/habanalabs.h+149−12
@@ -20,8 +20,8 @@ · 19 unmodified lines
20/*20/*
21 * Queue Numbering21 * Queue Numbering
22 *22 *
23 * The external queues (DMA channels + CPU) MUST be before the internal queues23 * The external queues (PCI DMA channels) MUST be before the internal queues
24 * and each group (DMA channels + CPU and internal) must be contiguous inside24 * and each group (PCI DMA channels and internal) must be contiguous inside
25 * itself but there can be a gap between the two groups (although not25 * itself but there can be a gap between the two groups (although not
26 * recommended)26 * recommended)
27 */27 */
@@ -33,7 +33,7 @@ enum goya_queue_id { · 5 unmodified lines
33 GOYA_QUEUE_ID_DMA_3,33 GOYA_QUEUE_ID_DMA_3,
34 GOYA_QUEUE_ID_DMA_4,34 GOYA_QUEUE_ID_DMA_4,
35 GOYA_QUEUE_ID_CPU_PQ,35 GOYA_QUEUE_ID_CPU_PQ,
36 GOYA_QUEUE_ID_MME,36 GOYA_QUEUE_ID_MME, /* Internal queues start here */
37 GOYA_QUEUE_ID_TPC0,37 GOYA_QUEUE_ID_TPC0,
38 GOYA_QUEUE_ID_TPC1,38 GOYA_QUEUE_ID_TPC1,
39 GOYA_QUEUE_ID_TPC2,39 GOYA_QUEUE_ID_TPC2,
@@ -45,11 +45,18 @@ enum goya_queue_id { · 5 unmodified lines
45 GOYA_QUEUE_ID_SIZE45 GOYA_QUEUE_ID_SIZE
46};46};
47 47
48enum hl_device_status {
49 HL_DEVICE_STATUS_OPERATIONAL,
50 HL_DEVICE_STATUS_IN_RESET,
51 HL_DEVICE_STATUS_MALFUNCTION
52};
53
48/* Opcode for management ioctl */54/* Opcode for management ioctl */
49#define HL_INFO_HW_IP_INFO 055#define HL_INFO_HW_IP_INFO 0
50#define HL_INFO_HW_EVENTS 156#define HL_INFO_HW_EVENTS 1
51#define HL_INFO_DRAM_USAGE 257#define HL_INFO_DRAM_USAGE 2
52#define HL_INFO_HW_IDLE 358#define HL_INFO_HW_IDLE 3
59#define HL_INFO_DEVICE_STATUS 4
53 60
54#define HL_INFO_VERSION_MAX_LEN 12861#define HL_INFO_VERSION_MAX_LEN 128
55 62
@@ -82,6 +89,11 @@ struct hl_info_hw_idle { · 26 unmodified lines
82 __u32 pad;89 __u32 pad;
83};90};
84 91
92struct hl_info_device_status {
93 __u32 status;
94 __u32 pad;
95};
96
85struct hl_info_args {97struct hl_info_args {
86 /* Location of relevant struct in userspace */98 /* Location of relevant struct in userspace */
87 __u64 return_pointer;99 __u64 return_pointer;
@@ -181,7 +193,10 @@ struct hl_cs_in { · 93 unmodified lines
181};193};
182 194
183struct hl_cs_out {195struct hl_cs_out {
184 /* this holds the sequence number of the CS to pass to wait ioctl */196 /*
197 * seq holds the sequence number of the CS to pass to wait ioctl. All
198 * values are valid except for 0 and ULLONG_MAX
199 */
185 __u64 seq;200 __u64 seq;
186 /* HL_CS_STATUS_* */201 /* HL_CS_STATUS_* */
187 __u32 status;202 __u32 status;
@@ -320,6 +335,110 @@ union hl_mem_args { · 132 unmodified lines
320 struct hl_mem_out out;335 struct hl_mem_out out;
321};336};
322 337
338#define HL_DEBUG_MAX_AUX_VALUES 10
339
340struct hl_debug_params_etr {
341 /* Address in memory to allocate buffer */
342 __u64 buffer_address;
343
344 /* Size of buffer to allocate */
345 __u64 buffer_size;
346
347 /* Sink operation mode: SW fifo, HW fifo, Circular buffer */
348 __u32 sink_mode;
349 __u32 pad;
350};
351
352struct hl_debug_params_etf {
353 /* Address in memory to allocate buffer */
354 __u64 buffer_address;
355
356 /* Size of buffer to allocate */
357 __u64 buffer_size;
358
359 /* Sink operation mode: SW fifo, HW fifo, Circular buffer */
360 __u32 sink_mode;
361 __u32 pad;
362};
363
364struct hl_debug_params_stm {
365 /* Two bit masks for HW event and Stimulus Port */
366 __u64 he_mask;
367 __u64 sp_mask;
368
369 /* Trace source ID */
370 __u32 id;
371
372 /* Frequency for the timestamp register */
373 __u32 frequency;
374};
375
376struct hl_debug_params_bmon {
377 /* Two address ranges that the user can request to filter */
378 __u64 start_addr0;
379 __u64 addr_mask0;
380
381 __u64 start_addr1;
382 __u64 addr_mask1;
383
384 /* Capture window configuration */
385 __u32 bw_win;
386 __u32 win_capture;
387
388 /* Trace source ID */
389 __u32 id;
390 __u32 pad;
391};
392
393struct hl_debug_params_spmu {
394 /* Event types selection */
395 __u64 event_types[HL_DEBUG_MAX_AUX_VALUES];
396
397 /* Number of event types selection */
398 __u32 event_types_num;
399 __u32 pad;
400};
401
402/* Opcode for ETR component */
403#define HL_DEBUG_OP_ETR 0
404/* Opcode for ETF component */
405#define HL_DEBUG_OP_ETF 1
406/* Opcode for STM component */
407#define HL_DEBUG_OP_STM 2
408/* Opcode for FUNNEL component */
409#define HL_DEBUG_OP_FUNNEL 3
410/* Opcode for BMON component */
411#define HL_DEBUG_OP_BMON 4
412/* Opcode for SPMU component */
413#define HL_DEBUG_OP_SPMU 5
414/* Opcode for timestamp */
415#define HL_DEBUG_OP_TIMESTAMP 6
416
417struct hl_debug_args {
418 /*
419 * Pointer to user input structure.
420 * This field is relevant to specific opcodes.
421 */
422 __u64 input_ptr;
423 /* Pointer to user output structure */
424 __u64 output_ptr;
425 /* Size of user input structure */
426 __u32 input_size;
427 /* Size of user output structure */
428 __u32 output_size;
429 /* HL_DEBUG_OP_* */
430 __u32 op;
431 /*
432 * Register index in the component, taken from the debug_regs_index enum
433 * in the various ASIC header files
434 */
435 __u32 reg_idx;
436 /* Enable/disable */
437 __u32 enable;
438 /* Context ID - Currently not in use */
439 __u32 ctx_id;
440};
441
323/*442/*
324 * Various information operations such as:443 * Various information operations such as:
325 * - H/W IP information444 * - H/W IP information
@@ -361,6 +480,12 @@ union hl_mem_args { · 35 unmodified lines
361 * Each JOB will be enqueued on a specific queue, according to the user's input.480 * 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.481 * There can be more then one JOB per queue.
363 *482 *
483 * The CS IOCTL will receive three sets of JOBS. One set is for "restore" phase,
484 * a second set is for "execution" phase and a third set is for "store" phase.
485 * The JOBS on the "restore" phase are enqueued only after context-switch
486 * (or if its the first CS for this context). The user can also order the
487 * driver to run the "restore" phase explicitly
488 *
364 * There are two types of queues - external and internal. External queues489 * 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 are490 * 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 only491 * internal. The driver will get completion notifications from the device only
@@ -377,19 +502,18 @@ union hl_mem_args { · 10 unmodified lines
377 * relevant queues. Therefore, the user mustn't assume the CS has been completed502 * relevant queues. Therefore, the user mustn't assume the CS has been completed
378 * or has even started to execute.503 * or has even started to execute.
379 *504 *
380 * Upon successful enqueue, the IOCTL returns an opaque handle which the user505 * Upon successful enqueue, the IOCTL returns a sequence number which the user
381 * can use with the "Wait for CS" IOCTL to check whether the handle's CS506 * 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 JOBS507 * 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 might508 * which can execute AFTER the external JOBS have finished, the driver might
384 * report that the CS has finished executing BEFORE the internal JOBS have509 * report that the CS has finished executing BEFORE the internal JOBS have
385 * actually finish executing.510 * actually finish executing.
386 *511 *
387 * The CS IOCTL will receive three sets of JOBS. One set is for "restore" phase,512 * Even though the sequence number increments per CS, the user can NOT
388 * a second set is for "execution" phase and a third set is for "store" phase.513 * automatically assume that if CS with sequence number N finished, then CS
389 * The JOBS on the "restore" phase are enqueued only after context-switch514 * with sequence number N-1 also finished. The user can make this assumption if
390 * (or if its the first CS for this context). The user can also order the515 * and only if CS N and CS N-1 are exactly the same (same CBs for the same
391 * driver to run the "restore" phase explicitly516 * queues).
392 *
393 */517 */
394#define HL_IOCTL_CS \518#define HL_IOCTL_CS \
395 _IOWR('H', 0x03, union hl_cs_args)519 _IOWR('H', 0x03, union hl_cs_args)
@@ -444,7 +568,20 @@ union hl_mem_args { · 48 unmodified lines
444#define HL_IOCTL_MEMORY \568#define HL_IOCTL_MEMORY \
445 _IOWR('H', 0x05, union hl_mem_args)569 _IOWR('H', 0x05, union hl_mem_args)
446 570
571/*
572 * Debug
573 * - Enable/disable the ETR/ETF/FUNNEL/STM/BMON/SPMU debug traces
574 *
575 * This IOCTL allows the user to get debug traces from the chip.
576 *
577 * The user needs to provide the register index and essential data such as
578 * buffer address and size.
579 *
580 */
581#define HL_IOCTL_DEBUG \
582 _IOWR('H', 0x06, struct hl_debug_args)
583
447#define HL_COMMAND_START 0x01584#define HL_COMMAND_START 0x01
448#define HL_COMMAND_END 0x06585#define HL_COMMAND_END 0x07
449 586
450#endif /* HABANALABS_H_ */587#endif /* HABANALABS_H_ */
include/uapi/rdma/efa-abi.h+101−0
@@ -0,0 +1,101 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause) */
2/*
3 * Copyright 2018-2019 Amazon.com, Inc. or its affiliates. All rights reserved.
4 */
5
6#ifndef EFA_ABI_USER_H
7#define EFA_ABI_USER_H
8
9#include <linux/types.h>
10
11/*
12 * Increment this value if any changes that break userspace ABI
13 * compatibility are made.
14 */
15#define EFA_UVERBS_ABI_VERSION 1
16
17/*
18 * Keep structs aligned to 8 bytes.
19 * Keep reserved fields as arrays of __u8 named reserved_XXX where XXX is the
20 * hex bit offset of the field.
21 */
22
23enum efa_ibv_user_cmds_supp_udata {
24 EFA_USER_CMDS_SUPP_UDATA_QUERY_DEVICE = 1 << 0,
25 EFA_USER_CMDS_SUPP_UDATA_CREATE_AH = 1 << 1,
26};
27
28struct efa_ibv_alloc_ucontext_resp {
29 __u32 comp_mask;
30 __u32 cmds_supp_udata_mask;
31 __u16 sub_cqs_per_cq;
32 __u16 inline_buf_size;
33 __u32 max_llq_size; /* bytes */
34};
35
36struct efa_ibv_alloc_pd_resp {
37 __u32 comp_mask;
38 __u16 pdn;
39 __u8 reserved_30[2];
40};
41
42struct efa_ibv_create_cq {
43 __u32 comp_mask;
44 __u32 cq_entry_size;
45 __u16 num_sub_cqs;
46 __u8 reserved_50[6];
47};
48
49struct efa_ibv_create_cq_resp {
50 __u32 comp_mask;
51 __u8 reserved_20[4];
52 __aligned_u64 q_mmap_key;
53 __aligned_u64 q_mmap_size;
54 __u16 cq_idx;
55 __u8 reserved_d0[6];
56};
57
58enum {
59 EFA_QP_DRIVER_TYPE_SRD = 0,
60};
61
62struct efa_ibv_create_qp {
63 __u32 comp_mask;
64 __u32 rq_ring_size; /* bytes */
65 __u32 sq_ring_size; /* bytes */
66 __u32 driver_qp_type;
67};
68
69struct efa_ibv_create_qp_resp {
70 __u32 comp_mask;
71 /* the offset inside the page of the rq db */
72 __u32 rq_db_offset;
73 /* the offset inside the page of the sq db */
74 __u32 sq_db_offset;
75 /* the offset inside the page of descriptors buffer */
76 __u32 llq_desc_offset;
77 __aligned_u64 rq_mmap_key;
78 __aligned_u64 rq_mmap_size;
79 __aligned_u64 rq_db_mmap_key;
80 __aligned_u64 sq_db_mmap_key;
81 __aligned_u64 llq_desc_mmap_key;
82 __u16 send_sub_cq_idx;
83 __u16 recv_sub_cq_idx;
84 __u8 reserved_1e0[4];
85};
86
87struct efa_ibv_create_ah_resp {
88 __u32 comp_mask;
89 __u16 efa_address_handle;
90 __u8 reserved_30[2];
91};
92
93struct efa_ibv_ex_query_device_resp {
94 __u32 comp_mask;
95 __u32 max_sq_wr;
96 __u32 max_rq_wr;
97 __u16 max_sq_sge;
98 __u16 max_rq_sge;
99};
100
101#endif /* EFA_ABI_USER_H */
include/uapi/rdma/mlx5-abi.h+3−0
@@ -238,6 +238,7 @@ enum mlx5_ib_query_dev_resp_flags { · 237 unmodified lines
238 MLX5_IB_QUERY_DEV_RESP_FLAGS_CQE_128B_COMP = 1 << 0,238 MLX5_IB_QUERY_DEV_RESP_FLAGS_CQE_128B_COMP = 1 << 0,
239 MLX5_IB_QUERY_DEV_RESP_FLAGS_CQE_128B_PAD = 1 << 1,239 MLX5_IB_QUERY_DEV_RESP_FLAGS_CQE_128B_PAD = 1 << 1,
240 MLX5_IB_QUERY_DEV_RESP_PACKET_BASED_CREDIT_MODE = 1 << 2,240 MLX5_IB_QUERY_DEV_RESP_PACKET_BASED_CREDIT_MODE = 1 << 2,
241 MLX5_IB_QUERY_DEV_RESP_FLAGS_SCAT2CQE_DCT = 1 << 3,
241};242};
242 243
243enum mlx5_ib_tunnel_offloads {244enum mlx5_ib_tunnel_offloads {
@@ -359,6 +360,7 @@ enum mlx5_ib_create_qp_resp_mask { · 115 unmodified lines
359 MLX5_IB_CREATE_QP_RESP_MASK_TISN = 1UL << 1,360 MLX5_IB_CREATE_QP_RESP_MASK_TISN = 1UL << 1,
360 MLX5_IB_CREATE_QP_RESP_MASK_RQN = 1UL << 2,361 MLX5_IB_CREATE_QP_RESP_MASK_RQN = 1UL << 2,
361 MLX5_IB_CREATE_QP_RESP_MASK_SQN = 1UL << 3,362 MLX5_IB_CREATE_QP_RESP_MASK_SQN = 1UL << 3,
363 MLX5_IB_CREATE_QP_RESP_MASK_TIR_ICM_ADDR = 1UL << 4,
362};364};
363 365
364struct mlx5_ib_create_qp_resp {366struct mlx5_ib_create_qp_resp {
@@ -370,6 +372,7 @@ struct mlx5_ib_create_qp_resp { · 5 unmodified lines
370 __u32 rqn;372 __u32 rqn;
371 __u32 sqn;373 __u32 sqn;
372 __u32 reserved1;374 __u32 reserved1;
375 __u64 tir_icm_addr;
373};376};
374 377
375struct mlx5_ib_alloc_mw {378struct mlx5_ib_alloc_mw {
include/uapi/rdma/mlx5_user_ioctl_cmds.h+2−0
@@ -44,6 +44,7 @@ enum mlx5_ib_create_flow_action_attrs { · 43 unmodified lines
44enum mlx5_ib_alloc_dm_attrs {44enum mlx5_ib_alloc_dm_attrs {
45 MLX5_IB_ATTR_ALLOC_DM_RESP_START_OFFSET = (1U << UVERBS_ID_NS_SHIFT),45 MLX5_IB_ATTR_ALLOC_DM_RESP_START_OFFSET = (1U << UVERBS_ID_NS_SHIFT),
46 MLX5_IB_ATTR_ALLOC_DM_RESP_PAGE_INDEX,46 MLX5_IB_ATTR_ALLOC_DM_RESP_PAGE_INDEX,
47 MLX5_IB_ATTR_ALLOC_DM_REQ_TYPE,
47};48};
48 49
49enum mlx5_ib_devx_methods {50enum mlx5_ib_devx_methods {
@@ -144,6 +145,7 @@ enum mlx5_ib_flow_matcher_create_attrs { · 94 unmodified lines
144 MLX5_IB_ATTR_FLOW_MATCHER_FLOW_TYPE,145 MLX5_IB_ATTR_FLOW_MATCHER_FLOW_TYPE,
145 MLX5_IB_ATTR_FLOW_MATCHER_MATCH_CRITERIA,146 MLX5_IB_ATTR_FLOW_MATCHER_MATCH_CRITERIA,
146 MLX5_IB_ATTR_FLOW_MATCHER_FLOW_FLAGS,147 MLX5_IB_ATTR_FLOW_MATCHER_FLOW_FLAGS,
148 MLX5_IB_ATTR_FLOW_MATCHER_FT_TYPE,
147};149};
148 150
149enum mlx5_ib_flow_matcher_destroy_attrs {151enum mlx5_ib_flow_matcher_destroy_attrs {
include/uapi/rdma/mlx5_user_ioctl_verbs.h+7−0
@@ -42,6 +42,7 @@ enum mlx5_ib_uapi_flow_action_flags { · 41 unmodified lines
42enum mlx5_ib_uapi_flow_table_type {42enum mlx5_ib_uapi_flow_table_type {
43 MLX5_IB_UAPI_FLOW_TABLE_TYPE_NIC_RX = 0x0,43 MLX5_IB_UAPI_FLOW_TABLE_TYPE_NIC_RX = 0x0,
44 MLX5_IB_UAPI_FLOW_TABLE_TYPE_NIC_TX = 0x1,44 MLX5_IB_UAPI_FLOW_TABLE_TYPE_NIC_TX = 0x1,
45 MLX5_IB_UAPI_FLOW_TABLE_TYPE_FDB = 0x2,
45};46};
46 47
47enum mlx5_ib_uapi_flow_action_packet_reformat_type {48enum mlx5_ib_uapi_flow_action_packet_reformat_type {
@@ -56,5 +57,11 @@ struct mlx5_ib_uapi_devx_async_cmd_hdr { · 8 unmodified lines
56 __u8 out_data[];57 __u8 out_data[];
57};58};
58 59
60enum mlx5_ib_uapi_dm_type {
61 MLX5_IB_UAPI_DM_TYPE_MEMIC,
62 MLX5_IB_UAPI_DM_TYPE_STEERING_SW_ICM,
63 MLX5_IB_UAPI_DM_TYPE_HEADER_MODIFY_SW_ICM,
64};
65
59#endif66#endif
60 67
include/uapi/rdma/rdma_netlink.h+19−12
@@ -49,17 +49,6 @@ enum { · 48 unmodified lines
49 RDMA_NL_IWPM_NUM_OPS49 RDMA_NL_IWPM_NUM_OPS
50};50};
51 51
52struct rdma_cm_id_stats {
53 __u32 qp_num;
54 __u32 bound_dev_if;
55 __u32 port_space;
56 __s32 pid;
57 __u8 cm_state;
58 __u8 node_type;
59 __u8 port_num;
60 __u8 qp_type;
61};
62
63enum {52enum {
64 IWPM_NLA_REG_PID_UNSPEC = 0,53 IWPM_NLA_REG_PID_UNSPEC = 0,
65 IWPM_NLA_REG_PID_SEQ,54 IWPM_NLA_REG_PID_SEQ,
@@ -261,7 +250,10 @@ enum rdma_nldev_command { · 195 unmodified lines
261 250
262 RDMA_NLDEV_CMD_PORT_GET, /* can dump */251 RDMA_NLDEV_CMD_PORT_GET, /* can dump */
263 252
264 /* 6 - 8 are free to use */253 RDMA_NLDEV_CMD_SYS_GET,
254 RDMA_NLDEV_CMD_SYS_SET,
255
256 /* 8 is free to use */
265 257
266 RDMA_NLDEV_CMD_RES_GET = 9, /* can dump */258 RDMA_NLDEV_CMD_RES_GET = 9, /* can dump */
267 259
@@ -472,6 +464,21 @@ enum rdma_nldev_attr { · 204 unmodified lines
472 */464 */
473 RDMA_NLDEV_ATTR_LINK_TYPE, /* string */465 RDMA_NLDEV_ATTR_LINK_TYPE, /* string */
474 466
467 /*
468 * net namespace mode for rdma subsystem:
469 * either shared or exclusive among multiple net namespaces.
470 */
471 RDMA_NLDEV_SYS_ATTR_NETNS_MODE, /* u8 */
472 /*
473 * Device protocol, e.g. ib, iw, usnic, roce and opa
474 */
475 RDMA_NLDEV_ATTR_DEV_PROTOCOL, /* string */
476
477 /*
478 * File descriptor handle of the net namespace object
479 */
480 RDMA_NLDEV_NET_NS_FD, /* u32 */
481
475 /*482 /*
476 * Always the end483 * Always the end
477 */484 */
include/uapi/rdma/rdma_user_ioctl_cmds.h+1−0
@@ -102,6 +102,7 @@ enum rdma_driver_id { · 101 unmodified lines
102 RDMA_DRIVER_RXE,102 RDMA_DRIVER_RXE,
103 RDMA_DRIVER_HFI1,103 RDMA_DRIVER_HFI1,
104 RDMA_DRIVER_QIB,104 RDMA_DRIVER_QIB,
105 RDMA_DRIVER_EFA,
105};106};
106 107
107#endif108#endif
include/uapi/scsi/fc/fc_els.h+33−0
@@ -52,6 +52,7 @@ enum fc_els_cmd { · 51 unmodified lines
52 ELS_RRQ = 0x12, /* reinstate recovery qualifier */52 ELS_RRQ = 0x12, /* reinstate recovery qualifier */
53 ELS_REC = 0x13, /* read exchange concise */53 ELS_REC = 0x13, /* read exchange concise */
54 ELS_SRR = 0x14, /* sequence retransmission request */54 ELS_SRR = 0x14, /* sequence retransmission request */
55 ELS_FPIN = 0x16, /* Fabric Performance Impact Notification */
55 ELS_PRLI = 0x20, /* process login */56 ELS_PRLI = 0x20, /* process login */
56 ELS_PRLO = 0x21, /* process logout */57 ELS_PRLO = 0x21, /* process logout */
57 ELS_SCN = 0x22, /* state change notification */58 ELS_SCN = 0x22, /* state change notification */
@@ -119,6 +120,7 @@ enum fc_els_cmd { · 61 unmodified lines
119 [ELS_RRQ] = "RRQ", \120 [ELS_RRQ] = "RRQ", \
120 [ELS_REC] = "REC", \121 [ELS_REC] = "REC", \
121 [ELS_SRR] = "SRR", \122 [ELS_SRR] = "SRR", \
123 [ELS_FPIN] = "FPIN", \
122 [ELS_PRLI] = "PRLI", \124 [ELS_PRLI] = "PRLI", \
123 [ELS_PRLO] = "PRLO", \125 [ELS_PRLO] = "PRLO", \
124 [ELS_SCN] = "SCN", \126 [ELS_SCN] = "SCN", \
@@ -829,4 +831,35 @@ enum fc_els_clid_ic { · 704 unmodified lines
829 ELS_CLID_IC_LIP = 8, /* receiving LIP */831 ELS_CLID_IC_LIP = 8, /* receiving LIP */
830};832};
831 833
834
835/*
836 * Fabric Notification Descriptor Tag values
837 */
838enum fc_fn_dtag {
839 ELS_FN_DTAG_LNK_INTEGRITY = 0x00020001, /* Link Integrity */
840 ELS_FN_DTAG_PEER_CONGEST = 0x00020003, /* Peer Congestion */
841 ELS_FN_DTAG_CONGESTION = 0x00020004, /* Congestion */
842};
843
844/*
845 * Fabric Notification Descriptor
846 */
847struct fc_fn_desc {
848 __be32 fn_desc_tag; /* Notification Descriptor Tag */
849 __be32 fn_desc_value_len; /* Length of Descriptor Value field
850 * (in bytes)
851 */
852 __u8 fn_desc_value[0]; /* Descriptor Value */
853};
854
855/*
856 * ELS_FPIN - Fabric Performance Impact Notification
857 */
858struct fc_els_fpin {
859 __u8 fpin_cmd; /* command (0x16) */
860 __u8 fpin_zero[3]; /* specified as zero - part of cmd */
861 __be32 fpin_desc_cnt; /* count of descriptors */
862 struct fc_fn_desc fpin_desc[0]; /* Descriptor list */
863};
864
832#endif /* _FC_ELS_H_ */865#endif /* _FC_ELS_H_ */
include/uapi/sound/sof/abi.h+62−0
@@ -0,0 +1,62 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 */
8
9/**
10 * SOF ABI versioning is based on Semantic Versioning where we have a given
11 * MAJOR.MINOR.PATCH version number. See https://semver.org/
12 *
13 * Rules for incrementing or changing version :-
14 *
15 * 1) Increment MAJOR version if you make incompatible API changes. MINOR and
16 * PATCH should be reset to 0.
17 *
18 * 2) Increment MINOR version if you add backwards compatible features or
19 * changes. PATCH should be reset to 0.
20 *
21 * 3) Increment PATCH version if you add backwards compatible bug fixes.
22 */
23
24#ifndef __INCLUDE_UAPI_SOUND_SOF_ABI_H__
25#define __INCLUDE_UAPI_SOUND_SOF_ABI_H__
26
27/* SOF ABI version major, minor and patch numbers */
28#define SOF_ABI_MAJOR 3
29#define SOF_ABI_MINOR 4
30#define SOF_ABI_PATCH 0
31
32/* SOF ABI version number. Format within 32bit word is MMmmmppp */
33#define SOF_ABI_MAJOR_SHIFT 24
34#define SOF_ABI_MAJOR_MASK 0xff
35#define SOF_ABI_MINOR_SHIFT 12
36#define SOF_ABI_MINOR_MASK 0xfff
37#define SOF_ABI_PATCH_SHIFT 0
38#define SOF_ABI_PATCH_MASK 0xfff
39
40#define SOF_ABI_VER(major, minor, patch) \
41 (((major) << SOF_ABI_MAJOR_SHIFT) | \
42 ((minor) << SOF_ABI_MINOR_SHIFT) | \
43 ((patch) << SOF_ABI_PATCH_SHIFT))
44
45#define SOF_ABI_VERSION_MAJOR(version) \
46 (((version) >> SOF_ABI_MAJOR_SHIFT) & SOF_ABI_MAJOR_MASK)
47#define SOF_ABI_VERSION_MINOR(version) \
48 (((version) >> SOF_ABI_MINOR_SHIFT) & SOF_ABI_MINOR_MASK)
49#define SOF_ABI_VERSION_PATCH(version) \
50 (((version) >> SOF_ABI_PATCH_SHIFT) & SOF_ABI_PATCH_MASK)
51
52#define SOF_ABI_VERSION_INCOMPATIBLE(sof_ver, client_ver) \
53 (SOF_ABI_VERSION_MAJOR((sof_ver)) != \
54 SOF_ABI_VERSION_MAJOR((client_ver)) \
55 )
56
57#define SOF_ABI_VERSION SOF_ABI_VER(SOF_ABI_MAJOR, SOF_ABI_MINOR, SOF_ABI_PATCH)
58
59/* SOF ABI magic number "SOF\0". */
60#define SOF_ABI_MAGIC 0x00464F53
61
62#endif
include/uapi/sound/sof/eq.h+172−0
@@ -0,0 +1,172 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 */
8
9#ifndef __INCLUDE_UAPI_SOUND_SOF_USER_EQ_H__
10#define __INCLUDE_UAPI_SOUND_SOF_USER_EQ_H__
11
12/* FIR EQ type */
13
14#define SOF_EQ_FIR_IDX_SWITCH 0
15
16#define SOF_EQ_FIR_MAX_SIZE 4096 /* Max size allowed for coef data in bytes */
17
18#define SOF_EQ_FIR_MAX_LENGTH 192 /* Max length for individual filter */
19
20#define SOF_EQ_FIR_MAX_RESPONSES 8 /* A blob can define max 8 FIR EQs */
21
22/*
23 * eq_fir_configuration data structure contains this information
24 * uint32_t size
25 * This is the number of bytes need to store the received EQ
26 * configuration.
27 * uint16_t channels_in_config
28 * This describes the number of channels in this EQ config data. It
29 * can be different from PLATFORM_MAX_CHANNELS.
30 * uint16_t number_of_responses
31 * 0=no responses, 1=one response defined, 2=two responses defined, etc.
32 * int16_t data[]
33 * assign_response[channels_in_config]
34 * 0 = use first response, 1 = use 2nd response, etc.
35 * E.g. {0, 0, 0, 0, 1, 1, 1, 1} would apply to channels 0-3 the
36 * same first defined response and for to channels 4-7 the second.
37 * coef_data[]
38 * Repeated data
39 * { filter_length, output_shift, h[] }
40 * for every EQ response defined where vector h has filter_length
41 * number of coefficients. Coefficients in h[] are in Q1.15 format.
42 * E.g. 16384 (Q1.15) = 0.5. The shifts are number of right shifts.
43 *
44 * NOTE: The channels_in_config must be even to have coef_data aligned to
45 * 32 bit word in RAM. Therefore a mono EQ assign must be duplicated to 2ch
46 * even if it would never used. Similarly a 5ch EQ assign must be increased
47 * to 6ch. EQ init will return an error if this is not met.
48 *
49 * NOTE: The filter_length must be multiple of four. Therefore the filter must
50 * be padded from the end with zeros have this condition met.
51 */
52
53struct sof_eq_fir_config {
54 uint32_t size;
55 uint16_t channels_in_config;
56 uint16_t number_of_responses;
57
58 /* reserved */
59 uint32_t reserved[4];
60
61 int16_t data[];
62} __packed;
63
64struct sof_eq_fir_coef_data {
65 int16_t length; /* Number of FIR taps */
66 int16_t out_shift; /* Amount of right shifts at output */
67
68 /* reserved */
69 uint32_t reserved[4];
70
71 int16_t coef[]; /* FIR coefficients */
72} __packed;
73
74/* In the struct above there's two 16 bit words (length, shift) and four
75 * reserved 32 bit words before the actual FIR coefficients. This information
76 * is used in parsing of the configuration blob.
77 */
78#define SOF_EQ_FIR_COEF_NHEADER \
79 (sizeof(struct sof_eq_fir_coef_data) / sizeof(int16_t))
80
81/* IIR EQ type */
82
83#define SOF_EQ_IIR_IDX_SWITCH 0
84
85#define SOF_EQ_IIR_MAX_SIZE 1024 /* Max size allowed for coef data in bytes */
86
87#define SOF_EQ_IIR_MAX_RESPONSES 8 /* A blob can define max 8 IIR EQs */
88
89/* eq_iir_configuration
90 * uint32_t channels_in_config
91 * This describes the number of channels in this EQ config data. It
92 * can be different from PLATFORM_MAX_CHANNELS.
93 * uint32_t number_of_responses_defined
94 * 0=no responses, 1=one response defined, 2=two responses defined, etc.
95 * int32_t data[]
96 * Data consist of two parts. First is the response assign vector that
97 * has length of channels_in_config. The latter part is coefficient
98 * data.
99 * uint32_t assign_response[channels_in_config]
100 * -1 = not defined, 0 = use first response, 1 = use 2nd, etc.
101 * E.g. {0, 0, 0, 0, -1, -1, -1, -1} would apply to channels 0-3 the
102 * same first defined response and leave channels 4-7 unequalized.
103 * coefficient_data[]
104 * <1st EQ>
105 * uint32_t num_biquads
106 * uint32_t num_biquads_in_series
107 * <1st biquad>
108 * int32_t coef_a2 Q2.30 format
109 * int32_t coef_a1 Q2.30 format
110 * int32_t coef_b2 Q2.30 format
111 * int32_t coef_b1 Q2.30 format
112 * int32_t coef_b0 Q2.30 format
113 * int32_t output_shift number of shifts right, shift left is negative
114 * int32_t output_gain Q2.14 format
115 * <2nd biquad>
116 * ...
117 * <2nd EQ>
118 *
119 * Note: A flat response biquad can be made with a section set to
120 * b0 = 1.0, gain = 1.0, and other parameters set to 0
121 * {0, 0, 0, 0, 1073741824, 0, 16484}
122 */
123
124struct sof_eq_iir_config {
125 uint32_t size;
126 uint32_t channels_in_config;
127 uint32_t number_of_responses;
128
129 /* reserved */
130 uint32_t reserved[4];
131
132 int32_t data[]; /* eq_assign[channels], eq 0, eq 1, ... */
133} __packed;
134
135struct sof_eq_iir_header_df2t {
136 uint32_t num_sections;
137 uint32_t num_sections_in_series;
138
139 /* reserved */
140 uint32_t reserved[4];
141
142 int32_t biquads[]; /* Repeated biquad coefficients */
143} __packed;
144
145struct sof_eq_iir_biquad_df2t {
146 int32_t a2; /* Q2.30 */
147 int32_t a1; /* Q2.30 */
148 int32_t b2; /* Q2.30 */
149 int32_t b1; /* Q2.30 */
150 int32_t b0; /* Q2.30 */
151 int32_t output_shift; /* Number of right shifts */
152 int32_t output_gain; /* Q2.14 */
153} __packed;
154
155/* A full 22th order equalizer with 11 biquads cover octave bands 1-11 in
156 * in the 0 - 20 kHz bandwidth.
157 */
158#define SOF_EQ_IIR_DF2T_BIQUADS_MAX 11
159
160/* The number of int32_t words in sof_eq_iir_header_df2t:
161 * num_sections, num_sections_in_series, reserved[4]
162 */
163#define SOF_EQ_IIR_NHEADER_DF2T \
164 (sizeof(struct sof_eq_iir_header_df2t) / sizeof(int32_t))
165
166/* The number of int32_t words in sof_eq_iir_biquad_df2t:
167 * a2, a1, b2, b1, b0, output_shift, output_gain
168 */
169#define SOF_EQ_IIR_NBIQUAD_DF2T \
170 (sizeof(struct sof_eq_iir_biquad_df2t) / sizeof(int32_t))
171
172#endif
include/uapi/sound/sof/fw.h+78−0
@@ -0,0 +1,78 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 */
8
9/*
10 * Firmware file format .
11 */
12
13#ifndef __INCLUDE_UAPI_SOF_FW_H__
14#define __INCLUDE_UAPI_SOF_FW_H__
15
16#define SND_SOF_FW_SIG_SIZE 4
17#define SND_SOF_FW_ABI 1
18#define SND_SOF_FW_SIG "Reef"
19
20/*
21 * Firmware module is made up of 1 . N blocks of different types. The
22 * Block header is used to determine where and how block is to be copied in the
23 * DSP/host memory space.
24 */
25enum snd_sof_fw_blk_type {
26 SOF_FW_BLK_TYPE_INVALID = -1,
27 SOF_FW_BLK_TYPE_START = 0,
28 SOF_FW_BLK_TYPE_RSRVD0 = SOF_FW_BLK_TYPE_START,
29 SOF_FW_BLK_TYPE_IRAM = 1, /* local instruction RAM */
30 SOF_FW_BLK_TYPE_DRAM = 2, /* local data RAM */
31 SOF_FW_BLK_TYPE_SRAM = 3, /* system RAM */
32 SOF_FW_BLK_TYPE_ROM = 4,
33 SOF_FW_BLK_TYPE_IMR = 5,
34 SOF_FW_BLK_TYPE_RSRVD6 = 6,
35 SOF_FW_BLK_TYPE_RSRVD7 = 7,
36 SOF_FW_BLK_TYPE_RSRVD8 = 8,
37 SOF_FW_BLK_TYPE_RSRVD9 = 9,
38 SOF_FW_BLK_TYPE_RSRVD10 = 10,
39 SOF_FW_BLK_TYPE_RSRVD11 = 11,
40 SOF_FW_BLK_TYPE_RSRVD12 = 12,
41 SOF_FW_BLK_TYPE_RSRVD13 = 13,
42 SOF_FW_BLK_TYPE_RSRVD14 = 14,
43 /* use SOF_FW_BLK_TYPE_RSVRDX for new block types */
44 SOF_FW_BLK_TYPE_NUM
45};
46
47struct snd_sof_blk_hdr {
48 enum snd_sof_fw_blk_type type;
49 uint32_t size; /* bytes minus this header */
50 uint32_t offset; /* offset from base */
51} __packed;
52
53/*
54 * Firmware file is made up of 1 .. N different modules types. The module
55 * type is used to determine how to load and parse the module.
56 */
57enum snd_sof_fw_mod_type {
58 SOF_FW_BASE = 0, /* base firmware image */
59 SOF_FW_MODULE = 1, /* firmware module */
60};
61
62struct snd_sof_mod_hdr {
63 enum snd_sof_fw_mod_type type;
64 uint32_t size; /* bytes minus this header */
65 uint32_t num_blocks; /* number of blocks */
66} __packed;
67
68/*
69 * Firmware file header.
70 */
71struct snd_sof_fw_header {
72 unsigned char sig[SND_SOF_FW_SIG_SIZE]; /* "Reef" */
73 uint32_t file_size; /* size of file minus this header */
74 uint32_t num_modules; /* number of modules */
75 uint32_t abi; /* version of header format */
76} __packed;
77
78#endif
include/uapi/sound/sof/header.h+27−0
@@ -0,0 +1,27 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 */
8
9#ifndef __INCLUDE_UAPI_SOUND_SOF_USER_HEADER_H__
10#define __INCLUDE_UAPI_SOUND_SOF_USER_HEADER_H__
11
12/*
13 * Header for all non IPC ABI data.
14 *
15 * Identifies data type, size and ABI.
16 * Used by any bespoke component data structures or binary blobs.
17 */
18struct sof_abi_hdr {
19 uint32_t magic; /**< 'S', 'O', 'F', '\0' */
20 uint32_t type; /**< component specific type */
21 uint32_t size; /**< size in bytes of data excl. this struct */
22 uint32_t abi; /**< SOF ABI version */
23 uint32_t reserved[4]; /**< reserved for future use */
24 uint32_t data[0]; /**< Component data - opaque to core */
25} __packed;
26
27#endif
include/uapi/sound/sof/manifest.h+188−0
@@ -0,0 +1,188 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 */
8
9#ifndef __INCLUDE_UAPI_SOUND_SOF_USER_MANIFEST_H__
10#define __INCLUDE_UAPI_SOUND_SOF_USER_MANIFEST_H__
11
12/* start offset for base FW module */
13#define SOF_MAN_ELF_TEXT_OFFSET 0x2000
14
15/* FW Extended Manifest Header id = $AE1 */
16#define SOF_MAN_EXT_HEADER_MAGIC 0x31454124
17
18/* module type load type */
19#define SOF_MAN_MOD_TYPE_BUILTIN 0
20#define SOF_MAN_MOD_TYPE_MODULE 1
21
22struct sof_man_module_type {
23 uint32_t load_type:4; /* SOF_MAN_MOD_TYPE_ */
24 uint32_t auto_start:1;
25 uint32_t domain_ll:1;
26 uint32_t domain_dp:1;
27 uint32_t rsvd_:25;
28};
29
30/* segment flags.type */
31#define SOF_MAN_SEGMENT_TEXT 0
32#define SOF_MAN_SEGMENT_RODATA 1
33#define SOF_MAN_SEGMENT_DATA 1
34#define SOF_MAN_SEGMENT_BSS 2
35#define SOF_MAN_SEGMENT_EMPTY 15
36
37union sof_man_segment_flags {
38 uint32_t ul;
39 struct {
40 uint32_t contents:1;
41 uint32_t alloc:1;
42 uint32_t load:1;
43 uint32_t readonly:1;
44 uint32_t code:1;
45 uint32_t data:1;
46 uint32_t _rsvd0:2;
47 uint32_t type:4; /* MAN_SEGMENT_ */
48 uint32_t _rsvd1:4;
49 uint32_t length:16; /* of segment in pages */
50 } r;
51} __packed;
52
53/*
54 * Module segment descriptor. Used by ROM - Immutable.
55 */
56struct sof_man_segment_desc {
57 union sof_man_segment_flags flags;
58 uint32_t v_base_addr;
59 uint32_t file_offset;
60} __packed;
61
62/*
63 * The firmware binary can be split into several modules.
64 */
65
66#define SOF_MAN_MOD_ID_LEN 4
67#define SOF_MAN_MOD_NAME_LEN 8
68#define SOF_MAN_MOD_SHA256_LEN 32
69#define SOF_MAN_MOD_ID {'$', 'A', 'M', 'E'}
70
71/*
72 * Each module has an entry in the FW header. Used by ROM - Immutable.
73 */
74struct sof_man_module {
75 uint8_t struct_id[SOF_MAN_MOD_ID_LEN]; /* SOF_MAN_MOD_ID */
76 uint8_t name[SOF_MAN_MOD_NAME_LEN];
77 uint8_t uuid[16];
78 struct sof_man_module_type type;
79 uint8_t hash[SOF_MAN_MOD_SHA256_LEN];
80 uint32_t entry_point;
81 uint16_t cfg_offset;
82 uint16_t cfg_count;
83 uint32_t affinity_mask;
84 uint16_t instance_max_count; /* max number of instances */
85 uint16_t instance_bss_size; /* instance (pages) */
86 struct sof_man_segment_desc segment[3];
87} __packed;
88
89/*
90 * Each module has a configuration in the FW header. Used by ROM - Immutable.
91 */
92struct sof_man_mod_config {
93 uint32_t par[4]; /* module parameters */
94 uint32_t is_pages; /* actual size of instance .bss (pages) */
95 uint32_t cps; /* cycles per second */
96 uint32_t ibs; /* input buffer size (bytes) */
97 uint32_t obs; /* output buffer size (bytes) */
98 uint32_t module_flags; /* flags, reserved for future use */
99 uint32_t cpc; /* cycles per single run */
100 uint32_t obls; /* output block size, reserved for future use */
101} __packed;
102
103/*
104 * FW Manifest Header
105 */
106
107#define SOF_MAN_FW_HDR_FW_NAME_LEN 8
108#define SOF_MAN_FW_HDR_ID {'$', 'A', 'M', '1'}
109#define SOF_MAN_FW_HDR_NAME "ADSPFW"
110#define SOF_MAN_FW_HDR_FLAGS 0x0
111#define SOF_MAN_FW_HDR_FEATURES 0xff
112
113/*
114 * The firmware has a standard header that is checked by the ROM on firmware
115 * loading. preload_page_count is used by DMA code loader and is entire
116 * image size on CNL. i.e. CNL: total size of the binary’s .text and .rodata
117 * Used by ROM - Immutable.
118 */
119struct sof_man_fw_header {
120 uint8_t header_id[4];
121 uint32_t header_len;
122 uint8_t name[SOF_MAN_FW_HDR_FW_NAME_LEN];
123 /* number of pages of preloaded image loaded by driver */
124 uint32_t preload_page_count;
125 uint32_t fw_image_flags;
126 uint32_t feature_mask;
127 uint16_t major_version;
128 uint16_t minor_version;
129 uint16_t hotfix_version;
130 uint16_t build_version;
131 uint32_t num_module_entries;
132 uint32_t hw_buf_base_addr;
133 uint32_t hw_buf_length;
134 /* target address for binary loading as offset in IMR - must be == base offset */
135 uint32_t load_offset;
136} __packed;
137
138/*
139 * Firmware manifest descriptor. This can contain N modules and N module
140 * configs. Used by ROM - Immutable.
141 */
142struct sof_man_fw_desc {
143 struct sof_man_fw_header header;
144
145 /* Warning - hack for module arrays. For some unknown reason the we
146 * have a variable size array of struct man_module followed by a
147 * variable size array of struct mod_config. These should have been
148 * merged into a variable array of a parent structure. We have to hack
149 * around this in many places....
150 *
151 * struct sof_man_module man_module[];
152 * struct sof_man_mod_config mod_config[];
153 */
154
155} __packed;
156
157/*
158 * Component Descriptor. Used by ROM - Immutable.
159 */
160struct sof_man_component_desc {
161 uint32_t reserved[2]; /* all 0 */
162 uint32_t version;
163 uint8_t hash[SOF_MAN_MOD_SHA256_LEN];
164 uint32_t base_offset;
165 uint32_t limit_offset;
166 uint32_t attributes[4];
167} __packed;
168
169/*
170 * Audio DSP extended metadata. Used by ROM - Immutable.
171 */
172struct sof_man_adsp_meta_file_ext {
173 uint32_t ext_type; /* always 17 for ADSP extension */
174 uint32_t ext_len;
175 uint32_t imr_type;
176 uint8_t reserved[16]; /* all 0 */
177 struct sof_man_component_desc comp_desc[1];
178} __packed;
179
180/*
181 * Module Manifest for rimage module metadata. Not used by ROM.
182 */
183struct sof_man_module_manifest {
184 struct sof_man_module module;
185 uint32_t text_size;
186} __packed;
187
188#endif
include/uapi/sound/sof/tokens.h+107−0
@@ -0,0 +1,107 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 * Author: Liam Girdwood <liam.r.girdwood@linux.intel.com>
8 * Keyon Jie <yang.jie@linux.intel.com>
9 */
10
11/*
12 * Topology IDs and tokens.
13 *
14 * ** MUST BE ALIGNED WITH TOPOLOGY CONFIGURATION TOKEN VALUES **
15 */
16
17#ifndef __INCLUDE_UAPI_SOF_TOPOLOGY_H__
18#define __INCLUDE_UAPI_SOF_TOPOLOGY_H__
19
20/*
21 * Kcontrol IDs
22 */
23#define SOF_TPLG_KCTL_VOL_ID 256
24#define SOF_TPLG_KCTL_ENUM_ID 257
25#define SOF_TPLG_KCTL_BYTES_ID 258
26#define SOF_TPLG_KCTL_SWITCH_ID 259
27
28/*
29 * Tokens - must match values in topology configurations
30 */
31
32/* buffers */
33#define SOF_TKN_BUF_SIZE 100
34#define SOF_TKN_BUF_CAPS 101
35
36/* DAI */
37/* Token retired with ABI 3.2, do not use for new capabilities
38 * #define SOF_TKN_DAI_DMAC_CONFIG 153
39 */
40#define SOF_TKN_DAI_TYPE 154
41#define SOF_TKN_DAI_INDEX 155
42#define SOF_TKN_DAI_DIRECTION 156
43
44/* scheduling */
45#define SOF_TKN_SCHED_PERIOD 200
46#define SOF_TKN_SCHED_PRIORITY 201
47#define SOF_TKN_SCHED_MIPS 202
48#define SOF_TKN_SCHED_CORE 203
49#define SOF_TKN_SCHED_FRAMES 204
50#define SOF_TKN_SCHED_TIME_DOMAIN 205
51
52/* volume */
53#define SOF_TKN_VOLUME_RAMP_STEP_TYPE 250
54#define SOF_TKN_VOLUME_RAMP_STEP_MS 251
55
56/* SRC */
57#define SOF_TKN_SRC_RATE_IN 300
58#define SOF_TKN_SRC_RATE_OUT 301
59
60/* PCM */
61#define SOF_TKN_PCM_DMAC_CONFIG 353
62
63/* Generic components */
64#define SOF_TKN_COMP_PERIOD_SINK_COUNT 400
65#define SOF_TKN_COMP_PERIOD_SOURCE_COUNT 401
66#define SOF_TKN_COMP_FORMAT 402
67/* Token retired with ABI 3.2, do not use for new capabilities
68 * #define SOF_TKN_COMP_PRELOAD_COUNT 403
69 */
70
71/* SSP */
72#define SOF_TKN_INTEL_SSP_CLKS_CONTROL 500
73#define SOF_TKN_INTEL_SSP_MCLK_ID 501
74#define SOF_TKN_INTEL_SSP_SAMPLE_BITS 502
75#define SOF_TKN_INTEL_SSP_FRAME_PULSE_WIDTH 503
76#define SOF_TKN_INTEL_SSP_QUIRKS 504
77#define SOF_TKN_INTEL_SSP_TDM_PADDING_PER_SLOT 505
78
79/* DMIC */
80#define SOF_TKN_INTEL_DMIC_DRIVER_VERSION 600
81#define SOF_TKN_INTEL_DMIC_CLK_MIN 601
82#define SOF_TKN_INTEL_DMIC_CLK_MAX 602
83#define SOF_TKN_INTEL_DMIC_DUTY_MIN 603
84#define SOF_TKN_INTEL_DMIC_DUTY_MAX 604
85#define SOF_TKN_INTEL_DMIC_NUM_PDM_ACTIVE 605
86#define SOF_TKN_INTEL_DMIC_SAMPLE_RATE 608
87#define SOF_TKN_INTEL_DMIC_FIFO_WORD_LENGTH 609
88
89/* DMIC PDM */
90#define SOF_TKN_INTEL_DMIC_PDM_CTRL_ID 700
91#define SOF_TKN_INTEL_DMIC_PDM_MIC_A_Enable 701
92#define SOF_TKN_INTEL_DMIC_PDM_MIC_B_Enable 702
93#define SOF_TKN_INTEL_DMIC_PDM_POLARITY_A 703
94#define SOF_TKN_INTEL_DMIC_PDM_POLARITY_B 704
95#define SOF_TKN_INTEL_DMIC_PDM_CLK_EDGE 705
96#define SOF_TKN_INTEL_DMIC_PDM_SKEW 706
97
98/* Tone */
99#define SOF_TKN_TONE_SAMPLE_RATE 800
100
101/* Processing Components */
102#define SOF_TKN_PROCESS_TYPE 900
103
104/* for backward compatibility */
105#define SOF_TKN_EFFECT_TYPE SOF_TKN_PROCESS_TYPE
106
107#endif
include/uapi/sound/sof/tone.h+21−0
@@ -0,0 +1,21 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3* This file is provided under a dual BSD/GPLv2 license. When using or
4* redistributing this file, you may do so under either license.
5*
6* Copyright(c) 2018 Intel Corporation. All rights reserved.
7*/
8
9#ifndef __INCLUDE_UAPI_SOUND_SOF_USER_TONE_H__
10#define __INCLUDE_UAPI_SOUND_SOF_USER_TONE_H__
11
12#define SOF_TONE_IDX_FREQUENCY 0
13#define SOF_TONE_IDX_AMPLITUDE 1
14#define SOF_TONE_IDX_FREQ_MULT 2
15#define SOF_TONE_IDX_AMPL_MULT 3
16#define SOF_TONE_IDX_LENGTH 4
17#define SOF_TONE_IDX_PERIOD 5
18#define SOF_TONE_IDX_REPEATS 6
19#define SOF_TONE_IDX_LIN_RAMP_STEP 7
20
21#endif
include/uapi/sound/sof/trace.h+66−0
@@ -0,0 +1,66 @@
1/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2018 Intel Corporation. All rights reserved.
7 */
8
9#ifndef __INCLUDE_UAPI_SOUND_SOF_USER_TRACE_H__
10#define __INCLUDE_UAPI_SOUND_SOF_USER_TRACE_H__
11
12/*
13 * Host system time.
14 *
15 * This property is used by the driver to pass down information about
16 * current system time. It is expressed in us.
17 * FW translates timestamps (in log entries, probe pockets) to this time
18 * domain.
19 *
20 * (cavs: SystemTime).
21 */
22struct system_time {
23 uint32_t val_l; /* Lower dword of current host time value */
24 uint32_t val_u; /* Upper dword of current host time value */
25} __packed;
26
27#define LOG_ENABLE 1 /* Enable logging */
28#define LOG_DISABLE 0 /* Disable logging */
29
30#define LOG_LEVEL_CRITICAL 1 /* (FDK fatal) */
31#define LOG_LEVEL_VERBOSE 2
32
33/*
34 * Layout of a log fifo.
35 */
36struct log_buffer_layout {
37 uint32_t read_ptr; /*read pointer */
38 uint32_t write_ptr; /* write pointer */
39 uint32_t buffer[0]; /* buffer */
40} __packed;
41
42/*
43 * Log buffer status reported by FW.
44 */
45struct log_buffer_status {
46 uint32_t core_id; /* ID of core that logged to other half */
47} __packed;
48
49#define TRACE_ID_LENGTH 12
50
51/*
52 * Log entry header.
53 *
54 * The header is followed by an array of arguments (uint32_t[]).
55 * Number of arguments is specified by the params_num field of log_entry
56 */
57struct log_entry_header {
58 uint32_t id_0 : TRACE_ID_LENGTH; /* e.g. Pipeline ID */
59 uint32_t id_1 : TRACE_ID_LENGTH; /* e.g. Component ID */
60 uint32_t core_id : 8; /* Reporting core's id */
61
62 uint64_t timestamp; /* Timestamp (in dsp ticks) */
63 uint32_t log_entry_address; /* Address of log entry in ELF */
64} __packed;
65
66#endif