Linux 5.3-rc3
Showing the changes to include/uapi (105 of 16417 files). Show all
Unified · Split
| @@ -1,14 +1,14 @@ | |||
| 1 | # SPDX-License-Identifier: GPL-2.0 | 1 | # SPDX-License-Identifier: GPL-2.0 |
| 2 | ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/a.out.h),) | 2 | ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/a.out.h),) |
| 3 | no-export-headers += a.out.h | 3 | no-export-headers += linux/a.out.h |
| 4 | endif | 4 | endif |
| 5 | 5 | ||
| 6 | ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm.h),) | 6 | ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm.h),) |
| 7 | no-export-headers += kvm.h | 7 | no-export-headers += linux/kvm.h |
| 8 | endif | 8 | endif |
| 9 | 9 | ||
| 10 | ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm_para.h),) | 10 | ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm_para.h),) |
| 11 | ifeq ($(wildcard $(objtree)/arch/$(SRCARCH)/include/generated/uapi/asm/kvm_para.h),) | 11 | ifeq ($(wildcard $(objtree)/arch/$(SRCARCH)/include/generated/uapi/asm/kvm_para.h),) |
| 12 | no-export-headers += kvm_para.h | 12 | no-export-headers += linux/kvm_para.h |
| 13 | endif | 13 | endif |
| 14 | endif | 14 | endif |
| @@ -19,15 +19,18 @@ · 18 unmodified lines | |||
| 19 | #define MAP_TYPE 0x0f /* Mask for type of mapping */ | 19 | #define MAP_TYPE 0x0f /* Mask for type of mapping */ |
| 20 | #define MAP_FIXED 0x10 /* Interpret addr exactly */ | 20 | #define MAP_FIXED 0x10 /* Interpret addr exactly */ |
| 21 | #define MAP_ANONYMOUS 0x20 /* don't use a file */ | 21 | #define MAP_ANONYMOUS 0x20 /* don't use a file */ |
| 22 | #ifdef CONFIG_MMAP_ALLOW_UNINITIALIZED | ||
| 23 | # define MAP_UNINITIALIZED 0x4000000 /* For anonymous mmap, memory could be uninitialized */ | ||
| 24 | #else | ||
| 25 | # define MAP_UNINITIALIZED 0x0 /* Don't support this flag */ | ||
| 26 | #endif | ||
| 27 | 22 | ||
| 28 | /* 0x0100 - 0x80000 flags are defined in asm-generic/mman.h */ | 23 | /* 0x0100 - 0x4000 flags are defined in asm-generic/mman.h */ |
| 24 | #define MAP_POPULATE 0x008000 /* populate (prefault) pagetables */ | ||
| 25 | #define MAP_NONBLOCK 0x010000 /* do not block on IO */ | ||
| 26 | #define MAP_STACK 0x020000 /* give out an address that is best suited for process/thread stacks */ | ||
| 27 | #define MAP_HUGETLB 0x040000 /* create a huge page mapping */ | ||
| 28 | #define MAP_SYNC 0x080000 /* perform synchronous page faults for the mapping */ | ||
| 29 | #define MAP_FIXED_NOREPLACE 0x100000 /* MAP_FIXED which doesn't unmap underlying mapping */ | 29 | #define MAP_FIXED_NOREPLACE 0x100000 /* MAP_FIXED which doesn't unmap underlying mapping */ |
| 30 | 30 | ||
| 31 | #define MAP_UNINITIALIZED 0x4000000 /* For anonymous mmap, memory could be | ||
| 32 | * uninitialized */ | ||
| 33 | |||
| 31 | /* | 34 | /* |
| 32 | * Flags for mlock | 35 | * Flags for mlock |
| 33 | */ | 36 | */ |
| @@ -9,13 +9,11 @@ · 8 unmodified lines | |||
| 9 | #define MAP_EXECUTABLE 0x1000 /* mark it as an executable */ | 9 | #define MAP_EXECUTABLE 0x1000 /* mark it as an executable */ |
| 10 | #define MAP_LOCKED 0x2000 /* pages are locked */ | 10 | #define MAP_LOCKED 0x2000 /* pages are locked */ |
| 11 | #define MAP_NORESERVE 0x4000 /* don't check for reservations */ | 11 | #define MAP_NORESERVE 0x4000 /* don't check for reservations */ |
| 12 | #define MAP_POPULATE 0x8000 /* populate (prefault) pagetables */ | ||
| 13 | #define MAP_NONBLOCK 0x10000 /* do not block on IO */ | ||
| 14 | #define MAP_STACK 0x20000 /* give out an address that is best suited for process/thread stacks */ | ||
| 15 | #define MAP_HUGETLB 0x40000 /* create a huge page mapping */ | ||
| 16 | #define MAP_SYNC 0x80000 /* perform synchronous page faults for the mapping */ | ||
| 17 | 12 | ||
| 18 | /* Bits [26:31] are reserved, see mman-common.h for MAP_HUGETLB usage */ | 13 | /* |
| 14 | * Bits [26:31] are reserved, see asm-generic/hugetlb_encode.h | ||
| 15 | * for MAP_HUGETLB usage | ||
| 16 | */ | ||
| 19 | 17 | ||
| 20 | #define MCL_CURRENT 1 /* lock all current mappings */ | 18 | #define MCL_CURRENT 1 /* lock all current mappings */ |
| 21 | #define MCL_FUTURE 2 /* lock all future mappings */ | 19 | #define MCL_FUTURE 2 /* lock all future mappings */ |
| @@ -117,6 +117,8 @@ · 116 unmodified lines | |||
| 117 | #define SO_RCVTIMEO_NEW 66 | 117 | #define SO_RCVTIMEO_NEW 66 |
| 118 | #define SO_SNDTIMEO_NEW 67 | 118 | #define SO_SNDTIMEO_NEW 67 |
| 119 | 119 | ||
| 120 | #define SO_DETACH_REUSEPORT_BPF 68 | ||
| 121 | |||
| 120 | #if !defined(__KERNEL__) | 122 | #if !defined(__KERNEL__) |
| 121 | 123 | ||
| 122 | #if __BITS_PER_LONG == 64 || (defined(__x86_64__) && defined(__ILP32__)) | 124 | #if __BITS_PER_LONG == 64 || (defined(__x86_64__) && defined(__ILP32__)) |
| @@ -844,9 +844,15 @@ __SYSCALL(__NR_fsconfig, sys_fsconfig) · 843 unmodified lines | |||
| 844 | __SYSCALL(__NR_fsmount, sys_fsmount) | 844 | __SYSCALL(__NR_fsmount, sys_fsmount) |
| 845 | #define __NR_fspick 433 | 845 | #define __NR_fspick 433 |
| 846 | __SYSCALL(__NR_fspick, sys_fspick) | 846 | __SYSCALL(__NR_fspick, sys_fspick) |
| 847 | #define __NR_pidfd_open 434 | ||
| 848 | __SYSCALL(__NR_pidfd_open, sys_pidfd_open) | ||
| 849 | #ifdef __ARCH_WANT_SYS_CLONE3 | ||
| 850 | #define __NR_clone3 435 | ||
| 851 | __SYSCALL(__NR_clone3, sys_clone3) | ||
| 852 | #endif | ||
| 847 | 853 | ||
| 848 | #undef __NR_syscalls | 854 | #undef __NR_syscalls |
| 849 | #define __NR_syscalls 434 | 855 | #define __NR_syscalls 436 |
| 850 | 856 | ||
| 851 | /* | 857 | /* |
| 852 | * 32 bit systems traditionally used different | 858 | * 32 bit systems traditionally used different |
| @@ -891,13 +891,11 @@ struct drm_vmw_shader_arg { · 890 unmodified lines | |||
| 891 | * surface. | 891 | * surface. |
| 892 | * @drm_vmw_surface_flag_create_buffer: Create a backup buffer if none is | 892 | * @drm_vmw_surface_flag_create_buffer: Create a backup buffer if none is |
| 893 | * given. | 893 | * given. |
| 894 | * @drm_vmw_surface_flag_coherent: Back surface with coherent memory. | ||
| 895 | */ | 894 | */ |
| 896 | enum drm_vmw_surface_flags { | 895 | enum drm_vmw_surface_flags { |
| 897 | drm_vmw_surface_flag_shareable = (1 << 0), | 896 | drm_vmw_surface_flag_shareable = (1 << 0), |
| 898 | drm_vmw_surface_flag_scanout = (1 << 1), | 897 | drm_vmw_surface_flag_scanout = (1 << 1), |
| 899 | drm_vmw_surface_flag_create_buffer = (1 << 2), | 898 | drm_vmw_surface_flag_create_buffer = (1 << 2) |
| 900 | drm_vmw_surface_flag_coherent = (1 << 3), | ||
| 901 | }; | 899 | }; |
| 902 | 900 | ||
| 903 | /** | 901 | /** |
| @@ -29,17 +29,17 @@ struct adfs_discrecord { · 28 unmodified lines | |||
| 29 | __u8 log2sharesize:4; | 29 | __u8 log2sharesize:4; |
| 30 | __u8 unused40:4; | 30 | __u8 unused40:4; |
| 31 | __u8 big_flag:1; | 31 | __u8 big_flag:1; |
| 32 | __u8 unused41:1; | 32 | __u8 unused41:7; |
| 33 | __u8 nzones_high; | 33 | __u8 nzones_high; |
| 34 | __u8 reserved43; | ||
| 34 | __le32 format_version; | 35 | __le32 format_version; |
| 35 | __le32 root_size; | 36 | __le32 root_size; |
| 36 | __u8 unused52[60 - 52]; | 37 | __u8 unused52[60 - 52]; |
| 37 | }; | 38 | } __attribute__((packed, aligned(4))); |
| 38 | 39 | ||
| 39 | #define ADFS_DISCRECORD (0xc00) | 40 | #define ADFS_DISCRECORD (0xc00) |
| 40 | #define ADFS_DR_OFFSET (0x1c0) | 41 | #define ADFS_DR_OFFSET (0x1c0) |
| 41 | #define ADFS_DR_SIZE 60 | 42 | #define ADFS_DR_SIZE 60 |
| 42 | #define ADFS_DR_SIZE_BITS (ADFS_DR_SIZE << 3) | 43 | #define ADFS_DR_SIZE_BITS (ADFS_DR_SIZE << 3) |
| 43 | 44 | ||
| 44 | |||
| 45 | #endif /* _UAPI_ADFS_FS_H */ | 45 | #endif /* _UAPI_ADFS_FS_H */ |
| @@ -281,6 +281,7 @@ · 280 unmodified lines | |||
| 281 | #define AUDIT_OBJ_GID 110 | 281 | #define AUDIT_OBJ_GID 110 |
| 282 | #define AUDIT_FIELD_COMPARE 111 | 282 | #define AUDIT_FIELD_COMPARE 111 |
| 283 | #define AUDIT_EXE 112 | 283 | #define AUDIT_EXE 112 |
| 284 | #define AUDIT_SADDR_FAM 113 | ||
| 284 | 285 | ||
| 285 | #define AUDIT_ARG0 200 | 286 | #define AUDIT_ARG0 200 |
| 286 | #define AUDIT_ARG1 (AUDIT_ARG0+1) | 287 | #define AUDIT_ARG1 (AUDIT_ARG0+1) |
| @@ -107,12 +107,20 @@ enum batadv_icmp_packettype { · 106 unmodified lines | |||
| 107 | * @BATADV_MCAST_WANT_ALL_UNSNOOPABLES: we want all packets destined for | 107 | * @BATADV_MCAST_WANT_ALL_UNSNOOPABLES: we want all packets destined for |
| 108 | * 224.0.0.0/24 or ff02::1 | 108 | * 224.0.0.0/24 or ff02::1 |
| 109 | * @BATADV_MCAST_WANT_ALL_IPV4: we want all IPv4 multicast packets | 109 | * @BATADV_MCAST_WANT_ALL_IPV4: we want all IPv4 multicast packets |
| 110 | * (both link-local and routable ones) | ||
| 110 | * @BATADV_MCAST_WANT_ALL_IPV6: we want all IPv6 multicast packets | 111 | * @BATADV_MCAST_WANT_ALL_IPV6: we want all IPv6 multicast packets |
| 112 | * (both link-local and routable ones) | ||
| 113 | * @BATADV_MCAST_WANT_NO_RTR4: we have no IPv4 multicast router and therefore | ||
| 114 | * only need routable IPv4 multicast packets we signed up for explicitly | ||
| 115 | * @BATADV_MCAST_WANT_NO_RTR6: we have no IPv6 multicast router and therefore | ||
| 116 | * only need routable IPv6 multicast packets we signed up for explicitly | ||
| 111 | */ | 117 | */ |
| 112 | enum batadv_mcast_flags { | 118 | enum batadv_mcast_flags { |
| 113 | BATADV_MCAST_WANT_ALL_UNSNOOPABLES = 1UL << 0, | 119 | BATADV_MCAST_WANT_ALL_UNSNOOPABLES = 1UL << 0, |
| 114 | BATADV_MCAST_WANT_ALL_IPV4 = 1UL << 1, | 120 | BATADV_MCAST_WANT_ALL_IPV4 = 1UL << 1, |
| 115 | BATADV_MCAST_WANT_ALL_IPV6 = 1UL << 2, | 121 | BATADV_MCAST_WANT_ALL_IPV6 = 1UL << 2, |
| 122 | BATADV_MCAST_WANT_NO_RTR4 = 1UL << 3, | ||
| 123 | BATADV_MCAST_WANT_NO_RTR6 = 1UL << 4, | ||
| 116 | }; | 124 | }; |
| 117 | 125 | ||
| 118 | /* tt data subtypes */ | 126 | /* tt data subtypes */ |
| @@ -170,6 +170,7 @@ enum bpf_prog_type { · 169 unmodified lines | |||
| 170 | BPF_PROG_TYPE_FLOW_DISSECTOR, | 170 | BPF_PROG_TYPE_FLOW_DISSECTOR, |
| 171 | BPF_PROG_TYPE_CGROUP_SYSCTL, | 171 | BPF_PROG_TYPE_CGROUP_SYSCTL, |
| 172 | BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE, | 172 | BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE, |
| 173 | BPF_PROG_TYPE_CGROUP_SOCKOPT, | ||
| 173 | }; | 174 | }; |
| 174 | 175 | ||
| 175 | enum bpf_attach_type { | 176 | enum bpf_attach_type { |
| @@ -192,6 +193,10 @@ enum bpf_attach_type { · 16 unmodified lines | |||
| 192 | BPF_LIRC_MODE2, | 193 | BPF_LIRC_MODE2, |
| 193 | BPF_FLOW_DISSECTOR, | 194 | BPF_FLOW_DISSECTOR, |
| 194 | BPF_CGROUP_SYSCTL, | 195 | BPF_CGROUP_SYSCTL, |
| 196 | BPF_CGROUP_UDP4_RECVMSG, | ||
| 197 | BPF_CGROUP_UDP6_RECVMSG, | ||
| 198 | BPF_CGROUP_GETSOCKOPT, | ||
| 199 | BPF_CGROUP_SETSOCKOPT, | ||
| 195 | __MAX_BPF_ATTACH_TYPE | 200 | __MAX_BPF_ATTACH_TYPE |
| 196 | }; | 201 | }; |
| 197 | 202 | ||
| @@ -260,6 +265,24 @@ enum bpf_attach_type { · 62 unmodified lines | |||
| 260 | */ | 265 | */ |
| 261 | #define BPF_F_ANY_ALIGNMENT (1U << 1) | 266 | #define BPF_F_ANY_ALIGNMENT (1U << 1) |
| 262 | 267 | ||
| 268 | /* BPF_F_TEST_RND_HI32 is used in BPF_PROG_LOAD command for testing purpose. | ||
| 269 | * Verifier does sub-register def/use analysis and identifies instructions whose | ||
| 270 | * def only matters for low 32-bit, high 32-bit is never referenced later | ||
| 271 | * through implicit zero extension. Therefore verifier notifies JIT back-ends | ||
| 272 | * that it is safe to ignore clearing high 32-bit for these instructions. This | ||
| 273 | * saves some back-ends a lot of code-gen. However such optimization is not | ||
| 274 | * necessary on some arches, for example x86_64, arm64 etc, whose JIT back-ends | ||
| 275 | * hence hasn't used verifier's analysis result. But, we really want to have a | ||
| 276 | * way to be able to verify the correctness of the described optimization on | ||
| 277 | * x86_64 on which testsuites are frequently exercised. | ||
| 278 | * | ||
| 279 | * So, this flag is introduced. Once it is set, verifier will randomize high | ||
| 280 | * 32-bit for those instructions who has been identified as safe to ignore them. | ||
| 281 | * Then, if verifier is not doing correct analysis, such randomization will | ||
| 282 | * regress tests to expose bugs. | ||
| 283 | */ | ||
| 284 | #define BPF_F_TEST_RND_HI32 (1U << 2) | ||
| 285 | |||
| 263 | /* When BPF ldimm64's insn[0].src_reg != 0 then this can have | 286 | /* When BPF ldimm64's insn[0].src_reg != 0 then this can have |
| 264 | * two extensions: | 287 | * two extensions: |
| 265 | * | 288 | * |
| @@ -783,7 +806,7 @@ union bpf_attr { · 517 unmodified lines | |||
| 783 | * based on a user-provided identifier for all traffic coming from | 806 | * based on a user-provided identifier for all traffic coming from |
| 784 | * the tasks belonging to the related cgroup. See also the related | 807 | * the tasks belonging to the related cgroup. See also the related |
| 785 | * kernel documentation, available from the Linux sources in file | 808 | * kernel documentation, available from the Linux sources in file |
| 786 | * *Documentation/cgroup-v1/net_cls.txt*. | 809 | * *Documentation/admin-guide/cgroup-v1/net_cls.rst*. |
| 787 | * | 810 | * |
| 788 | * The Linux kernel has two versions for cgroups: there are | 811 | * The Linux kernel has two versions for cgroups: there are |
| 789 | * cgroups v1 and cgroups v2. Both are available to users, who can | 812 | * cgroups v1 and cgroups v2. Both are available to users, who can |
| @@ -1548,8 +1571,11 @@ union bpf_attr { · 758 unmodified lines | |||
| 1548 | * but this is only implemented for native XDP (with driver | 1571 | * but this is only implemented for native XDP (with driver |
| 1549 | * support) as of this writing). | 1572 | * support) as of this writing). |
| 1550 | * | 1573 | * |
| 1551 | * All values for *flags* are reserved for future usage, and must | 1574 | * The lower two bits of *flags* are used as the return code if |
| 1552 | * be left at zero. | 1575 | * the map lookup fails. This is so that the return value can be |
| 1576 | * one of the XDP program return codes up to XDP_TX, as chosen by | ||
| 1577 | * the caller. Any higher bits in the *flags* argument must be | ||
| 1578 | * unset. | ||
| 1553 | * | 1579 | * |
| 1554 | * When used to redirect packets to net devices, this helper | 1580 | * When used to redirect packets to net devices, this helper |
| 1555 | * provides a high performance increase over **bpf_redirect**\ (). | 1581 | * provides a high performance increase over **bpf_redirect**\ (). |
| @@ -1744,6 +1770,7 @@ union bpf_attr { · 188 unmodified lines | |||
| 1744 | * * **BPF_SOCK_OPS_RTO_CB_FLAG** (retransmission time out) | 1770 | * * **BPF_SOCK_OPS_RTO_CB_FLAG** (retransmission time out) |
| 1745 | * * **BPF_SOCK_OPS_RETRANS_CB_FLAG** (retransmission) | 1771 | * * **BPF_SOCK_OPS_RETRANS_CB_FLAG** (retransmission) |
| 1746 | * * **BPF_SOCK_OPS_STATE_CB_FLAG** (TCP state change) | 1772 | * * **BPF_SOCK_OPS_STATE_CB_FLAG** (TCP state change) |
| 1773 | * * **BPF_SOCK_OPS_RTT_CB_FLAG** (every RTT) | ||
| 1747 | * | 1774 | * |
| 1748 | * Therefore, this function can be used to clear a callback flag by | 1775 | * 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 | 1776 | * setting the appropriate bit to zero. e.g. to disable the RTO |
| @@ -2672,6 +2699,20 @@ union bpf_attr { · 922 unmodified lines | |||
| 2672 | * 0 on success. | 2699 | * 0 on success. |
| 2673 | * | 2700 | * |
| 2674 | * **-ENOENT** if the bpf-local-storage cannot be found. | 2701 | * **-ENOENT** if the bpf-local-storage cannot be found. |
| 2702 | * | ||
| 2703 | * int bpf_send_signal(u32 sig) | ||
| 2704 | * Description | ||
| 2705 | * Send signal *sig* to the current task. | ||
| 2706 | * Return | ||
| 2707 | * 0 on success or successfully queued. | ||
| 2708 | * | ||
| 2709 | * **-EBUSY** if work queue under nmi is full. | ||
| 2710 | * | ||
| 2711 | * **-EINVAL** if *sig* is invalid. | ||
| 2712 | * | ||
| 2713 | * **-EPERM** if no permission to send the *sig*. | ||
| 2714 | * | ||
| 2715 | * **-EAGAIN** if bpf program can try again. | ||
| 2675 | */ | 2716 | */ |
| 2676 | #define __BPF_FUNC_MAPPER(FN) \ | 2717 | #define __BPF_FUNC_MAPPER(FN) \ |
| 2677 | FN(unspec), \ | 2718 | FN(unspec), \ |
| @@ -2782,7 +2823,8 @@ union bpf_attr { · 104 unmodified lines | |||
| 2782 | FN(strtol), \ | 2823 | FN(strtol), \ |
| 2783 | FN(strtoul), \ | 2824 | FN(strtoul), \ |
| 2784 | FN(sk_storage_get), \ | 2825 | FN(sk_storage_get), \ |
| 2785 | FN(sk_storage_delete), | 2826 | FN(sk_storage_delete), \ |
| 2827 | FN(send_signal), | ||
| 2786 | 2828 | ||
| 2787 | /* integer value in 'imm' field of BPF_CALL instruction selects which helper | 2829 | /* integer value in 'imm' field of BPF_CALL instruction selects which helper |
| 2788 | * function eBPF program intends to call | 2830 | * function eBPF program intends to call |
| @@ -3031,6 +3073,12 @@ struct bpf_tcp_sock { · 242 unmodified lines | |||
| 3031 | * sum(delta(snd_una)), or how many bytes | 3073 | * sum(delta(snd_una)), or how many bytes |
| 3032 | * were acked. | 3074 | * were acked. |
| 3033 | */ | 3075 | */ |
| 3076 | __u32 dsack_dups; /* RFC4898 tcpEStatsStackDSACKDups | ||
| 3077 | * total number of DSACK blocks received | ||
| 3078 | */ | ||
| 3079 | __u32 delivered; /* Total data packets delivered incl. rexmits */ | ||
| 3080 | __u32 delivered_ce; /* Like the above but only ECE marked packets */ | ||
| 3081 | __u32 icsk_retransmits; /* Number of unrecovered [RTO] timeouts */ | ||
| 3034 | }; | 3082 | }; |
| 3035 | 3083 | ||
| 3036 | struct bpf_sock_tuple { | 3084 | struct bpf_sock_tuple { |
| @@ -3050,6 +3098,10 @@ struct bpf_sock_tuple { · 13 unmodified lines | |||
| 3050 | }; | 3098 | }; |
| 3051 | }; | 3099 | }; |
| 3052 | 3100 | ||
| 3101 | struct bpf_xdp_sock { | ||
| 3102 | __u32 queue_id; | ||
| 3103 | }; | ||
| 3104 | |||
| 3053 | #define XDP_PACKET_HEADROOM 256 | 3105 | #define XDP_PACKET_HEADROOM 256 |
| 3054 | 3106 | ||
| 3055 | /* User return codes for XDP prog type. | 3107 | /* User return codes for XDP prog type. |
| @@ -3141,6 +3193,7 @@ struct bpf_prog_info { · 85 unmodified lines | |||
| 3141 | char name[BPF_OBJ_NAME_LEN]; | 3193 | char name[BPF_OBJ_NAME_LEN]; |
| 3142 | __u32 ifindex; | 3194 | __u32 ifindex; |
| 3143 | __u32 gpl_compatible:1; | 3195 | __u32 gpl_compatible:1; |
| 3196 | __u32 :31; /* alignment pad */ | ||
| 3144 | __u64 netns_dev; | 3197 | __u64 netns_dev; |
| 3145 | __u64 netns_ino; | 3198 | __u64 netns_ino; |
| 3146 | __u32 nr_jited_ksyms; | 3199 | __u32 nr_jited_ksyms; |
| @@ -3195,7 +3248,7 @@ struct bpf_sock_addr { · 48 unmodified lines | |||
| 3195 | __u32 user_ip4; /* Allows 1,2,4-byte read and 4-byte write. | 3248 | __u32 user_ip4; /* Allows 1,2,4-byte read and 4-byte write. |
| 3196 | * Stored in network byte order. | 3249 | * Stored in network byte order. |
| 3197 | */ | 3250 | */ |
| 3198 | __u32 user_ip6[4]; /* Allows 1,2,4-byte read an 4-byte write. | 3251 | __u32 user_ip6[4]; /* Allows 1,2,4,8-byte read and 4,8-byte write. |
| 3199 | * Stored in network byte order. | 3252 | * Stored in network byte order. |
| 3200 | */ | 3253 | */ |
| 3201 | __u32 user_port; /* Allows 4-byte read and write. | 3254 | __u32 user_port; /* Allows 4-byte read and write. |
| @@ -3204,12 +3257,13 @@ struct bpf_sock_addr { · 2 unmodified lines | |||
| 3204 | __u32 family; /* Allows 4-byte read, but no write */ | 3257 | __u32 family; /* Allows 4-byte read, but no write */ |
| 3205 | __u32 type; /* Allows 4-byte read, but no write */ | 3258 | __u32 type; /* Allows 4-byte read, but no write */ |
| 3206 | __u32 protocol; /* Allows 4-byte read, but no write */ | 3259 | __u32 protocol; /* Allows 4-byte read, but no write */ |
| 3207 | __u32 msg_src_ip4; /* Allows 1,2,4-byte read an 4-byte write. | 3260 | __u32 msg_src_ip4; /* Allows 1,2,4-byte read and 4-byte write. |
| 3208 | * Stored in network byte order. | 3261 | * Stored in network byte order. |
| 3209 | */ | 3262 | */ |
| 3210 | __u32 msg_src_ip6[4]; /* Allows 1,2,4-byte read an 4-byte write. | 3263 | __u32 msg_src_ip6[4]; /* Allows 1,2,4,8-byte read and 4,8-byte write. |
| 3211 | * Stored in network byte order. | 3264 | * Stored in network byte order. |
| 3212 | */ | 3265 | */ |
| 3266 | __bpf_md_ptr(struct bpf_sock *, sk); | ||
| 3213 | }; | 3267 | }; |
| 3214 | 3268 | ||
| 3215 | /* User bpf_sock_ops struct to access socket values and specify request ops | 3269 | /* User bpf_sock_ops struct to access socket values and specify request ops |
| @@ -3261,13 +3315,15 @@ struct bpf_sock_ops { · 45 unmodified lines | |||
| 3261 | __u32 sk_txhash; | 3315 | __u32 sk_txhash; |
| 3262 | __u64 bytes_received; | 3316 | __u64 bytes_received; |
| 3263 | __u64 bytes_acked; | 3317 | __u64 bytes_acked; |
| 3318 | __bpf_md_ptr(struct bpf_sock *, sk); | ||
| 3264 | }; | 3319 | }; |
| 3265 | 3320 | ||
| 3266 | /* Definitions for bpf_sock_ops_cb_flags */ | 3321 | /* Definitions for bpf_sock_ops_cb_flags */ |
| 3267 | #define BPF_SOCK_OPS_RTO_CB_FLAG (1<<0) | 3322 | #define BPF_SOCK_OPS_RTO_CB_FLAG (1<<0) |
| 3268 | #define BPF_SOCK_OPS_RETRANS_CB_FLAG (1<<1) | 3323 | #define BPF_SOCK_OPS_RETRANS_CB_FLAG (1<<1) |
| 3269 | #define BPF_SOCK_OPS_STATE_CB_FLAG (1<<2) | 3324 | #define BPF_SOCK_OPS_STATE_CB_FLAG (1<<2) |
| 3270 | #define BPF_SOCK_OPS_ALL_CB_FLAGS 0x7 /* Mask of all currently | 3325 | #define BPF_SOCK_OPS_RTT_CB_FLAG (1<<3) |
| 3326 | #define BPF_SOCK_OPS_ALL_CB_FLAGS 0xF /* Mask of all currently | ||
| 3271 | * supported cb flags | 3327 | * supported cb flags |
| 3272 | */ | 3328 | */ |
| 3273 | 3329 | ||
| @@ -3322,6 +3378,8 @@ enum { · 48 unmodified lines | |||
| 3322 | BPF_SOCK_OPS_TCP_LISTEN_CB, /* Called on listen(2), right after | 3378 | BPF_SOCK_OPS_TCP_LISTEN_CB, /* Called on listen(2), right after |
| 3323 | * socket transition to LISTEN state. | 3379 | * socket transition to LISTEN state. |
| 3324 | */ | 3380 | */ |
| 3381 | BPF_SOCK_OPS_RTT_CB, /* Called on every RTT. | ||
| 3382 | */ | ||
| 3325 | }; | 3383 | }; |
| 3326 | 3384 | ||
| 3327 | /* List of TCP states. There is a build check in net/ipv4/tcp.c to detect | 3385 | /* List of TCP states. There is a build check in net/ipv4/tcp.c to detect |
| @@ -3376,8 +3434,8 @@ struct bpf_raw_tracepoint_args { · 48 unmodified lines | |||
| 3376 | /* DIRECT: Skip the FIB rules and go to FIB table associated with device | 3434 | /* DIRECT: Skip the FIB rules and go to FIB table associated with device |
| 3377 | * OUTPUT: Do lookup from egress perspective; default is ingress | 3435 | * OUTPUT: Do lookup from egress perspective; default is ingress |
| 3378 | */ | 3436 | */ |
| 3379 | #define BPF_FIB_LOOKUP_DIRECT BIT(0) | 3437 | #define BPF_FIB_LOOKUP_DIRECT (1U << 0) |
| 3380 | #define BPF_FIB_LOOKUP_OUTPUT BIT(1) | 3438 | #define BPF_FIB_LOOKUP_OUTPUT (1U << 1) |
| 3381 | 3439 | ||
| 3382 | enum { | 3440 | enum { |
| 3383 | BPF_FIB_LKUP_RET_SUCCESS, /* lookup successful */ | 3441 | BPF_FIB_LKUP_RET_SUCCESS, /* lookup successful */ |
| @@ -3500,4 +3558,15 @@ struct bpf_sysctl { · 116 unmodified lines | |||
| 3500 | */ | 3558 | */ |
| 3501 | }; | 3559 | }; |
| 3502 | 3560 | ||
| 3561 | struct bpf_sockopt { | ||
| 3562 | __bpf_md_ptr(struct bpf_sock *, sk); | ||
| 3563 | __bpf_md_ptr(void *, optval); | ||
| 3564 | __bpf_md_ptr(void *, optval_end); | ||
| 3565 | |||
| 3566 | __s32 level; | ||
| 3567 | __s32 optname; | ||
| 3568 | __s32 optlen; | ||
| 3569 | __s32 retval; | ||
| 3570 | }; | ||
| 3571 | |||
| 3503 | #endif /* _UAPI__LINUX_BPF_H__ */ | 3572 | #endif /* _UAPI__LINUX_BPF_H__ */ |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
| 2 | #ifndef _UAPI_LINUX_BPFILTER_H | 2 | #ifndef _UAPI_LINUX_BPFILTER_H |
| 3 | #define _UAPI_LINUX_BPFILTER_H | 3 | #define _UAPI_LINUX_BPFILTER_H |
| 4 | 4 | ||
| @@ -866,6 +866,8 @@ enum btrfs_raid_types { · 865 unmodified lines | |||
| 866 | #define BTRFS_BLOCK_GROUP_RAID56_MASK (BTRFS_BLOCK_GROUP_RAID5 | \ | 866 | #define BTRFS_BLOCK_GROUP_RAID56_MASK (BTRFS_BLOCK_GROUP_RAID5 | \ |
| 867 | BTRFS_BLOCK_GROUP_RAID6) | 867 | BTRFS_BLOCK_GROUP_RAID6) |
| 868 | 868 | ||
| 869 | #define BTRFS_BLOCK_GROUP_RAID1_MASK (BTRFS_BLOCK_GROUP_RAID1) | ||
| 870 | |||
| 869 | /* | 871 | /* |
| 870 | * We need a bit for restriper to be able to tell when chunks of type | 872 | * We need a bit for restriper to be able to tell when chunks of type |
| 871 | * SINGLE are available. This "extended" profile format is used in | 873 | * SINGLE are available. This "extended" profile format is used in |
| @@ -144,6 +144,7 @@ static inline void cec_msg_set_reply_to(struct cec_msg *msg, · 143 unmodified lines | |||
| 144 | 144 | ||
| 145 | /* cec_msg flags field */ | 145 | /* cec_msg flags field */ |
| 146 | #define CEC_MSG_FL_REPLY_TO_FOLLOWERS (1 << 0) | 146 | #define CEC_MSG_FL_REPLY_TO_FOLLOWERS (1 << 0) |
| 147 | #define CEC_MSG_FL_RAW (1 << 1) | ||
| 147 | 148 | ||
| 148 | /* cec_msg tx/rx_status field */ | 149 | /* cec_msg tx/rx_status field */ |
| 149 | #define CEC_TX_STATUS_OK (1 << 0) | 150 | #define CEC_TX_STATUS_OK (1 << 0) |
| @@ -86,10 +86,6 @@ typedef unsigned long long u_quad_t; · 85 unmodified lines | |||
| 86 | 86 | ||
| 87 | #define inline | 87 | #define inline |
| 88 | 88 | ||
| 89 | struct timespec { | ||
| 90 | long ts_sec; | ||
| 91 | long ts_nsec; | ||
| 92 | }; | ||
| 93 | #else /* DJGPP but not KERNEL */ | 89 | #else /* DJGPP but not KERNEL */ |
| 94 | #include <sys/time.h> | 90 | #include <sys/time.h> |
| 95 | typedef unsigned long long u_quad_t; | 91 | typedef unsigned long long u_quad_t; |
| @@ -110,13 +106,6 @@ typedef unsigned long long u_quad_t; · 14 unmodified lines | |||
| 110 | #define cdev_t dev_t | 106 | #define cdev_t dev_t |
| 111 | #endif | 107 | #endif |
| 112 | 108 | ||
| 113 | #ifdef __CYGWIN32__ | ||
| 114 | struct timespec { | ||
| 115 | time_t tv_sec; /* seconds */ | ||
| 116 | long tv_nsec; /* nanoseconds */ | ||
| 117 | }; | ||
| 118 | #endif | ||
| 119 | |||
| 120 | #ifndef __BIT_TYPES_DEFINED__ | 109 | #ifndef __BIT_TYPES_DEFINED__ |
| 121 | #define __BIT_TYPES_DEFINED__ | 110 | #define __BIT_TYPES_DEFINED__ |
| 122 | typedef signed char int8_t; | 111 | typedef signed char int8_t; |
| @@ -211,6 +200,11 @@ struct CodaFid { · 88 unmodified lines | |||
| 211 | */ | 200 | */ |
| 212 | enum coda_vtype { C_VNON, C_VREG, C_VDIR, C_VBLK, C_VCHR, C_VLNK, C_VSOCK, C_VFIFO, C_VBAD }; | 201 | enum coda_vtype { C_VNON, C_VREG, C_VDIR, C_VBLK, C_VCHR, C_VLNK, C_VSOCK, C_VFIFO, C_VBAD }; |
| 213 | 202 | ||
| 203 | struct coda_timespec { | ||
| 204 | int64_t tv_sec; /* seconds */ | ||
| 205 | long tv_nsec; /* nanoseconds */ | ||
| 206 | }; | ||
| 207 | |||
| 214 | struct coda_vattr { | 208 | struct coda_vattr { |
| 215 | long va_type; /* vnode type (for create) */ | 209 | long va_type; /* vnode type (for create) */ |
| 216 | u_short va_mode; /* files access mode and type */ | 210 | u_short va_mode; /* files access mode and type */ |
| @@ -220,9 +214,9 @@ struct coda_vattr { · 3 unmodified lines | |||
| 220 | long va_fileid; /* file id */ | 214 | long va_fileid; /* file id */ |
| 221 | u_quad_t va_size; /* file size in bytes */ | 215 | u_quad_t va_size; /* file size in bytes */ |
| 222 | long va_blocksize; /* blocksize preferred for i/o */ | 216 | long va_blocksize; /* blocksize preferred for i/o */ |
| 223 | struct timespec va_atime; /* time of last access */ | 217 | struct coda_timespec va_atime; /* time of last access */ |
| 224 | struct timespec va_mtime; /* time of last modification */ | 218 | struct coda_timespec va_mtime; /* time of last modification */ |
| 225 | struct timespec va_ctime; /* time file changed */ | 219 | struct coda_timespec va_ctime; /* time file changed */ |
| 226 | u_long va_gen; /* generation number of file */ | 220 | u_long va_gen; /* generation number of file */ |
| 227 | u_long va_flags; /* flags defined for file */ | 221 | u_long va_flags; /* flags defined for file */ |
| 228 | cdev_t va_rdev; /* device special file represents */ | 222 | cdev_t va_rdev; /* device special file represents */ |
| @@ -277,7 +271,8 @@ struct coda_statfs { · 48 unmodified lines | |||
| 277 | #define CODA_STATFS 34 | 271 | #define CODA_STATFS 34 |
| 278 | #define CODA_STORE 35 | 272 | #define CODA_STORE 35 |
| 279 | #define CODA_RELEASE 36 | 273 | #define CODA_RELEASE 36 |
| 280 | #define CODA_NCALLS 37 | 274 | #define CODA_ACCESS_INTENT 37 |
| 275 | #define CODA_NCALLS 38 | ||
| 281 | 276 | ||
| 282 | #define DOWNCALL(opcode) (opcode >= CODA_REPLACE && opcode <= CODA_PURGEFID) | 277 | #define DOWNCALL(opcode) (opcode >= CODA_REPLACE && opcode <= CODA_PURGEFID) |
| 283 | 278 | ||
| @@ -287,7 +282,12 @@ struct coda_statfs { · 3 unmodified lines | |||
| 287 | 282 | ||
| 288 | #define CIOC_KERNEL_VERSION _IOWR('c', 10, size_t) | 283 | #define CIOC_KERNEL_VERSION _IOWR('c', 10, size_t) |
| 289 | 284 | ||
| 290 | #define CODA_KERNEL_VERSION 3 /* 128-bit file identifiers */ | 285 | // CODA_KERNEL_VERSION 0 /* don't care about kernel version number */ |
| 286 | // CODA_KERNEL_VERSION 1 /* The old venus 4.6 compatible interface */ | ||
| 287 | // CODA_KERNEL_VERSION 2 /* venus_lookup gets an extra parameter */ | ||
| 288 | // CODA_KERNEL_VERSION 3 /* 128-bit file identifiers */ | ||
| 289 | // CODA_KERNEL_VERSION 4 /* 64-bit timespec */ | ||
| 290 | #define CODA_KERNEL_VERSION 5 /* access intent support */ | ||
| 291 | 291 | ||
| 292 | /* | 292 | /* |
| 293 | * Venus <-> Coda RPC arguments | 293 | * Venus <-> Coda RPC arguments |
| @@ -295,8 +295,8 @@ struct coda_statfs { · 1 unmodified line | |||
| 295 | struct coda_in_hdr { | 295 | struct coda_in_hdr { |
| 296 | u_int32_t opcode; | 296 | u_int32_t opcode; |
| 297 | u_int32_t unique; /* Keep multiple outstanding msgs distinct */ | 297 | u_int32_t unique; /* Keep multiple outstanding msgs distinct */ |
| 298 | pid_t pid; | 298 | __kernel_pid_t pid; |
| 299 | pid_t pgid; | 299 | __kernel_pid_t pgid; |
| 300 | vuid_t uid; | 300 | vuid_t uid; |
| 301 | }; | 301 | }; |
| 302 | 302 | ||
| @@ -642,6 +642,25 @@ struct coda_statfs_out { · 339 unmodified lines | |||
| 642 | struct coda_statfs stat; | 642 | struct coda_statfs stat; |
| 643 | }; | 643 | }; |
| 644 | 644 | ||
| 645 | #define CODA_ACCESS_TYPE_READ 1 | ||
| 646 | #define CODA_ACCESS_TYPE_WRITE 2 | ||
| 647 | #define CODA_ACCESS_TYPE_MMAP 3 | ||
| 648 | #define CODA_ACCESS_TYPE_READ_FINISH 4 | ||
| 649 | #define CODA_ACCESS_TYPE_WRITE_FINISH 5 | ||
| 650 | |||
| 651 | /* coda_access_intent: NO_OUT */ | ||
| 652 | struct coda_access_intent_in { | ||
| 653 | struct coda_in_hdr ih; | ||
| 654 | struct CodaFid VFid; | ||
| 655 | int count; | ||
| 656 | int pos; | ||
| 657 | int type; | ||
| 658 | }; | ||
| 659 | |||
| 660 | struct coda_access_intent_out { | ||
| 661 | struct coda_out_hdr out; | ||
| 662 | }; | ||
| 663 | |||
| 645 | /* | 664 | /* |
| 646 | * Occasionally, we don't cache the fid returned by CODA_LOOKUP. | 665 | * Occasionally, we don't cache the fid returned by CODA_LOOKUP. |
| 647 | * For instance, if the fid is inconsistent. | 666 | * For instance, if the fid is inconsistent. |
| @@ -673,6 +692,7 @@ union inputArgs { · 25 unmodified lines | |||
| 673 | struct coda_open_by_fd_in coda_open_by_fd; | 692 | struct coda_open_by_fd_in coda_open_by_fd; |
| 674 | struct coda_open_by_path_in coda_open_by_path; | 693 | struct coda_open_by_path_in coda_open_by_path; |
| 675 | struct coda_statfs_in coda_statfs; | 694 | struct coda_statfs_in coda_statfs; |
| 695 | struct coda_access_intent_in coda_access_intent; | ||
| 676 | }; | 696 | }; |
| 677 | 697 | ||
| 678 | union outputArgs { | 698 | union outputArgs { |
| @@ -1,28 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | #ifndef _UAPI__CODA_PSDEV_H | ||
| 3 | #define _UAPI__CODA_PSDEV_H | ||
| 4 | |||
| 5 | #include <linux/magic.h> | ||
| 6 | |||
| 7 | #define CODA_PSDEV_MAJOR 67 | ||
| 8 | #define MAX_CODADEVS 5 /* how many do we allow */ | ||
| 9 | |||
| 10 | |||
| 11 | /* messages between coda filesystem in kernel and Venus */ | ||
| 12 | struct upc_req { | ||
| 13 | struct list_head uc_chain; | ||
| 14 | caddr_t uc_data; | ||
| 15 | u_short uc_flags; | ||
| 16 | u_short uc_inSize; /* Size is at most 5000 bytes */ | ||
| 17 | u_short uc_outSize; | ||
| 18 | u_short uc_opcode; /* copied from data to save lookup */ | ||
| 19 | int uc_unique; | ||
| 20 | wait_queue_head_t uc_sleep; /* process' wait queue */ | ||
| 21 | }; | ||
| 22 | |||
| 23 | #define CODA_REQ_ASYNC 0x1 | ||
| 24 | #define CODA_REQ_READ 0x2 | ||
| 25 | #define CODA_REQ_WRITE 0x4 | ||
| 26 | #define CODA_REQ_ABORT 0x8 | ||
| 27 | |||
| 28 | #endif /* _UAPI__CODA_PSDEV_H */ | ||
| @@ -104,6 +104,8 @@ enum devlink_command { · 103 unmodified lines | |||
| 104 | DEVLINK_CMD_HEALTH_REPORTER_DUMP_CLEAR, | 104 | DEVLINK_CMD_HEALTH_REPORTER_DUMP_CLEAR, |
| 105 | 105 | ||
| 106 | DEVLINK_CMD_FLASH_UPDATE, | 106 | DEVLINK_CMD_FLASH_UPDATE, |
| 107 | DEVLINK_CMD_FLASH_UPDATE_END, /* notification only */ | ||
| 108 | DEVLINK_CMD_FLASH_UPDATE_STATUS, /* notification only */ | ||
| 107 | 109 | ||
| 108 | /* add new commands above here */ | 110 | /* add new commands above here */ |
| 109 | __DEVLINK_CMD_MAX, | 111 | __DEVLINK_CMD_MAX, |
| @@ -167,6 +169,14 @@ enum devlink_port_flavour { · 57 unmodified lines | |||
| 167 | DEVLINK_PORT_FLAVOUR_DSA, /* Distributed switch architecture | 169 | DEVLINK_PORT_FLAVOUR_DSA, /* Distributed switch architecture |
| 168 | * interconnect port. | 170 | * interconnect port. |
| 169 | */ | 171 | */ |
| 172 | DEVLINK_PORT_FLAVOUR_PCI_PF, /* Represents eswitch port for | ||
| 173 | * the PCI PF. It is an internal | ||
| 174 | * port that faces the PCI PF. | ||
| 175 | */ | ||
| 176 | DEVLINK_PORT_FLAVOUR_PCI_VF, /* Represents eswitch port | ||
| 177 | * for the PCI VF. It is an internal | ||
| 178 | * port that faces the PCI VF. | ||
| 179 | */ | ||
| 170 | }; | 180 | }; |
| 171 | 181 | ||
| 172 | enum devlink_param_cmode { | 182 | enum devlink_param_cmode { |
| @@ -331,6 +341,12 @@ enum devlink_attr { · 158 unmodified lines | |||
| 331 | 341 | ||
| 332 | DEVLINK_ATTR_FLASH_UPDATE_FILE_NAME, /* string */ | 342 | DEVLINK_ATTR_FLASH_UPDATE_FILE_NAME, /* string */ |
| 333 | DEVLINK_ATTR_FLASH_UPDATE_COMPONENT, /* string */ | 343 | DEVLINK_ATTR_FLASH_UPDATE_COMPONENT, /* string */ |
| 344 | DEVLINK_ATTR_FLASH_UPDATE_STATUS_MSG, /* string */ | ||
| 345 | DEVLINK_ATTR_FLASH_UPDATE_STATUS_DONE, /* u64 */ | ||
| 346 | DEVLINK_ATTR_FLASH_UPDATE_STATUS_TOTAL, /* u64 */ | ||
| 347 | |||
| 348 | DEVLINK_ATTR_PORT_PCI_PF_NUMBER, /* u16 */ | ||
| 349 | DEVLINK_ATTR_PORT_PCI_VF_NUMBER, /* u16 */ | ||
| 334 | 350 | ||
| 335 | /* add new attributes above here, update the policy in devlink.c */ | 351 | /* add new attributes above here, update the policy in devlink.c */ |
| 336 | 352 | ||
| @@ -1,6 +1,8 @@ | |||
| 1 | /* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */ | 1 | /* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * audio.h | 3 | * audio.h - DEPRECATED MPEG-TS audio decoder API |
| 4 | * | ||
| 5 | * NOTE: should not be used on future drivers | ||
| 4 | * | 6 | * |
| 5 | * Copyright (C) 2000 Ralph Metzler <ralph@convergence.de> | 7 | * Copyright (C) 2000 Ralph Metzler <ralph@convergence.de> |
| 6 | * & Marcus Metzler <marcus@convergence.de> | 8 | * & Marcus Metzler <marcus@convergence.de> |
| @@ -52,7 +54,7 @@ typedef enum { · 45 unmodified lines | |||
| 52 | typedef struct audio_mixer { | 54 | typedef struct audio_mixer { |
| 53 | unsigned int volume_left; | 55 | unsigned int volume_left; |
| 54 | unsigned int volume_right; | 56 | unsigned int volume_right; |
| 55 | // what else do we need? bass, pass-through, ... | 57 | /* what else do we need? bass, pass-through, ... */ |
| 56 | } audio_mixer_t; | 58 | } audio_mixer_t; |
| 57 | 59 | ||
| 58 | 60 | ||
| @@ -1,6 +1,8 @@ | |||
| 1 | /* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */ | 1 | /* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * osd.h | 3 | * osd.h - DEPRECATED On Screen Display API |
| 4 | * | ||
| 5 | * NOTE: should not be used on future drivers | ||
| 4 | * | 6 | * |
| 5 | * Copyright (C) 2001 Ralph Metzler <ralph@convergence.de> | 7 | * Copyright (C) 2001 Ralph Metzler <ralph@convergence.de> |
| 6 | * & Marcus Metzler <marcus@convergence.de> | 8 | * & Marcus Metzler <marcus@convergence.de> |
| @@ -28,74 +30,108 @@ · 21 unmodified lines | |||
| 28 | #include <linux/compiler.h> | 30 | #include <linux/compiler.h> |
| 29 | 31 | ||
| 30 | typedef enum { | 32 | typedef enum { |
| 31 | // All functions return -2 on "not open" | 33 | /* All functions return -2 on "not open" */ |
| 32 | OSD_Close=1, // () | 34 | OSD_Close = 1, /* () */ |
| 33 | // Disables OSD and releases the buffers | 35 | /* |
| 34 | // returns 0 on success | 36 | * Disables OSD and releases the buffers |
| 35 | OSD_Open, // (x0,y0,x1,y1,BitPerPixel[2/4/8](color&0x0F),mix[0..15](color&0xF0)) | 37 | * returns 0 on success |
| 36 | // Opens OSD with this size and bit depth | 38 | */ |
| 37 | // returns 0 on success, -1 on DRAM allocation error, -2 on "already open" | 39 | OSD_Open, /* (x0,y0,x1,y1,BitPerPixel[2/4/8](color&0x0F),mix[0..15](color&0xF0)) */ |
| 38 | OSD_Show, // () | 40 | /* |
| 39 | // enables OSD mode | 41 | * Opens OSD with this size and bit depth |
| 40 | // returns 0 on success | 42 | * returns 0 on success, -1 on DRAM allocation error, -2 on "already open" |
| 41 | OSD_Hide, // () | 43 | */ |
| 42 | // disables OSD mode | 44 | OSD_Show, /* () */ |
| 43 | // returns 0 on success | 45 | /* |
| 44 | OSD_Clear, // () | 46 | * enables OSD mode |
| 45 | // Sets all pixel to color 0 | 47 | * returns 0 on success |
| 46 | // returns 0 on success | 48 | */ |
| 47 | OSD_Fill, // (color) | 49 | OSD_Hide, /* () */ |
| 48 | // Sets all pixel to color <col> | 50 | /* |
| 49 | // returns 0 on success | 51 | * disables OSD mode |
| 50 | OSD_SetColor, // (color,R{x0},G{y0},B{x1},opacity{y1}) | 52 | * returns 0 on success |
| 51 | // set palette entry <num> to <r,g,b>, <mix> and <trans> apply | 53 | */ |
| 52 | // R,G,B: 0..255 | 54 | OSD_Clear, /* () */ |
| 53 | // R=Red, G=Green, B=Blue | 55 | /* |
| 54 | // opacity=0: pixel opacity 0% (only video pixel shows) | 56 | * Sets all pixel to color 0 |
| 55 | // opacity=1..254: pixel opacity as specified in header | 57 | * returns 0 on success |
| 56 | // opacity=255: pixel opacity 100% (only OSD pixel shows) | 58 | */ |
| 57 | // returns 0 on success, -1 on error | 59 | OSD_Fill, /* (color) */ |
| 58 | OSD_SetPalette, // (firstcolor{color},lastcolor{x0},data) | 60 | /* |
| 59 | // Set a number of entries in the palette | 61 | * Sets all pixel to color <col> |
| 60 | // sets the entries "firstcolor" through "lastcolor" from the array "data" | 62 | * returns 0 on success |
| 61 | // data has 4 byte for each color: | 63 | */ |
| 62 | // R,G,B, and a opacity value: 0->transparent, 1..254->mix, 255->pixel | 64 | OSD_SetColor, /* (color,R{x0},G{y0},B{x1},opacity{y1}) */ |
| 63 | OSD_SetTrans, // (transparency{color}) | 65 | /* |
| 64 | // Sets transparency of mixed pixel (0..15) | 66 | * set palette entry <num> to <r,g,b>, <mix> and <trans> apply |
| 65 | // returns 0 on success | 67 | * R,G,B: 0..255 |
| 66 | OSD_SetPixel, // (x0,y0,color) | 68 | * R=Red, G=Green, B=Blue |
| 67 | // sets pixel <x>,<y> to color number <col> | 69 | * opacity=0: pixel opacity 0% (only video pixel shows) |
| 68 | // returns 0 on success, -1 on error | 70 | * opacity=1..254: pixel opacity as specified in header |
| 69 | OSD_GetPixel, // (x0,y0) | 71 | * opacity=255: pixel opacity 100% (only OSD pixel shows) |
| 70 | // returns color number of pixel <x>,<y>, or -1 | 72 | * returns 0 on success, -1 on error |
| 71 | OSD_SetRow, // (x0,y0,x1,data) | 73 | */ |
| 72 | // fills pixels x0,y through x1,y with the content of data[] | 74 | OSD_SetPalette, /* (firstcolor{color},lastcolor{x0},data) */ |
| 73 | // returns 0 on success, -1 on clipping all pixel (no pixel drawn) | 75 | /* |
| 74 | OSD_SetBlock, // (x0,y0,x1,y1,increment{color},data) | 76 | * Set a number of entries in the palette |
| 75 | // fills pixels x0,y0 through x1,y1 with the content of data[] | 77 | * sets the entries "firstcolor" through "lastcolor" from the array "data" |
| 76 | // inc contains the width of one line in the data block, | 78 | * data has 4 byte for each color: |
| 77 | // inc<=0 uses blockwidth as linewidth | 79 | * R,G,B, and a opacity value: 0->transparent, 1..254->mix, 255->pixel |
| 78 | // returns 0 on success, -1 on clipping all pixel | 80 | */ |
| 79 | OSD_FillRow, // (x0,y0,x1,color) | 81 | OSD_SetTrans, /* (transparency{color}) */ |
| 80 | // fills pixels x0,y through x1,y with the color <col> | 82 | /* |
| 81 | // returns 0 on success, -1 on clipping all pixel | 83 | * Sets transparency of mixed pixel (0..15) |
| 82 | OSD_FillBlock, // (x0,y0,x1,y1,color) | 84 | * returns 0 on success |
| 83 | // fills pixels x0,y0 through x1,y1 with the color <col> | 85 | */ |
| 84 | // returns 0 on success, -1 on clipping all pixel | 86 | OSD_SetPixel, /* (x0,y0,color) */ |
| 85 | OSD_Line, // (x0,y0,x1,y1,color) | 87 | /* |
| 86 | // draw a line from x0,y0 to x1,y1 with the color <col> | 88 | * sets pixel <x>,<y> to color number <col> |
| 87 | // returns 0 on success | 89 | * returns 0 on success, -1 on error |
| 88 | OSD_Query, // (x0,y0,x1,y1,xasp{color}}), yasp=11 | 90 | */ |
| 89 | // fills parameters with the picture dimensions and the pixel aspect ratio | 91 | OSD_GetPixel, /* (x0,y0) */ |
| 90 | // returns 0 on success | 92 | /* returns color number of pixel <x>,<y>, or -1 */ |
| 91 | OSD_Test, // () | 93 | OSD_SetRow, /* (x0,y0,x1,data) */ |
| 92 | // draws a test picture. for debugging purposes only | 94 | /* |
| 93 | // returns 0 on success | 95 | * fills pixels x0,y through x1,y with the content of data[] |
| 94 | // TODO: remove "test" in final version | 96 | * returns 0 on success, -1 on clipping all pixel (no pixel drawn) |
| 95 | OSD_Text, // (x0,y0,size,color,text) | 97 | */ |
| 96 | OSD_SetWindow, // (x0) set window with number 0<x0<8 as current | 98 | OSD_SetBlock, /* (x0,y0,x1,y1,increment{color},data) */ |
| 97 | OSD_MoveWindow, // move current window to (x0, y0) | 99 | /* |
| 98 | OSD_OpenRaw, // Open other types of OSD windows | 100 | * fills pixels x0,y0 through x1,y1 with the content of data[] |
| 101 | * inc contains the width of one line in the data block, | ||
| 102 | * inc<=0 uses blockwidth as linewidth | ||
| 103 | * returns 0 on success, -1 on clipping all pixel | ||
| 104 | */ | ||
| 105 | OSD_FillRow, /* (x0,y0,x1,color) */ | ||
| 106 | /* | ||
| 107 | * fills pixels x0,y through x1,y with the color <col> | ||
| 108 | * returns 0 on success, -1 on clipping all pixel | ||
| 109 | */ | ||
| 110 | OSD_FillBlock, /* (x0,y0,x1,y1,color) */ | ||
| 111 | /* | ||
| 112 | * fills pixels x0,y0 through x1,y1 with the color <col> | ||
| 113 | * returns 0 on success, -1 on clipping all pixel | ||
| 114 | */ | ||
| 115 | OSD_Line, /* (x0,y0,x1,y1,color) */ | ||
| 116 | /* | ||
| 117 | * draw a line from x0,y0 to x1,y1 with the color <col> | ||
| 118 | * returns 0 on success | ||
| 119 | */ | ||
| 120 | OSD_Query, /* (x0,y0,x1,y1,xasp{color}}), yasp=11 */ | ||
| 121 | /* | ||
| 122 | * fills parameters with the picture dimensions and the pixel aspect ratio | ||
| 123 | * returns 0 on success | ||
| 124 | */ | ||
| 125 | OSD_Test, /* () */ | ||
| 126 | /* | ||
| 127 | * draws a test picture. for debugging purposes only | ||
| 128 | * returns 0 on success | ||
| 129 | * TODO: remove "test" in final version | ||
| 130 | */ | ||
| 131 | OSD_Text, /* (x0,y0,size,color,text) */ | ||
| 132 | OSD_SetWindow, /* (x0) set window with number 0<x0<8 as current */ | ||
| 133 | OSD_MoveWindow, /* move current window to (x0, y0) */ | ||
| 134 | OSD_OpenRaw, /* Open other types of OSD windows */ | ||
| 99 | } OSD_Command; | 135 | } OSD_Command; |
| 100 | 136 | ||
| 101 | typedef struct osd_cmd_s { | 137 | typedef struct osd_cmd_s { |
| @@ -1,6 +1,8 @@ | |||
| 1 | /* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */ | 1 | /* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * video.h | 3 | * video.h - DEPRECATED MPEG-TS video decoder API |
| 4 | * | ||
| 5 | * NOTE: should not be used on future drivers | ||
| 4 | * | 6 | * |
| 5 | * Copyright (C) 2000 Marcus Metzler <marcus@convergence.de> | 7 | * Copyright (C) 2000 Marcus Metzler <marcus@convergence.de> |
| 6 | * & Ralph Metzler <ralph@convergence.de> | 8 | * & Ralph Metzler <ralph@convergence.de> |
| @@ -1483,6 +1483,8 @@ enum ethtool_link_mode_bit_indices { · 1482 unmodified lines | |||
| 1483 | ETHTOOL_LINK_MODE_200000baseLR4_ER4_FR4_Full_BIT = 64, | 1483 | ETHTOOL_LINK_MODE_200000baseLR4_ER4_FR4_Full_BIT = 64, |
| 1484 | ETHTOOL_LINK_MODE_200000baseDR4_Full_BIT = 65, | 1484 | ETHTOOL_LINK_MODE_200000baseDR4_Full_BIT = 65, |
| 1485 | ETHTOOL_LINK_MODE_200000baseCR4_Full_BIT = 66, | 1485 | ETHTOOL_LINK_MODE_200000baseCR4_Full_BIT = 66, |
| 1486 | ETHTOOL_LINK_MODE_100baseT1_Full_BIT = 67, | ||
| 1487 | ETHTOOL_LINK_MODE_1000baseT1_Full_BIT = 68, | ||
| 1486 | 1488 | ||
| 1487 | /* must be last entry */ | 1489 | /* must be last entry */ |
| 1488 | __ETHTOOL_LINK_MODE_MASK_NBITS | 1490 | __ETHTOOL_LINK_MODE_MASK_NBITS |
| @@ -1,59 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* | ||
| 3 | * Copyright (C) 2002-2003 David McCullough <davidm@snapgear.com> | ||
| 4 | * Copyright (C) 1998 Kenneth Albanowski <kjahds@kjahds.com> | ||
| 5 | * The Silver Hammer Group, Ltd. | ||
| 6 | * | ||
| 7 | * This file provides the definitions and structures needed to | ||
| 8 | * support uClinux flat-format executables. | ||
| 9 | */ | ||
| 10 | |||
| 11 | #ifndef _UAPI_LINUX_FLAT_H | ||
| 12 | #define _UAPI_LINUX_FLAT_H | ||
| 13 | |||
| 14 | |||
| 15 | #define FLAT_VERSION 0x00000004L | ||
| 16 | |||
| 17 | #ifdef CONFIG_BINFMT_SHARED_FLAT | ||
| 18 | #define MAX_SHARED_LIBS (4) | ||
| 19 | #else | ||
| 20 | #define MAX_SHARED_LIBS (1) | ||
| 21 | #endif | ||
| 22 | |||
| 23 | /* | ||
| 24 | * To make everything easier to port and manage cross platform | ||
| 25 | * development, all fields are in network byte order. | ||
| 26 | */ | ||
| 27 | |||
| 28 | struct flat_hdr { | ||
| 29 | char magic[4]; | ||
| 30 | unsigned long rev; /* version (as above) */ | ||
| 31 | unsigned long entry; /* Offset of first executable instruction | ||
| 32 | with text segment from beginning of file */ | ||
| 33 | unsigned long data_start; /* Offset of data segment from beginning of | ||
| 34 | file */ | ||
| 35 | unsigned long data_end; /* Offset of end of data segment | ||
| 36 | from beginning of file */ | ||
| 37 | unsigned long bss_end; /* Offset of end of bss segment from beginning | ||
| 38 | of file */ | ||
| 39 | |||
| 40 | /* (It is assumed that data_end through bss_end forms the bss segment.) */ | ||
| 41 | |||
| 42 | unsigned long stack_size; /* Size of stack, in bytes */ | ||
| 43 | unsigned long reloc_start; /* Offset of relocation records from | ||
| 44 | beginning of file */ | ||
| 45 | unsigned long reloc_count; /* Number of relocation records */ | ||
| 46 | unsigned long flags; | ||
| 47 | unsigned long build_date; /* When the program/library was built */ | ||
| 48 | unsigned long filler[5]; /* Reservered, set to zero */ | ||
| 49 | }; | ||
| 50 | |||
| 51 | #define FLAT_FLAG_RAM 0x0001 /* load program entirely into RAM */ | ||
| 52 | #define FLAT_FLAG_GOTPIC 0x0002 /* program is PIC with GOT */ | ||
| 53 | #define FLAT_FLAG_GZIP 0x0004 /* all but the header is compressed */ | ||
| 54 | #define FLAT_FLAG_GZDATA 0x0008 /* only data/relocs are compressed (for XIP) */ | ||
| 55 | #define FLAT_FLAG_KTRACE 0x0010 /* output useful kernel trace for debugging */ | ||
| 56 | |||
| 57 | |||
| 58 | |||
| 59 | #endif /* _UAPI_LINUX_FLAT_H */ | ||
| @@ -91,6 +91,7 @@ · 90 unmodified lines | |||
| 91 | #define ETH_P_802_EX1 0x88B5 /* 802.1 Local Experimental 1. */ | 91 | #define ETH_P_802_EX1 0x88B5 /* 802.1 Local Experimental 1. */ |
| 92 | #define ETH_P_PREAUTH 0x88C7 /* 802.11 Preauthentication */ | 92 | #define ETH_P_PREAUTH 0x88C7 /* 802.11 Preauthentication */ |
| 93 | #define ETH_P_TIPC 0x88CA /* TIPC */ | 93 | #define ETH_P_TIPC 0x88CA /* TIPC */ |
| 94 | #define ETH_P_LLDP 0x88CC /* Link Layer Discovery Protocol */ | ||
| 94 | #define ETH_P_MACSEC 0x88E5 /* 802.1ae MACsec */ | 95 | #define ETH_P_MACSEC 0x88E5 /* 802.1ae MACsec */ |
| 95 | #define ETH_P_8021AH 0x88E7 /* 802.1ah Backbone Service Tag */ | 96 | #define ETH_P_8021AH 0x88E7 /* 802.1ah Backbone Service Tag */ |
| 96 | #define ETH_P_MVRP 0x88F5 /* 802.1Q MVRP */ | 97 | #define ETH_P_MVRP 0x88F5 /* 802.1Q MVRP */ |
| @@ -636,6 +636,7 @@ enum { · 635 unmodified lines | |||
| 636 | IFLA_BOND_AD_USER_PORT_KEY, | 636 | IFLA_BOND_AD_USER_PORT_KEY, |
| 637 | IFLA_BOND_AD_ACTOR_SYSTEM, | 637 | IFLA_BOND_AD_ACTOR_SYSTEM, |
| 638 | IFLA_BOND_TLB_DYNAMIC_LB, | 638 | IFLA_BOND_TLB_DYNAMIC_LB, |
| 639 | IFLA_BOND_PEER_NOTIF_DELAY, | ||
| 639 | __IFLA_BOND_MAX, | 640 | __IFLA_BOND_MAX, |
| 640 | }; | 641 | }; |
| 641 | 642 | ||
| @@ -694,6 +695,7 @@ enum { · 52 unmodified lines | |||
| 694 | IFLA_VF_IB_NODE_GUID, /* VF Infiniband node GUID */ | 695 | IFLA_VF_IB_NODE_GUID, /* VF Infiniband node GUID */ |
| 695 | IFLA_VF_IB_PORT_GUID, /* VF Infiniband port GUID */ | 696 | IFLA_VF_IB_PORT_GUID, /* VF Infiniband port GUID */ |
| 696 | IFLA_VF_VLAN_LIST, /* nested list of vlans, option for QinQ */ | 697 | IFLA_VF_VLAN_LIST, /* nested list of vlans, option for QinQ */ |
| 698 | IFLA_VF_BROADCAST, /* VF broadcast */ | ||
| 697 | __IFLA_VF_MAX, | 699 | __IFLA_VF_MAX, |
| 698 | }; | 700 | }; |
| 699 | 701 | ||
| @@ -704,6 +706,10 @@ struct ifla_vf_mac { · 4 unmodified lines | |||
| 704 | __u8 mac[32]; /* MAX_ADDR_LEN */ | 706 | __u8 mac[32]; /* MAX_ADDR_LEN */ |
| 705 | }; | 707 | }; |
| 706 | 708 | ||
| 709 | struct ifla_vf_broadcast { | ||
| 710 | __u8 broadcast[32]; | ||
| 711 | }; | ||
| 712 | |||
| 707 | struct ifla_vf_vlan { | 713 | struct ifla_vf_vlan { |
| 708 | __u32 vf; | 714 | __u32 vf; |
| 709 | __u32 vlan; /* 0 - 4095, 0 disables VLAN filter */ | 715 | __u32 vlan; /* 0 - 4095, 0 disables VLAN filter */ |
| @@ -123,7 +123,7 @@ struct tpacket_auxdata { · 122 unmodified lines | |||
| 123 | /* Rx and Tx ring - header status */ | 123 | /* Rx and Tx ring - header status */ |
| 124 | #define TP_STATUS_TS_SOFTWARE (1 << 29) | 124 | #define TP_STATUS_TS_SOFTWARE (1 << 29) |
| 125 | #define TP_STATUS_TS_SYS_HARDWARE (1 << 30) /* deprecated, never set */ | 125 | #define TP_STATUS_TS_SYS_HARDWARE (1 << 30) /* deprecated, never set */ |
| 126 | #define TP_STATUS_TS_RAW_HARDWARE (1 << 31) | 126 | #define TP_STATUS_TS_RAW_HARDWARE (1U << 31) |
| 127 | 127 | ||
| 128 | /* Rx ring - feature request bits */ | 128 | /* Rx ring - feature request bits */ |
| 129 | #define TP_FT_REQ_FILL_RXHASH 0x1 | 129 | #define TP_FT_REQ_FILL_RXHASH 0x1 |
| @@ -46,6 +46,7 @@ struct xdp_mmap_offsets { · 45 unmodified lines | |||
| 46 | #define XDP_UMEM_FILL_RING 5 | 46 | #define XDP_UMEM_FILL_RING 5 |
| 47 | #define XDP_UMEM_COMPLETION_RING 6 | 47 | #define XDP_UMEM_COMPLETION_RING 6 |
| 48 | #define XDP_STATISTICS 7 | 48 | #define XDP_STATISTICS 7 |
| 49 | #define XDP_OPTIONS 8 | ||
| 49 | 50 | ||
| 50 | struct xdp_umem_reg { | 51 | struct xdp_umem_reg { |
| 51 | __u64 addr; /* Start of packet data area */ | 52 | __u64 addr; /* Start of packet data area */ |
| @@ -60,6 +61,13 @@ struct xdp_statistics { · 8 unmodified lines | |||
| 60 | __u64 tx_invalid_descs; /* Dropped due to invalid descriptor */ | 61 | __u64 tx_invalid_descs; /* Dropped due to invalid descriptor */ |
| 61 | }; | 62 | }; |
| 62 | 63 | ||
| 64 | struct xdp_options { | ||
| 65 | __u32 flags; | ||
| 66 | }; | ||
| 67 | |||
| 68 | /* Flags for the flags field of struct xdp_options */ | ||
| 69 | #define XDP_OPTIONS_ZEROCOPY (1 << 0) | ||
| 70 | |||
| 63 | /* Pgoff for mmaping the rings */ | 71 | /* Pgoff for mmaping the rings */ |
| 64 | #define XDP_PGOFF_RX_RING 0 | 72 | #define XDP_PGOFF_RX_RING 0 |
| 65 | #define XDP_PGOFF_TX_RING 0x80000000 | 73 | #define XDP_PGOFF_TX_RING 0x80000000 |
| @@ -27,6 +27,7 @@ struct io_uring_sqe { · 26 unmodified lines | |||
| 27 | __u32 fsync_flags; | 27 | __u32 fsync_flags; |
| 28 | __u16 poll_events; | 28 | __u16 poll_events; |
| 29 | __u32 sync_range_flags; | 29 | __u32 sync_range_flags; |
| 30 | __u32 msg_flags; | ||
| 30 | }; | 31 | }; |
| 31 | __u64 user_data; /* data to be passed back at completion time */ | 32 | __u64 user_data; /* data to be passed back at completion time */ |
| 32 | union { | 33 | union { |
| @@ -40,6 +41,7 @@ struct io_uring_sqe { · 7 unmodified lines | |||
| 40 | */ | 41 | */ |
| 41 | #define IOSQE_FIXED_FILE (1U << 0) /* use fixed fileset */ | 42 | #define IOSQE_FIXED_FILE (1U << 0) /* use fixed fileset */ |
| 42 | #define IOSQE_IO_DRAIN (1U << 1) /* issue after inflight IO */ | 43 | #define IOSQE_IO_DRAIN (1U << 1) /* issue after inflight IO */ |
| 44 | #define IOSQE_IO_LINK (1U << 2) /* links next sqe */ | ||
| 43 | 45 | ||
| 44 | /* | 46 | /* |
| 45 | * io_uring_setup() flags | 47 | * io_uring_setup() flags |
| @@ -57,6 +59,8 @@ struct io_uring_sqe { · 11 unmodified lines | |||
| 57 | #define IORING_OP_POLL_ADD 6 | 59 | #define IORING_OP_POLL_ADD 6 |
| 58 | #define IORING_OP_POLL_REMOVE 7 | 60 | #define IORING_OP_POLL_REMOVE 7 |
| 59 | #define IORING_OP_SYNC_FILE_RANGE 8 | 61 | #define IORING_OP_SYNC_FILE_RANGE 8 |
| 62 | #define IORING_OP_SENDMSG 9 | ||
| 63 | #define IORING_OP_RECVMSG 10 | ||
| 60 | 64 | ||
| 61 | /* | 65 | /* |
| 62 | * sqe->fsync_flags | 66 | * sqe->fsync_flags |
| @@ -0,0 +1,155 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* | ||
| 3 | * IOMMU user API definitions | ||
| 4 | */ | ||
| 5 | |||
| 6 | #ifndef _UAPI_IOMMU_H | ||
| 7 | #define _UAPI_IOMMU_H | ||
| 8 | |||
| 9 | #include <linux/types.h> | ||
| 10 | |||
| 11 | #define IOMMU_FAULT_PERM_READ (1 << 0) /* read */ | ||
| 12 | #define IOMMU_FAULT_PERM_WRITE (1 << 1) /* write */ | ||
| 13 | #define IOMMU_FAULT_PERM_EXEC (1 << 2) /* exec */ | ||
| 14 | #define IOMMU_FAULT_PERM_PRIV (1 << 3) /* privileged */ | ||
| 15 | |||
| 16 | /* Generic fault types, can be expanded IRQ remapping fault */ | ||
| 17 | enum iommu_fault_type { | ||
| 18 | IOMMU_FAULT_DMA_UNRECOV = 1, /* unrecoverable fault */ | ||
| 19 | IOMMU_FAULT_PAGE_REQ, /* page request fault */ | ||
| 20 | }; | ||
| 21 | |||
| 22 | enum iommu_fault_reason { | ||
| 23 | IOMMU_FAULT_REASON_UNKNOWN = 0, | ||
| 24 | |||
| 25 | /* Could not access the PASID table (fetch caused external abort) */ | ||
| 26 | IOMMU_FAULT_REASON_PASID_FETCH, | ||
| 27 | |||
| 28 | /* PASID entry is invalid or has configuration errors */ | ||
| 29 | IOMMU_FAULT_REASON_BAD_PASID_ENTRY, | ||
| 30 | |||
| 31 | /* | ||
| 32 | * PASID is out of range (e.g. exceeds the maximum PASID | ||
| 33 | * supported by the IOMMU) or disabled. | ||
| 34 | */ | ||
| 35 | IOMMU_FAULT_REASON_PASID_INVALID, | ||
| 36 | |||
| 37 | /* | ||
| 38 | * An external abort occurred fetching (or updating) a translation | ||
| 39 | * table descriptor | ||
| 40 | */ | ||
| 41 | IOMMU_FAULT_REASON_WALK_EABT, | ||
| 42 | |||
| 43 | /* | ||
| 44 | * Could not access the page table entry (Bad address), | ||
| 45 | * actual translation fault | ||
| 46 | */ | ||
| 47 | IOMMU_FAULT_REASON_PTE_FETCH, | ||
| 48 | |||
| 49 | /* Protection flag check failed */ | ||
| 50 | IOMMU_FAULT_REASON_PERMISSION, | ||
| 51 | |||
| 52 | /* access flag check failed */ | ||
| 53 | IOMMU_FAULT_REASON_ACCESS, | ||
| 54 | |||
| 55 | /* Output address of a translation stage caused Address Size fault */ | ||
| 56 | IOMMU_FAULT_REASON_OOR_ADDRESS, | ||
| 57 | }; | ||
| 58 | |||
| 59 | /** | ||
| 60 | * struct iommu_fault_unrecoverable - Unrecoverable fault data | ||
| 61 | * @reason: reason of the fault, from &enum iommu_fault_reason | ||
| 62 | * @flags: parameters of this fault (IOMMU_FAULT_UNRECOV_* values) | ||
| 63 | * @pasid: Process Address Space ID | ||
| 64 | * @perm: requested permission access using by the incoming transaction | ||
| 65 | * (IOMMU_FAULT_PERM_* values) | ||
| 66 | * @addr: offending page address | ||
| 67 | * @fetch_addr: address that caused a fetch abort, if any | ||
| 68 | */ | ||
| 69 | struct iommu_fault_unrecoverable { | ||
| 70 | __u32 reason; | ||
| 71 | #define IOMMU_FAULT_UNRECOV_PASID_VALID (1 << 0) | ||
| 72 | #define IOMMU_FAULT_UNRECOV_ADDR_VALID (1 << 1) | ||
| 73 | #define IOMMU_FAULT_UNRECOV_FETCH_ADDR_VALID (1 << 2) | ||
| 74 | __u32 flags; | ||
| 75 | __u32 pasid; | ||
| 76 | __u32 perm; | ||
| 77 | __u64 addr; | ||
| 78 | __u64 fetch_addr; | ||
| 79 | }; | ||
| 80 | |||
| 81 | /** | ||
| 82 | * struct iommu_fault_page_request - Page Request data | ||
| 83 | * @flags: encodes whether the corresponding fields are valid and whether this | ||
| 84 | * is the last page in group (IOMMU_FAULT_PAGE_REQUEST_* values) | ||
| 85 | * @pasid: Process Address Space ID | ||
| 86 | * @grpid: Page Request Group Index | ||
| 87 | * @perm: requested page permissions (IOMMU_FAULT_PERM_* values) | ||
| 88 | * @addr: page address | ||
| 89 | * @private_data: device-specific private information | ||
| 90 | */ | ||
| 91 | struct iommu_fault_page_request { | ||
| 92 | #define IOMMU_FAULT_PAGE_REQUEST_PASID_VALID (1 << 0) | ||
| 93 | #define IOMMU_FAULT_PAGE_REQUEST_LAST_PAGE (1 << 1) | ||
| 94 | #define IOMMU_FAULT_PAGE_REQUEST_PRIV_DATA (1 << 2) | ||
| 95 | __u32 flags; | ||
| 96 | __u32 pasid; | ||
| 97 | __u32 grpid; | ||
| 98 | __u32 perm; | ||
| 99 | __u64 addr; | ||
| 100 | __u64 private_data[2]; | ||
| 101 | }; | ||
| 102 | |||
| 103 | /** | ||
| 104 | * struct iommu_fault - Generic fault data | ||
| 105 | * @type: fault type from &enum iommu_fault_type | ||
| 106 | * @padding: reserved for future use (should be zero) | ||
| 107 | * @event: fault event, when @type is %IOMMU_FAULT_DMA_UNRECOV | ||
| 108 | * @prm: Page Request message, when @type is %IOMMU_FAULT_PAGE_REQ | ||
| 109 | * @padding2: sets the fault size to allow for future extensions | ||
| 110 | */ | ||
| 111 | struct iommu_fault { | ||
| 112 | __u32 type; | ||
| 113 | __u32 padding; | ||
| 114 | union { | ||
| 115 | struct iommu_fault_unrecoverable event; | ||
| 116 | struct iommu_fault_page_request prm; | ||
| 117 | __u8 padding2[56]; | ||
| 118 | }; | ||
| 119 | }; | ||
| 120 | |||
| 121 | /** | ||
| 122 | * enum iommu_page_response_code - Return status of fault handlers | ||
| 123 | * @IOMMU_PAGE_RESP_SUCCESS: Fault has been handled and the page tables | ||
| 124 | * populated, retry the access. This is "Success" in PCI PRI. | ||
| 125 | * @IOMMU_PAGE_RESP_FAILURE: General error. Drop all subsequent faults from | ||
| 126 | * this device if possible. This is "Response Failure" in PCI PRI. | ||
| 127 | * @IOMMU_PAGE_RESP_INVALID: Could not handle this fault, don't retry the | ||
| 128 | * access. This is "Invalid Request" in PCI PRI. | ||
| 129 | */ | ||
| 130 | enum iommu_page_response_code { | ||
| 131 | IOMMU_PAGE_RESP_SUCCESS = 0, | ||
| 132 | IOMMU_PAGE_RESP_INVALID, | ||
| 133 | IOMMU_PAGE_RESP_FAILURE, | ||
| 134 | }; | ||
| 135 | |||
| 136 | /** | ||
| 137 | * struct iommu_page_response - Generic page response information | ||
| 138 | * @version: API version of this structure | ||
| 139 | * @flags: encodes whether the corresponding fields are valid | ||
| 140 | * (IOMMU_FAULT_PAGE_RESPONSE_* values) | ||
| 141 | * @pasid: Process Address Space ID | ||
| 142 | * @grpid: Page Request Group Index | ||
| 143 | * @code: response code from &enum iommu_page_response_code | ||
| 144 | */ | ||
| 145 | struct iommu_page_response { | ||
| 146 | #define IOMMU_PAGE_RESP_VERSION_1 1 | ||
| 147 | __u32 version; | ||
| 148 | #define IOMMU_PAGE_RESP_PASID_VALID (1 << 0) | ||
| 149 | __u32 flags; | ||
| 150 | __u32 pasid; | ||
| 151 | __u32 grpid; | ||
| 152 | __u32 code; | ||
| 153 | }; | ||
| 154 | |||
| 155 | #endif /* _UAPI_IOMMU_H */ | ||
| @@ -128,9 +128,15 @@ · 127 unmodified lines | |||
| 128 | enum { | 128 | enum { |
| 129 | IP_VS_CONN_F_TUNNEL_TYPE_IPIP = 0, /* IPIP */ | 129 | IP_VS_CONN_F_TUNNEL_TYPE_IPIP = 0, /* IPIP */ |
| 130 | IP_VS_CONN_F_TUNNEL_TYPE_GUE, /* GUE */ | 130 | IP_VS_CONN_F_TUNNEL_TYPE_GUE, /* GUE */ |
| 131 | IP_VS_CONN_F_TUNNEL_TYPE_GRE, /* GRE */ | ||
| 131 | IP_VS_CONN_F_TUNNEL_TYPE_MAX, | 132 | IP_VS_CONN_F_TUNNEL_TYPE_MAX, |
| 132 | }; | 133 | }; |
| 133 | 134 | ||
| 135 | /* Tunnel encapsulation flags */ | ||
| 136 | #define IP_VS_TUNNEL_ENCAP_FLAG_NOCSUM (0) | ||
| 137 | #define IP_VS_TUNNEL_ENCAP_FLAG_CSUM (1 << 0) | ||
| 138 | #define IP_VS_TUNNEL_ENCAP_FLAG_REMCSUM (1 << 1) | ||
| 139 | |||
| 134 | /* | 140 | /* |
| 135 | * The struct ip_vs_service_user and struct ip_vs_dest_user are | 141 | * The struct ip_vs_service_user and struct ip_vs_dest_user are |
| 136 | * used to set IPVS rules through setsockopt. | 142 | * used to set IPVS rules through setsockopt. |
| @@ -403,6 +409,8 @@ enum { · 266 unmodified lines | |||
| 403 | 409 | ||
| 404 | IPVS_DEST_ATTR_TUN_PORT, /* tunnel port */ | 410 | IPVS_DEST_ATTR_TUN_PORT, /* tunnel port */ |
| 405 | 411 | ||
| 412 | IPVS_DEST_ATTR_TUN_FLAGS, /* tunnel flags */ | ||
| 413 | |||
| 406 | __IPVS_DEST_ATTR_MAX, | 414 | __IPVS_DEST_ATTR_MAX, |
| 407 | }; | 415 | }; |
| 408 | 416 | ||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2015-2018, Intel Corporation. | 3 | * Copyright (c) 2015-2018, Intel Corporation. |
| 4 | */ | 4 | */ |
| @@ -1,144 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* $Id: isdn.h,v 1.125.2.3 2004/02/10 01:07:14 keil Exp $ | ||
| 3 | * | ||
| 4 | * Main header for the Linux ISDN subsystem (linklevel). | ||
| 5 | * | ||
| 6 | * Copyright 1994,95,96 by Fritz Elfert (fritz@isdn4linux.de) | ||
| 7 | * Copyright 1995,96 by Thinking Objects Software GmbH Wuerzburg | ||
| 8 | * Copyright 1995,96 by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de) | ||
| 9 | * | ||
| 10 | * This software may be used and distributed according to the terms | ||
| 11 | * of the GNU General Public License, incorporated herein by reference. | ||
| 12 | * | ||
| 13 | */ | ||
| 14 | |||
| 15 | #ifndef _UAPI__ISDN_H__ | ||
| 16 | #define _UAPI__ISDN_H__ | ||
| 17 | |||
| 18 | #include <linux/ioctl.h> | ||
| 19 | #include <linux/tty.h> | ||
| 20 | |||
| 21 | #define ISDN_MAX_DRIVERS 32 | ||
| 22 | #define ISDN_MAX_CHANNELS 64 | ||
| 23 | |||
| 24 | /* New ioctl-codes */ | ||
| 25 | #define IIOCNETAIF _IO('I',1) | ||
| 26 | #define IIOCNETDIF _IO('I',2) | ||
| 27 | #define IIOCNETSCF _IO('I',3) | ||
| 28 | #define IIOCNETGCF _IO('I',4) | ||
| 29 | #define IIOCNETANM _IO('I',5) | ||
| 30 | #define IIOCNETDNM _IO('I',6) | ||
| 31 | #define IIOCNETGNM _IO('I',7) | ||
| 32 | #define IIOCGETSET _IO('I',8) /* no longer supported */ | ||
| 33 | #define IIOCSETSET _IO('I',9) /* no longer supported */ | ||
| 34 | #define IIOCSETVER _IO('I',10) | ||
| 35 | #define IIOCNETHUP _IO('I',11) | ||
| 36 | #define IIOCSETGST _IO('I',12) | ||
| 37 | #define IIOCSETBRJ _IO('I',13) | ||
| 38 | #define IIOCSIGPRF _IO('I',14) | ||
| 39 | #define IIOCGETPRF _IO('I',15) | ||
| 40 | #define IIOCSETPRF _IO('I',16) | ||
| 41 | #define IIOCGETMAP _IO('I',17) | ||
| 42 | #define IIOCSETMAP _IO('I',18) | ||
| 43 | #define IIOCNETASL _IO('I',19) | ||
| 44 | #define IIOCNETDIL _IO('I',20) | ||
| 45 | #define IIOCGETCPS _IO('I',21) | ||
| 46 | #define IIOCGETDVR _IO('I',22) | ||
| 47 | #define IIOCNETLCR _IO('I',23) /* dwabc ioctl for LCR from isdnlog */ | ||
| 48 | #define IIOCNETDWRSET _IO('I',24) /* dwabc ioctl to reset abc-values to default on a net-interface */ | ||
| 49 | |||
| 50 | #define IIOCNETALN _IO('I',32) | ||
| 51 | #define IIOCNETDLN _IO('I',33) | ||
| 52 | |||
| 53 | #define IIOCNETGPN _IO('I',34) | ||
| 54 | |||
| 55 | #define IIOCDBGVAR _IO('I',127) | ||
| 56 | |||
| 57 | #define IIOCDRVCTL _IO('I',128) | ||
| 58 | |||
| 59 | /* cisco hdlck device private ioctls */ | ||
| 60 | #define SIOCGKEEPPERIOD (SIOCDEVPRIVATE + 0) | ||
| 61 | #define SIOCSKEEPPERIOD (SIOCDEVPRIVATE + 1) | ||
| 62 | #define SIOCGDEBSERINT (SIOCDEVPRIVATE + 2) | ||
| 63 | #define SIOCSDEBSERINT (SIOCDEVPRIVATE + 3) | ||
| 64 | |||
| 65 | /* Packet encapsulations for net-interfaces */ | ||
| 66 | #define ISDN_NET_ENCAP_ETHER 0 | ||
| 67 | #define ISDN_NET_ENCAP_RAWIP 1 | ||
| 68 | #define ISDN_NET_ENCAP_IPTYP 2 | ||
| 69 | #define ISDN_NET_ENCAP_CISCOHDLC 3 /* Without SLARP and keepalive */ | ||
| 70 | #define ISDN_NET_ENCAP_SYNCPPP 4 | ||
| 71 | #define ISDN_NET_ENCAP_UIHDLC 5 | ||
| 72 | #define ISDN_NET_ENCAP_CISCOHDLCK 6 /* With SLARP and keepalive */ | ||
| 73 | #define ISDN_NET_ENCAP_X25IFACE 7 /* Documentation/networking/x25-iface.txt */ | ||
| 74 | #define ISDN_NET_ENCAP_MAX_ENCAP ISDN_NET_ENCAP_X25IFACE | ||
| 75 | |||
| 76 | /* Facility which currently uses an ISDN-channel */ | ||
| 77 | #define ISDN_USAGE_NONE 0 | ||
| 78 | #define ISDN_USAGE_RAW 1 | ||
| 79 | #define ISDN_USAGE_MODEM 2 | ||
| 80 | #define ISDN_USAGE_NET 3 | ||
| 81 | #define ISDN_USAGE_VOICE 4 | ||
| 82 | #define ISDN_USAGE_FAX 5 | ||
| 83 | #define ISDN_USAGE_MASK 7 /* Mask to get plain usage */ | ||
| 84 | #define ISDN_USAGE_DISABLED 32 /* This bit is set, if channel is disabled */ | ||
| 85 | #define ISDN_USAGE_EXCLUSIVE 64 /* This bit is set, if channel is exclusive */ | ||
| 86 | #define ISDN_USAGE_OUTGOING 128 /* This bit is set, if channel is outgoing */ | ||
| 87 | |||
| 88 | #define ISDN_MODEM_NUMREG 24 /* Number of Modem-Registers */ | ||
| 89 | #define ISDN_LMSNLEN 255 /* Length of tty's Listen-MSN string */ | ||
| 90 | #define ISDN_CMSGLEN 50 /* Length of CONNECT-Message to add for Modem */ | ||
| 91 | |||
| 92 | #define ISDN_MSNLEN 32 | ||
| 93 | #define NET_DV 0x06 /* Data version for isdn_net_ioctl_cfg */ | ||
| 94 | #define TTY_DV 0x06 /* Data version for iprofd etc. */ | ||
| 95 | |||
| 96 | #define INF_DV 0x01 /* Data version for /dev/isdninfo */ | ||
| 97 | |||
| 98 | typedef struct { | ||
| 99 | char drvid[25]; | ||
| 100 | unsigned long arg; | ||
| 101 | } isdn_ioctl_struct; | ||
| 102 | |||
| 103 | typedef struct { | ||
| 104 | char name[10]; | ||
| 105 | char phone[ISDN_MSNLEN]; | ||
| 106 | int outgoing; | ||
| 107 | } isdn_net_ioctl_phone; | ||
| 108 | |||
| 109 | typedef struct { | ||
| 110 | char name[10]; /* Name of interface */ | ||
| 111 | char master[10]; /* Name of Master for Bundling */ | ||
| 112 | char slave[10]; /* Name of Slave for Bundling */ | ||
| 113 | char eaz[256]; /* EAZ/MSN */ | ||
| 114 | char drvid[25]; /* DriverId for Bindings */ | ||
| 115 | int onhtime; /* Hangup-Timeout */ | ||
| 116 | int charge; /* Charge-Units */ | ||
| 117 | int l2_proto; /* Layer-2 protocol */ | ||
| 118 | int l3_proto; /* Layer-3 protocol */ | ||
| 119 | int p_encap; /* Encapsulation */ | ||
| 120 | int exclusive; /* Channel, if bound exclusive */ | ||
| 121 | int dialmax; /* Dial Retry-Counter */ | ||
| 122 | int slavedelay; /* Delay until slave starts up */ | ||
| 123 | int cbdelay; /* Delay before Callback */ | ||
| 124 | int chargehup; /* Flag: Charge-Hangup */ | ||
| 125 | int ihup; /* Flag: Hangup-Timeout on incoming line */ | ||
| 126 | int secure; /* Flag: Secure */ | ||
| 127 | int callback; /* Flag: Callback */ | ||
| 128 | int cbhup; /* Flag: Reject Call before Callback */ | ||
| 129 | int pppbind; /* ippp device for bindings */ | ||
| 130 | int chargeint; /* Use fixed charge interval length */ | ||
| 131 | int triggercps; /* BogoCPS needed for triggering slave */ | ||
| 132 | int dialtimeout; /* Dial-Timeout */ | ||
| 133 | int dialwait; /* Time to wait after failed dial */ | ||
| 134 | int dialmode; /* Flag: off / on / auto */ | ||
| 135 | } isdn_net_ioctl_cfg; | ||
| 136 | |||
| 137 | #define ISDN_NET_DIALMODE_MASK 0xC0 /* bits for status */ | ||
| 138 | #define ISDN_NET_DM_OFF 0x00 /* this interface is stopped */ | ||
| 139 | #define ISDN_NET_DM_MANUAL 0x40 /* this interface is on (manual) */ | ||
| 140 | #define ISDN_NET_DM_AUTO 0x80 /* this interface is autodial */ | ||
| 141 | #define ISDN_NET_DIALMODE(x) ((&(x))->flags & ISDN_NET_DIALMODE_MASK) | ||
| 142 | |||
| 143 | |||
| 144 | #endif /* _UAPI__ISDN_H__ */ | ||
| @@ -1,31 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* $Id: isdn_divertif.h,v 1.4.6.1 2001/09/23 22:25:05 kai Exp $ | ||
| 3 | * | ||
| 4 | * Header for the diversion supplementary interface for i4l. | ||
| 5 | * | ||
| 6 | * Author Werner Cornelius (werner@titro.de) | ||
| 7 | * Copyright by Werner Cornelius (werner@titro.de) | ||
| 8 | * | ||
| 9 | * This software may be used and distributed according to the terms | ||
| 10 | * of the GNU General Public License, incorporated herein by reference. | ||
| 11 | * | ||
| 12 | */ | ||
| 13 | |||
| 14 | #ifndef _UAPI_LINUX_ISDN_DIVERTIF_H | ||
| 15 | #define _UAPI_LINUX_ISDN_DIVERTIF_H | ||
| 16 | |||
| 17 | /***********************************************************/ | ||
| 18 | /* magic value is also used to control version information */ | ||
| 19 | /***********************************************************/ | ||
| 20 | #define DIVERT_IF_MAGIC 0x25873401 | ||
| 21 | #define DIVERT_CMD_REG 0x00 /* register command */ | ||
| 22 | #define DIVERT_CMD_REL 0x01 /* release command */ | ||
| 23 | #define DIVERT_NO_ERR 0x00 /* return value no error */ | ||
| 24 | #define DIVERT_CMD_ERR 0x01 /* invalid cmd */ | ||
| 25 | #define DIVERT_VER_ERR 0x02 /* magic/version invalid */ | ||
| 26 | #define DIVERT_REG_ERR 0x03 /* module already registered */ | ||
| 27 | #define DIVERT_REL_ERR 0x04 /* module not registered */ | ||
| 28 | #define DIVERT_REG_NAME isdn_register_divert | ||
| 29 | |||
| 30 | |||
| 31 | #endif /* _UAPI_LINUX_ISDN_DIVERTIF_H */ | ||
| @@ -1,68 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-1.0+ WITH Linux-syscall-note */ | ||
| 2 | /* Linux ISDN subsystem, sync PPP, interface to ipppd | ||
| 3 | * | ||
| 4 | * Copyright 1994-1999 by Fritz Elfert (fritz@isdn4linux.de) | ||
| 5 | * Copyright 1995,96 Thinking Objects Software GmbH Wuerzburg | ||
| 6 | * Copyright 1995,96 by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de) | ||
| 7 | * Copyright 2000-2002 by Kai Germaschewski (kai@germaschewski.name) | ||
| 8 | * | ||
| 9 | * This software may be used and distributed according to the terms | ||
| 10 | * of the GNU General Public License, incorporated herein by reference. | ||
| 11 | * | ||
| 12 | */ | ||
| 13 | |||
| 14 | #ifndef _UAPI_LINUX_ISDN_PPP_H | ||
| 15 | #define _UAPI_LINUX_ISDN_PPP_H | ||
| 16 | |||
| 17 | #define CALLTYPE_INCOMING 0x1 | ||
| 18 | #define CALLTYPE_OUTGOING 0x2 | ||
| 19 | #define CALLTYPE_CALLBACK 0x4 | ||
| 20 | |||
| 21 | #define IPPP_VERSION "2.2.0" | ||
| 22 | |||
| 23 | struct pppcallinfo | ||
| 24 | { | ||
| 25 | int calltype; | ||
| 26 | unsigned char local_num[64]; | ||
| 27 | unsigned char remote_num[64]; | ||
| 28 | int charge_units; | ||
| 29 | }; | ||
| 30 | |||
| 31 | #define PPPIOCGCALLINFO _IOWR('t',128,struct pppcallinfo) | ||
| 32 | #define PPPIOCBUNDLE _IOW('t',129,int) | ||
| 33 | #define PPPIOCGMPFLAGS _IOR('t',130,int) | ||
| 34 | #define PPPIOCSMPFLAGS _IOW('t',131,int) | ||
| 35 | #define PPPIOCSMPMTU _IOW('t',132,int) | ||
| 36 | #define PPPIOCSMPMRU _IOW('t',133,int) | ||
| 37 | #define PPPIOCGCOMPRESSORS _IOR('t',134,unsigned long [8]) | ||
| 38 | #define PPPIOCSCOMPRESSOR _IOW('t',135,int) | ||
| 39 | #define PPPIOCGIFNAME _IOR('t',136, char [IFNAMSIZ] ) | ||
| 40 | |||
| 41 | |||
| 42 | #define SC_MP_PROT 0x00000200 | ||
| 43 | #define SC_REJ_MP_PROT 0x00000400 | ||
| 44 | #define SC_OUT_SHORT_SEQ 0x00000800 | ||
| 45 | #define SC_IN_SHORT_SEQ 0x00004000 | ||
| 46 | |||
| 47 | #define SC_DECOMP_ON 0x01 | ||
| 48 | #define SC_COMP_ON 0x02 | ||
| 49 | #define SC_DECOMP_DISCARD 0x04 | ||
| 50 | #define SC_COMP_DISCARD 0x08 | ||
| 51 | #define SC_LINK_DECOMP_ON 0x10 | ||
| 52 | #define SC_LINK_COMP_ON 0x20 | ||
| 53 | #define SC_LINK_DECOMP_DISCARD 0x40 | ||
| 54 | #define SC_LINK_COMP_DISCARD 0x80 | ||
| 55 | |||
| 56 | #define ISDN_PPP_COMP_MAX_OPTIONS 16 | ||
| 57 | |||
| 58 | #define IPPP_COMP_FLAG_XMIT 0x1 | ||
| 59 | #define IPPP_COMP_FLAG_LINK 0x2 | ||
| 60 | |||
| 61 | struct isdn_ppp_comp_data { | ||
| 62 | int num; | ||
| 63 | unsigned char options[ISDN_PPP_COMP_MAX_OPTIONS]; | ||
| 64 | int optlen; | ||
| 65 | int flags; | ||
| 66 | }; | ||
| 67 | |||
| 68 | #endif /* _UAPI_LINUX_ISDN_PPP_H */ | ||
| @@ -1,57 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-1.0+ WITH Linux-syscall-note */ | ||
| 2 | /* $Id: isdnif.h,v 1.43.2.2 2004/01/12 23:08:35 keil Exp $ | ||
| 3 | * | ||
| 4 | * Linux ISDN subsystem | ||
| 5 | * Definition of the interface between the subsystem and its low-level drivers. | ||
| 6 | * | ||
| 7 | * Copyright 1994,95,96 by Fritz Elfert (fritz@isdn4linux.de) | ||
| 8 | * Copyright 1995,96 Thinking Objects Software GmbH Wuerzburg | ||
| 9 | * | ||
| 10 | * This software may be used and distributed according to the terms | ||
| 11 | * of the GNU General Public License, incorporated herein by reference. | ||
| 12 | * | ||
| 13 | */ | ||
| 14 | |||
| 15 | #ifndef _UAPI__ISDNIF_H__ | ||
| 16 | #define _UAPI__ISDNIF_H__ | ||
| 17 | |||
| 18 | |||
| 19 | /* | ||
| 20 | * Values for general protocol-selection | ||
| 21 | */ | ||
| 22 | #define ISDN_PTYPE_UNKNOWN 0 /* Protocol undefined */ | ||
| 23 | #define ISDN_PTYPE_1TR6 1 /* german 1TR6-protocol */ | ||
| 24 | #define ISDN_PTYPE_EURO 2 /* EDSS1-protocol */ | ||
| 25 | #define ISDN_PTYPE_LEASED 3 /* for leased lines */ | ||
| 26 | #define ISDN_PTYPE_NI1 4 /* US NI-1 protocol */ | ||
| 27 | #define ISDN_PTYPE_MAX 7 /* Max. 8 Protocols */ | ||
| 28 | |||
| 29 | /* | ||
| 30 | * Values for Layer-2-protocol-selection | ||
| 31 | */ | ||
| 32 | #define ISDN_PROTO_L2_X75I 0 /* X75/LAPB with I-Frames */ | ||
| 33 | #define ISDN_PROTO_L2_X75UI 1 /* X75/LAPB with UI-Frames */ | ||
| 34 | #define ISDN_PROTO_L2_X75BUI 2 /* X75/LAPB with UI-Frames */ | ||
| 35 | #define ISDN_PROTO_L2_HDLC 3 /* HDLC */ | ||
| 36 | #define ISDN_PROTO_L2_TRANS 4 /* Transparent (Voice) */ | ||
| 37 | #define ISDN_PROTO_L2_X25DTE 5 /* X25/LAPB DTE mode */ | ||
| 38 | #define ISDN_PROTO_L2_X25DCE 6 /* X25/LAPB DCE mode */ | ||
| 39 | #define ISDN_PROTO_L2_V11096 7 /* V.110 bitrate adaption 9600 Baud */ | ||
| 40 | #define ISDN_PROTO_L2_V11019 8 /* V.110 bitrate adaption 19200 Baud */ | ||
| 41 | #define ISDN_PROTO_L2_V11038 9 /* V.110 bitrate adaption 38400 Baud */ | ||
| 42 | #define ISDN_PROTO_L2_MODEM 10 /* Analog Modem on Board */ | ||
| 43 | #define ISDN_PROTO_L2_FAX 11 /* Fax Group 2/3 */ | ||
| 44 | #define ISDN_PROTO_L2_HDLC_56K 12 /* HDLC 56k */ | ||
| 45 | #define ISDN_PROTO_L2_MAX 15 /* Max. 16 Protocols */ | ||
| 46 | |||
| 47 | /* | ||
| 48 | * Values for Layer-3-protocol-selection | ||
| 49 | */ | ||
| 50 | #define ISDN_PROTO_L3_TRANS 0 /* Transparent */ | ||
| 51 | #define ISDN_PROTO_L3_TRANSDSP 1 /* Transparent with DSP */ | ||
| 52 | #define ISDN_PROTO_L3_FCLASS2 2 /* Fax Group 2/3 CLASS 2 */ | ||
| 53 | #define ISDN_PROTO_L3_FCLASS1 3 /* Fax Group 2/3 CLASS 1 */ | ||
| 54 | #define ISDN_PROTO_L3_MAX 7 /* Max. 8 Protocols */ | ||
| 55 | |||
| 56 | |||
| 57 | #endif /* _UAPI__ISDNIF_H__ */ | ||
| @@ -0,0 +1,172 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* | ||
| 3 | * Intel Speed Select Interface: OS to hardware Interface | ||
| 4 | * Copyright (c) 2019, Intel Corporation. | ||
| 5 | * All rights reserved. | ||
| 6 | * | ||
| 7 | * Author: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> | ||
| 8 | */ | ||
| 9 | |||
| 10 | #ifndef __ISST_IF_H | ||
| 11 | #define __ISST_IF_H | ||
| 12 | |||
| 13 | #include <linux/types.h> | ||
| 14 | |||
| 15 | /** | ||
| 16 | * struct isst_if_platform_info - Define platform information | ||
| 17 | * @api_version: Version of the firmware document, which this driver | ||
| 18 | * can communicate | ||
| 19 | * @driver_version: Driver version, which will help user to send right | ||
| 20 | * commands. Even if the firmware is capable, driver may | ||
| 21 | * not be ready | ||
| 22 | * @max_cmds_per_ioctl: Returns the maximum number of commands driver will | ||
| 23 | * accept in a single ioctl | ||
| 24 | * @mbox_supported: Support of mail box interface | ||
| 25 | * @mmio_supported: Support of mmio interface for core-power feature | ||
| 26 | * | ||
| 27 | * Used to return output of IOCTL ISST_IF_GET_PLATFORM_INFO. This | ||
| 28 | * information can be used by the user space, to get the driver, firmware | ||
| 29 | * support and also number of commands to send in a single IOCTL request. | ||
| 30 | */ | ||
| 31 | struct isst_if_platform_info { | ||
| 32 | __u16 api_version; | ||
| 33 | __u16 driver_version; | ||
| 34 | __u16 max_cmds_per_ioctl; | ||
| 35 | __u8 mbox_supported; | ||
| 36 | __u8 mmio_supported; | ||
| 37 | }; | ||
| 38 | |||
| 39 | /** | ||
| 40 | * struct isst_if_cpu_map - CPU mapping between logical and physical CPU | ||
| 41 | * @logical_cpu: Linux logical CPU number | ||
| 42 | * @physical_cpu: PUNIT CPU number | ||
| 43 | * | ||
| 44 | * Used to convert from Linux logical CPU to PUNIT CPU numbering scheme. | ||
| 45 | * The PUNIT CPU number is different than APIC ID based CPU numbering. | ||
| 46 | */ | ||
| 47 | struct isst_if_cpu_map { | ||
| 48 | __u32 logical_cpu; | ||
| 49 | __u32 physical_cpu; | ||
| 50 | }; | ||
| 51 | |||
| 52 | /** | ||
| 53 | * struct isst_if_cpu_maps - structure for CPU map IOCTL | ||
| 54 | * @cmd_count: Number of CPU mapping command in cpu_map[] | ||
| 55 | * @cpu_map[]: Holds one or more CPU map data structure | ||
| 56 | * | ||
| 57 | * This structure used with ioctl ISST_IF_GET_PHY_ID to send | ||
| 58 | * one or more CPU mapping commands. Here IOCTL return value indicates | ||
| 59 | * number of commands sent or error number if no commands have been sent. | ||
| 60 | */ | ||
| 61 | struct isst_if_cpu_maps { | ||
| 62 | __u32 cmd_count; | ||
| 63 | struct isst_if_cpu_map cpu_map[1]; | ||
| 64 | }; | ||
| 65 | |||
| 66 | /** | ||
| 67 | * struct isst_if_io_reg - Read write PUNIT IO register | ||
| 68 | * @read_write: Value 0: Read, 1: Write | ||
| 69 | * @logical_cpu: Logical CPU number to get target PCI device. | ||
| 70 | * @reg: PUNIT register offset | ||
| 71 | * @value: For write operation value to write and for | ||
| 72 | * for read placeholder read value | ||
| 73 | * | ||
| 74 | * Structure to specify read/write data to PUNIT registers. | ||
| 75 | */ | ||
| 76 | struct isst_if_io_reg { | ||
| 77 | __u32 read_write; /* Read:0, Write:1 */ | ||
| 78 | __u32 logical_cpu; | ||
| 79 | __u32 reg; | ||
| 80 | __u32 value; | ||
| 81 | }; | ||
| 82 | |||
| 83 | /** | ||
| 84 | * struct isst_if_io_regs - structure for IO register commands | ||
| 85 | * @cmd_count: Number of io reg commands in io_reg[] | ||
| 86 | * @io_reg[]: Holds one or more io_reg command structure | ||
| 87 | * | ||
| 88 | * This structure used with ioctl ISST_IF_IO_CMD to send | ||
| 89 | * one or more read/write commands to PUNIT. Here IOCTL return value | ||
| 90 | * indicates number of requests sent or error number if no requests have | ||
| 91 | * been sent. | ||
| 92 | */ | ||
| 93 | struct isst_if_io_regs { | ||
| 94 | __u32 req_count; | ||
| 95 | struct isst_if_io_reg io_reg[1]; | ||
| 96 | }; | ||
| 97 | |||
| 98 | /** | ||
| 99 | * struct isst_if_mbox_cmd - Structure to define mail box command | ||
| 100 | * @logical_cpu: Logical CPU number to get target PCI device | ||
| 101 | * @parameter: Mailbox parameter value | ||
| 102 | * @req_data: Request data for the mailbox | ||
| 103 | * @resp_data: Response data for mailbox command response | ||
| 104 | * @command: Mailbox command value | ||
| 105 | * @sub_command: Mailbox sub command value | ||
| 106 | * @reserved: Unused, set to 0 | ||
| 107 | * | ||
| 108 | * Structure to specify mailbox command to be sent to PUNIT. | ||
| 109 | */ | ||
| 110 | struct isst_if_mbox_cmd { | ||
| 111 | __u32 logical_cpu; | ||
| 112 | __u32 parameter; | ||
| 113 | __u32 req_data; | ||
| 114 | __u32 resp_data; | ||
| 115 | __u16 command; | ||
| 116 | __u16 sub_command; | ||
| 117 | __u32 reserved; | ||
| 118 | }; | ||
| 119 | |||
| 120 | /** | ||
| 121 | * struct isst_if_mbox_cmds - structure for mailbox commands | ||
| 122 | * @cmd_count: Number of mailbox commands in mbox_cmd[] | ||
| 123 | * @mbox_cmd[]: Holds one or more mbox commands | ||
| 124 | * | ||
| 125 | * This structure used with ioctl ISST_IF_MBOX_COMMAND to send | ||
| 126 | * one or more mailbox commands to PUNIT. Here IOCTL return value | ||
| 127 | * indicates number of commands sent or error number if no commands have | ||
| 128 | * been sent. | ||
| 129 | */ | ||
| 130 | struct isst_if_mbox_cmds { | ||
| 131 | __u32 cmd_count; | ||
| 132 | struct isst_if_mbox_cmd mbox_cmd[1]; | ||
| 133 | }; | ||
| 134 | |||
| 135 | /** | ||
| 136 | * struct isst_if_msr_cmd - Structure to define msr command | ||
| 137 | * @read_write: Value 0: Read, 1: Write | ||
| 138 | * @logical_cpu: Logical CPU number | ||
| 139 | * @msr: MSR number | ||
| 140 | * @data: For write operation, data to write, for read | ||
| 141 | * place holder | ||
| 142 | * | ||
| 143 | * Structure to specify MSR command related to PUNIT. | ||
| 144 | */ | ||
| 145 | struct isst_if_msr_cmd { | ||
| 146 | __u32 read_write; /* Read:0, Write:1 */ | ||
| 147 | __u32 logical_cpu; | ||
| 148 | __u64 msr; | ||
| 149 | __u64 data; | ||
| 150 | }; | ||
| 151 | |||
| 152 | /** | ||
| 153 | * struct isst_if_msr_cmds - structure for msr commands | ||
| 154 | * @cmd_count: Number of mailbox commands in msr_cmd[] | ||
| 155 | * @msr_cmd[]: Holds one or more msr commands | ||
| 156 | * | ||
| 157 | * This structure used with ioctl ISST_IF_MSR_COMMAND to send | ||
| 158 | * one or more MSR commands. IOCTL return value indicates number of | ||
| 159 | * commands sent or error number if no commands have been sent. | ||
| 160 | */ | ||
| 161 | struct isst_if_msr_cmds { | ||
| 162 | __u32 cmd_count; | ||
| 163 | struct isst_if_msr_cmd msr_cmd[1]; | ||
| 164 | }; | ||
| 165 | |||
| 166 | #define ISST_IF_MAGIC 0xFE | ||
| 167 | #define ISST_IF_GET_PLATFORM_INFO _IOR(ISST_IF_MAGIC, 0, struct isst_if_platform_info *) | ||
| 168 | #define ISST_IF_GET_PHY_ID _IOWR(ISST_IF_MAGIC, 1, struct isst_if_cpu_map *) | ||
| 169 | #define ISST_IF_IO_CMD _IOW(ISST_IF_MAGIC, 2, struct isst_if_io_regs *) | ||
| 170 | #define ISST_IF_MBOX_COMMAND _IOWR(ISST_IF_MAGIC, 3, struct isst_if_mbox_cmds *) | ||
| 171 | #define ISST_IF_MSR_COMMAND _IOWR(ISST_IF_MAGIC, 4, struct isst_if_msr_cmds *) | ||
| 172 | #endif | ||
| @@ -67,6 +67,8 @@ · 66 unmodified lines | |||
| 67 | #define KEYCTL_PKEY_SIGN 27 /* Create a public key signature */ | 67 | #define KEYCTL_PKEY_SIGN 27 /* Create a public key signature */ |
| 68 | #define KEYCTL_PKEY_VERIFY 28 /* Verify a public key signature */ | 68 | #define KEYCTL_PKEY_VERIFY 28 /* Verify a public key signature */ |
| 69 | #define KEYCTL_RESTRICT_KEYRING 29 /* Restrict keys allowed to link to a keyring */ | 69 | #define KEYCTL_RESTRICT_KEYRING 29 /* Restrict keys allowed to link to a keyring */ |
| 70 | #define KEYCTL_MOVE 30 /* Move keys between keyrings */ | ||
| 71 | #define KEYCTL_CAPABILITIES 31 /* Find capabilities of keyrings subsystem */ | ||
| 70 | 72 | ||
| 71 | /* keyctl structures */ | 73 | /* keyctl structures */ |
| 72 | struct keyctl_dh_params { | 74 | struct keyctl_dh_params { |
| @@ -112,4 +114,21 @@ struct keyctl_pkey_params { · 39 unmodified lines | |||
| 112 | __u32 __spare[7]; | 114 | __u32 __spare[7]; |
| 113 | }; | 115 | }; |
| 114 | 116 | ||
| 117 | #define KEYCTL_MOVE_EXCL 0x00000001 /* Do not displace from the to-keyring */ | ||
| 118 | |||
| 119 | /* | ||
| 120 | * Capabilities flags. The capabilities list is an array of 8-bit integers; | ||
| 121 | * each integer can carry up to 8 flags. | ||
| 122 | */ | ||
| 123 | #define KEYCTL_CAPS0_CAPABILITIES 0x01 /* KEYCTL_CAPABILITIES supported */ | ||
| 124 | #define KEYCTL_CAPS0_PERSISTENT_KEYRINGS 0x02 /* Persistent keyrings enabled */ | ||
| 125 | #define KEYCTL_CAPS0_DIFFIE_HELLMAN 0x04 /* Diffie-Hellman computation enabled */ | ||
| 126 | #define KEYCTL_CAPS0_PUBLIC_KEY 0x08 /* Public key ops enabled */ | ||
| 127 | #define KEYCTL_CAPS0_BIG_KEY 0x10 /* big_key-type enabled */ | ||
| 128 | #define KEYCTL_CAPS0_INVALIDATE 0x20 /* KEYCTL_INVALIDATE supported */ | ||
| 129 | #define KEYCTL_CAPS0_RESTRICT_KEYRING 0x40 /* KEYCTL_RESTRICT_KEYRING supported */ | ||
| 130 | #define KEYCTL_CAPS0_MOVE 0x80 /* KEYCTL_MOVE supported */ | ||
| 131 | #define KEYCTL_CAPS1_NS_KEYRING_NAME 0x01 /* Keyring names are per-user_namespace */ | ||
| 132 | #define KEYCTL_CAPS1_NS_KEY_TAG 0x02 /* Key indexing can include a namespace tag */ | ||
| 133 | |||
| 115 | #endif /* _LINUX_KEYCTL_H */ | 134 | #endif /* _LINUX_KEYCTL_H */ |
| @@ -116,7 +116,7 @@ struct kvm_irq_level { · 115 unmodified lines | |||
| 116 | * ACPI gsi notion of irq. | 116 | * ACPI gsi notion of irq. |
| 117 | * For IA-64 (APIC model) IOAPIC0: irq 0-23; IOAPIC1: irq 24-47.. | 117 | * For IA-64 (APIC model) IOAPIC0: irq 0-23; IOAPIC1: irq 24-47.. |
| 118 | * For X86 (standard AT mode) PIC0/1: irq 0-15. IOAPIC0: 0-23.. | 118 | * For X86 (standard AT mode) PIC0/1: irq 0-15. IOAPIC0: 0-23.. |
| 119 | * For ARM: See Documentation/virtual/kvm/api.txt | 119 | * For ARM: See Documentation/virt/kvm/api.txt |
| 120 | */ | 120 | */ |
| 121 | union { | 121 | union { |
| 122 | __u32 irq; | 122 | __u32 irq; |
| @@ -696,9 +696,11 @@ struct kvm_ioeventfd { · 573 unmodified lines | |||
| 696 | #define KVM_X86_DISABLE_EXITS_MWAIT (1 << 0) | 696 | #define KVM_X86_DISABLE_EXITS_MWAIT (1 << 0) |
| 697 | #define KVM_X86_DISABLE_EXITS_HLT (1 << 1) | 697 | #define KVM_X86_DISABLE_EXITS_HLT (1 << 1) |
| 698 | #define KVM_X86_DISABLE_EXITS_PAUSE (1 << 2) | 698 | #define KVM_X86_DISABLE_EXITS_PAUSE (1 << 2) |
| 699 | #define KVM_X86_DISABLE_EXITS_CSTATE (1 << 3) | ||
| 699 | #define KVM_X86_DISABLE_VALID_EXITS (KVM_X86_DISABLE_EXITS_MWAIT | \ | 700 | #define KVM_X86_DISABLE_VALID_EXITS (KVM_X86_DISABLE_EXITS_MWAIT | \ |
| 700 | KVM_X86_DISABLE_EXITS_HLT | \ | 701 | KVM_X86_DISABLE_EXITS_HLT | \ |
| 701 | KVM_X86_DISABLE_EXITS_PAUSE) | 702 | KVM_X86_DISABLE_EXITS_PAUSE | \ |
| 703 | KVM_X86_DISABLE_EXITS_CSTATE) | ||
| 702 | 704 | ||
| 703 | /* for KVM_ENABLE_CAP */ | 705 | /* for KVM_ENABLE_CAP */ |
| 704 | struct kvm_enable_cap { | 706 | struct kvm_enable_cap { |
| @@ -993,6 +995,7 @@ struct kvm_ppc_resize_hpt { · 288 unmodified lines | |||
| 993 | #define KVM_CAP_ARM_SVE 170 | 995 | #define KVM_CAP_ARM_SVE 170 |
| 994 | #define KVM_CAP_ARM_PTRAUTH_ADDRESS 171 | 996 | #define KVM_CAP_ARM_PTRAUTH_ADDRESS 171 |
| 995 | #define KVM_CAP_ARM_PTRAUTH_GENERIC 172 | 997 | #define KVM_CAP_ARM_PTRAUTH_GENERIC 172 |
| 998 | #define KVM_CAP_PMU_EVENT_FILTER 173 | ||
| 996 | 999 | ||
| 997 | #ifdef KVM_CAP_IRQ_ROUTING | 1000 | #ifdef KVM_CAP_IRQ_ROUTING |
| 998 | 1001 | ||
| @@ -1083,7 +1086,7 @@ struct kvm_xen_hvm_config { · 84 unmodified lines | |||
| 1083 | * | 1086 | * |
| 1084 | * KVM_IRQFD_FLAG_RESAMPLE indicates resamplefd is valid and specifies | 1087 | * KVM_IRQFD_FLAG_RESAMPLE indicates resamplefd is valid and specifies |
| 1085 | * the irqfd to operate in resampling mode for level triggered interrupt | 1088 | * the irqfd to operate in resampling mode for level triggered interrupt |
| 1086 | * emulation. See Documentation/virtual/kvm/api.txt. | 1089 | * emulation. See Documentation/virt/kvm/api.txt. |
| 1087 | */ | 1090 | */ |
| 1088 | #define KVM_IRQFD_FLAG_RESAMPLE (1 << 1) | 1091 | #define KVM_IRQFD_FLAG_RESAMPLE (1 << 1) |
| 1089 | 1092 | ||
| @@ -1327,6 +1330,8 @@ struct kvm_s390_ucas_mapping { · 237 unmodified lines | |||
| 1327 | #define KVM_PPC_GET_RMMU_INFO _IOW(KVMIO, 0xb0, struct kvm_ppc_rmmu_info) | 1330 | #define KVM_PPC_GET_RMMU_INFO _IOW(KVMIO, 0xb0, struct kvm_ppc_rmmu_info) |
| 1328 | /* Available with KVM_CAP_PPC_GET_CPU_CHAR */ | 1331 | /* Available with KVM_CAP_PPC_GET_CPU_CHAR */ |
| 1329 | #define KVM_PPC_GET_CPU_CHAR _IOR(KVMIO, 0xb1, struct kvm_ppc_cpu_char) | 1332 | #define KVM_PPC_GET_CPU_CHAR _IOR(KVMIO, 0xb1, struct kvm_ppc_cpu_char) |
| 1333 | /* Available with KVM_CAP_PMU_EVENT_FILTER */ | ||
| 1334 | #define KVM_SET_PMU_EVENT_FILTER _IOW(KVMIO, 0xb2, struct kvm_pmu_event_filter) | ||
| 1330 | 1335 | ||
| 1331 | /* ioctl for vm fd */ | 1336 | /* ioctl for vm fd */ |
| 1332 | #define KVM_CREATE_DEVICE _IOWR(KVMIO, 0xe0, struct kvm_create_device) | 1337 | #define KVM_CREATE_DEVICE _IOWR(KVMIO, 0xe0, struct kvm_create_device) |
| @@ -28,6 +28,7 @@ · 27 unmodified lines | |||
| 28 | #define KVM_HC_MIPS_CONSOLE_OUTPUT 8 | 28 | #define KVM_HC_MIPS_CONSOLE_OUTPUT 8 |
| 29 | #define KVM_HC_CLOCK_PAIRING 9 | 29 | #define KVM_HC_CLOCK_PAIRING 9 |
| 30 | #define KVM_HC_SEND_IPI 10 | 30 | #define KVM_HC_SEND_IPI 10 |
| 31 | #define KVM_HC_SCHED_YIELD 11 | ||
| 31 | 32 | ||
| 32 | /* | 33 | /* |
| 33 | * hypercalls use architecture specific | 34 | * hypercalls use architecture specific |
| @@ -92,5 +92,6 @@ · 91 unmodified lines | |||
| 92 | #define BALLOON_KVM_MAGIC 0x13661366 | 92 | #define BALLOON_KVM_MAGIC 0x13661366 |
| 93 | #define ZSMALLOC_MAGIC 0x58295829 | 93 | #define ZSMALLOC_MAGIC 0x58295829 |
| 94 | #define DMA_BUF_MAGIC 0x444d4142 /* "DMAB" */ | 94 | #define DMA_BUF_MAGIC 0x444d4142 /* "DMAB" */ |
| 95 | #define Z3FOLD_MAGIC 0x33 | ||
| 95 | 96 | ||
| 96 | #endif /* __LINUX_MAGIC_H__ */ | 97 | #endif /* __LINUX_MAGIC_H__ */ |
| @@ -146,7 +146,7 @@ struct media_device_info { · 145 unmodified lines | |||
| 146 | #define MEDIA_ENT_FL_CONNECTOR (1 << 1) | 146 | #define MEDIA_ENT_FL_CONNECTOR (1 << 1) |
| 147 | 147 | ||
| 148 | /* OR with the entity id value to find the next entity */ | 148 | /* OR with the entity id value to find the next entity */ |
| 149 | #define MEDIA_ENT_ID_FLAG_NEXT (1 << 31) | 149 | #define MEDIA_ENT_ID_FLAG_NEXT (1U << 31) |
| 150 | 150 | ||
| 151 | struct media_entity_desc { | 151 | struct media_entity_desc { |
| 152 | __u32 id; | 152 | __u32 id; |
| @@ -121,6 +121,8 @@ · 120 unmodified lines | |||
| 121 | #define EXPANSION_MFAULTS 0x0010 /* Multiple faults detected */ | 121 | #define EXPANSION_MFAULTS 0x0010 /* Multiple faults detected */ |
| 122 | #define EXPANSION_RESV 0xffe0 /* Unused... */ | 122 | #define EXPANSION_RESV 0xffe0 /* Unused... */ |
| 123 | 123 | ||
| 124 | #define ESTATUS_1000_XFULL 0x8000 /* Can do 1000BaseX Full */ | ||
| 125 | #define ESTATUS_1000_XHALF 0x4000 /* Can do 1000BaseX Half */ | ||
| 124 | #define ESTATUS_1000_TFULL 0x2000 /* Can do 1000BT Full */ | 126 | #define ESTATUS_1000_TFULL 0x2000 /* Can do 1000BT Full */ |
| 125 | #define ESTATUS_1000_THALF 0x1000 /* Can do 1000BT Half */ | 127 | #define ESTATUS_1000_THALF 0x1000 /* Can do 1000BT Half */ |
| 126 | 128 | ||
| @@ -2,7 +2,7 @@ · 1 unmodified line | |||
| 2 | /* Copyright (C) 2000-2002 Joakim Axelsson <gozem@linux.nu> | 2 | /* Copyright (C) 2000-2002 Joakim Axelsson <gozem@linux.nu> |
| 3 | * Patrick Schaaf <bof@bof.de> | 3 | * Patrick Schaaf <bof@bof.de> |
| 4 | * Martin Josefsson <gandalf@wlug.westbo.se> | 4 | * Martin Josefsson <gandalf@wlug.westbo.se> |
| 5 | * Copyright (C) 2003-2011 Jozsef Kadlecsik <kadlec@blackhole.kfki.hu> | 5 | * Copyright (C) 2003-2011 Jozsef Kadlecsik <kadlec@netfilter.org> |
| 6 | * | 6 | * |
| 7 | * This program is free software; you can redistribute it and/or modify | 7 | * This program is free software; you can redistribute it and/or modify |
| 8 | * it under the terms of the GNU General Public License version 2 as | 8 | * it under the terms of the GNU General Public License version 2 as |
| @@ -0,0 +1,23 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | #ifndef _NF_SYNPROXY_H | ||
| 3 | #define _NF_SYNPROXY_H | ||
| 4 | |||
| 5 | #include <linux/types.h> | ||
| 6 | |||
| 7 | #define NF_SYNPROXY_OPT_MSS 0x01 | ||
| 8 | #define NF_SYNPROXY_OPT_WSCALE 0x02 | ||
| 9 | #define NF_SYNPROXY_OPT_SACK_PERM 0x04 | ||
| 10 | #define NF_SYNPROXY_OPT_TIMESTAMP 0x08 | ||
| 11 | #define NF_SYNPROXY_OPT_ECN 0x10 | ||
| 12 | #define NF_SYNPROXY_OPT_MASK (NF_SYNPROXY_OPT_MSS | \ | ||
| 13 | NF_SYNPROXY_OPT_WSCALE | \ | ||
| 14 | NF_SYNPROXY_OPT_SACK_PERM | \ | ||
| 15 | NF_SYNPROXY_OPT_TIMESTAMP) | ||
| 16 | |||
| 17 | struct nf_synproxy_info { | ||
| 18 | __u8 options; | ||
| 19 | __u8 wscale; | ||
| 20 | __u16 mss; | ||
| 21 | }; | ||
| 22 | |||
| 23 | #endif /* _NF_SYNPROXY_H */ | ||
| @@ -192,6 +192,7 @@ enum nft_table_attributes { · 191 unmodified lines | |||
| 192 | * @NFTA_CHAIN_USE: number of references to this chain (NLA_U32) | 192 | * @NFTA_CHAIN_USE: number of references to this chain (NLA_U32) |
| 193 | * @NFTA_CHAIN_TYPE: type name of the string (NLA_NUL_STRING) | 193 | * @NFTA_CHAIN_TYPE: type name of the string (NLA_NUL_STRING) |
| 194 | * @NFTA_CHAIN_COUNTERS: counter specification of the chain (NLA_NESTED: nft_counter_attributes) | 194 | * @NFTA_CHAIN_COUNTERS: counter specification of the chain (NLA_NESTED: nft_counter_attributes) |
| 195 | * @NFTA_CHAIN_FLAGS: chain flags | ||
| 195 | */ | 196 | */ |
| 196 | enum nft_chain_attributes { | 197 | enum nft_chain_attributes { |
| 197 | NFTA_CHAIN_UNSPEC, | 198 | NFTA_CHAIN_UNSPEC, |
| @@ -204,6 +205,7 @@ enum nft_chain_attributes { · 6 unmodified lines | |||
| 204 | NFTA_CHAIN_TYPE, | 205 | NFTA_CHAIN_TYPE, |
| 205 | NFTA_CHAIN_COUNTERS, | 206 | NFTA_CHAIN_COUNTERS, |
| 206 | NFTA_CHAIN_PAD, | 207 | NFTA_CHAIN_PAD, |
| 208 | NFTA_CHAIN_FLAGS, | ||
| 207 | __NFTA_CHAIN_MAX | 209 | __NFTA_CHAIN_MAX |
| 208 | }; | 210 | }; |
| 209 | #define NFTA_CHAIN_MAX (__NFTA_CHAIN_MAX - 1) | 211 | #define NFTA_CHAIN_MAX (__NFTA_CHAIN_MAX - 1) |
| @@ -730,10 +732,12 @@ enum nft_exthdr_flags { · 520 unmodified lines | |||
| 730 | * | 732 | * |
| 731 | * @NFT_EXTHDR_OP_IPV6: match against ipv6 extension headers | 733 | * @NFT_EXTHDR_OP_IPV6: match against ipv6 extension headers |
| 732 | * @NFT_EXTHDR_OP_TCP: match against tcp options | 734 | * @NFT_EXTHDR_OP_TCP: match against tcp options |
| 735 | * @NFT_EXTHDR_OP_IPV4: match against ipv4 options | ||
| 733 | */ | 736 | */ |
| 734 | enum nft_exthdr_op { | 737 | enum nft_exthdr_op { |
| 735 | NFT_EXTHDR_OP_IPV6, | 738 | NFT_EXTHDR_OP_IPV6, |
| 736 | NFT_EXTHDR_OP_TCPOPT, | 739 | NFT_EXTHDR_OP_TCPOPT, |
| 740 | NFT_EXTHDR_OP_IPV4, | ||
| 737 | __NFT_EXTHDR_OP_MAX | 741 | __NFT_EXTHDR_OP_MAX |
| 738 | }; | 742 | }; |
| 739 | #define NFT_EXTHDR_OP_MAX (__NFT_EXTHDR_OP_MAX - 1) | 743 | #define NFT_EXTHDR_OP_MAX (__NFT_EXTHDR_OP_MAX - 1) |
| @@ -793,6 +797,8 @@ enum nft_exthdr_attributes { · 53 unmodified lines | |||
| 793 | * @NFT_META_SECPATH: boolean, secpath_exists (!!skb->sp) | 797 | * @NFT_META_SECPATH: boolean, secpath_exists (!!skb->sp) |
| 794 | * @NFT_META_IIFKIND: packet input interface kind name (dev->rtnl_link_ops->kind) | 798 | * @NFT_META_IIFKIND: packet input interface kind name (dev->rtnl_link_ops->kind) |
| 795 | * @NFT_META_OIFKIND: packet output interface kind name (dev->rtnl_link_ops->kind) | 799 | * @NFT_META_OIFKIND: packet output interface kind name (dev->rtnl_link_ops->kind) |
| 800 | * @NFT_META_BRI_IIFPVID: packet input bridge port pvid | ||
| 801 | * @NFT_META_BRI_IIFVPROTO: packet input bridge vlan proto | ||
| 796 | */ | 802 | */ |
| 797 | enum nft_meta_keys { | 803 | enum nft_meta_keys { |
| 798 | NFT_META_LEN, | 804 | NFT_META_LEN, |
| @@ -823,6 +829,8 @@ enum nft_meta_keys { · 24 unmodified lines | |||
| 823 | NFT_META_SECPATH, | 829 | NFT_META_SECPATH, |
| 824 | NFT_META_IIFKIND, | 830 | NFT_META_IIFKIND, |
| 825 | NFT_META_OIFKIND, | 831 | NFT_META_OIFKIND, |
| 832 | NFT_META_BRI_IIFPVID, | ||
| 833 | NFT_META_BRI_IIFVPROTO, | ||
| 826 | }; | 834 | }; |
| 827 | 835 | ||
| 828 | /** | 836 | /** |
| @@ -1445,6 +1453,17 @@ enum nft_ct_timeout_timeout_attributes { · 616 unmodified lines | |||
| 1445 | }; | 1453 | }; |
| 1446 | #define NFTA_CT_TIMEOUT_MAX (__NFTA_CT_TIMEOUT_MAX - 1) | 1454 | #define NFTA_CT_TIMEOUT_MAX (__NFTA_CT_TIMEOUT_MAX - 1) |
| 1447 | 1455 | ||
| 1456 | enum nft_ct_expectation_attributes { | ||
| 1457 | NFTA_CT_EXPECT_UNSPEC, | ||
| 1458 | NFTA_CT_EXPECT_L3PROTO, | ||
| 1459 | NFTA_CT_EXPECT_L4PROTO, | ||
| 1460 | NFTA_CT_EXPECT_DPORT, | ||
| 1461 | NFTA_CT_EXPECT_TIMEOUT, | ||
| 1462 | NFTA_CT_EXPECT_SIZE, | ||
| 1463 | __NFTA_CT_EXPECT_MAX, | ||
| 1464 | }; | ||
| 1465 | #define NFTA_CT_EXPECT_MAX (__NFTA_CT_EXPECT_MAX - 1) | ||
| 1466 | |||
| 1448 | #define NFT_OBJECT_UNSPEC 0 | 1467 | #define NFT_OBJECT_UNSPEC 0 |
| 1449 | #define NFT_OBJECT_COUNTER 1 | 1468 | #define NFT_OBJECT_COUNTER 1 |
| 1450 | #define NFT_OBJECT_QUOTA 2 | 1469 | #define NFT_OBJECT_QUOTA 2 |
| @@ -1454,7 +1473,8 @@ enum nft_ct_timeout_timeout_attributes { · 3 unmodified lines | |||
| 1454 | #define NFT_OBJECT_TUNNEL 6 | 1473 | #define NFT_OBJECT_TUNNEL 6 |
| 1455 | #define NFT_OBJECT_CT_TIMEOUT 7 | 1474 | #define NFT_OBJECT_CT_TIMEOUT 7 |
| 1456 | #define NFT_OBJECT_SECMARK 8 | 1475 | #define NFT_OBJECT_SECMARK 8 |
| 1457 | #define __NFT_OBJECT_MAX 9 | 1476 | #define NFT_OBJECT_CT_EXPECT 9 |
| 1477 | #define __NFT_OBJECT_MAX 10 | ||
| 1458 | #define NFT_OBJECT_MAX (__NFT_OBJECT_MAX - 1) | 1478 | #define NFT_OBJECT_MAX (__NFT_OBJECT_MAX - 1) |
| 1459 | 1479 | ||
| 1460 | /** | 1480 | /** |
| @@ -1537,6 +1557,22 @@ enum nft_osf_flags { · 76 unmodified lines | |||
| 1537 | NFT_OSF_F_VERSION = (1 << 0), | 1557 | NFT_OSF_F_VERSION = (1 << 0), |
| 1538 | }; | 1558 | }; |
| 1539 | 1559 | ||
| 1560 | /** | ||
| 1561 | * enum nft_synproxy_attributes - nf_tables synproxy expression netlink attributes | ||
| 1562 | * | ||
| 1563 | * @NFTA_SYNPROXY_MSS: mss value sent to the backend (NLA_U16) | ||
| 1564 | * @NFTA_SYNPROXY_WSCALE: wscale value sent to the backend (NLA_U8) | ||
| 1565 | * @NFTA_SYNPROXY_FLAGS: flags (NLA_U32) | ||
| 1566 | */ | ||
| 1567 | enum nft_synproxy_attributes { | ||
| 1568 | NFTA_SYNPROXY_UNSPEC, | ||
| 1569 | NFTA_SYNPROXY_MSS, | ||
| 1570 | NFTA_SYNPROXY_WSCALE, | ||
| 1571 | NFTA_SYNPROXY_FLAGS, | ||
| 1572 | __NFTA_SYNPROXY_MAX, | ||
| 1573 | }; | ||
| 1574 | #define NFTA_SYNPROXY_MAX (__NFTA_SYNPROXY_MAX - 1) | ||
| 1575 | |||
| 1540 | /** | 1576 | /** |
| 1541 | * enum nft_device_attributes - nf_tables device netlink attributes | 1577 | * enum nft_device_attributes - nf_tables device netlink attributes |
| 1542 | * | 1578 | * |
| @@ -2,18 +2,14 @@ · 1 unmodified line | |||
| 2 | #ifndef _XT_SYNPROXY_H | 2 | #ifndef _XT_SYNPROXY_H |
| 3 | #define _XT_SYNPROXY_H | 3 | #define _XT_SYNPROXY_H |
| 4 | 4 | ||
| 5 | #include <linux/types.h> | 5 | #include <linux/netfilter/nf_synproxy.h> |
| 6 | 6 | ||
| 7 | #define XT_SYNPROXY_OPT_MSS 0x01 | 7 | #define XT_SYNPROXY_OPT_MSS NF_SYNPROXY_OPT_MSS |
| 8 | #define XT_SYNPROXY_OPT_WSCALE 0x02 | 8 | #define XT_SYNPROXY_OPT_WSCALE NF_SYNPROXY_OPT_WSCALE |
| 9 | #define XT_SYNPROXY_OPT_SACK_PERM 0x04 | 9 | #define XT_SYNPROXY_OPT_SACK_PERM NF_SYNPROXY_OPT_SACK_PERM |
| 10 | #define XT_SYNPROXY_OPT_TIMESTAMP 0x08 | 10 | #define XT_SYNPROXY_OPT_TIMESTAMP NF_SYNPROXY_OPT_TIMESTAMP |
| 11 | #define XT_SYNPROXY_OPT_ECN 0x10 | 11 | #define XT_SYNPROXY_OPT_ECN NF_SYNPROXY_OPT_ECN |
| 12 | 12 | ||
| 13 | struct xt_synproxy_info { | 13 | #define xt_synproxy_info nf_synproxy_info |
| 14 | __u8 options; | ||
| 15 | __u8 wscale; | ||
| 16 | __u16 mss; | ||
| 17 | }; | ||
| 18 | 14 | ||
| 19 | #endif /* _XT_SYNPROXY_H */ | 15 | #endif /* _XT_SYNPROXY_H */ |
| @@ -5,11 +5,17 @@ · 4 unmodified lines | |||
| 5 | #include <linux/types.h> | 5 | #include <linux/types.h> |
| 6 | 6 | ||
| 7 | enum { | 7 | enum { |
| 8 | XT_OWNER_UID = 1 << 0, | 8 | XT_OWNER_UID = 1 << 0, |
| 9 | XT_OWNER_GID = 1 << 1, | 9 | XT_OWNER_GID = 1 << 1, |
| 10 | XT_OWNER_SOCKET = 1 << 2, | 10 | XT_OWNER_SOCKET = 1 << 2, |
| 11 | XT_OWNER_SUPPL_GROUPS = 1 << 3, | ||
| 11 | }; | 12 | }; |
| 12 | 13 | ||
| 14 | #define XT_OWNER_MASK (XT_OWNER_UID | \ | ||
| 15 | XT_OWNER_GID | \ | ||
| 16 | XT_OWNER_SOCKET | \ | ||
| 17 | XT_OWNER_SUPPL_GROUPS) | ||
| 18 | |||
| 13 | struct xt_owner_match_info { | 19 | struct xt_owner_match_info { |
| 14 | __u32 uid_min, uid_max; | 20 | __u32 uid_min, uid_max; |
| 15 | __u32 gid_min, gid_max; | 21 | __u32 gid_min, gid_max; |
| @@ -0,0 +1,56 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | #ifndef _UAPI_LINUX_NEXTHOP_H | ||
| 3 | #define _UAPI_LINUX_NEXTHOP_H | ||
| 4 | |||
| 5 | #include <linux/types.h> | ||
| 6 | |||
| 7 | struct nhmsg { | ||
| 8 | unsigned char nh_family; | ||
| 9 | unsigned char nh_scope; /* return only */ | ||
| 10 | unsigned char nh_protocol; /* Routing protocol that installed nh */ | ||
| 11 | unsigned char resvd; | ||
| 12 | unsigned int nh_flags; /* RTNH_F flags */ | ||
| 13 | }; | ||
| 14 | |||
| 15 | /* entry in a nexthop group */ | ||
| 16 | struct nexthop_grp { | ||
| 17 | __u32 id; /* nexthop id - must exist */ | ||
| 18 | __u8 weight; /* weight of this nexthop */ | ||
| 19 | __u8 resvd1; | ||
| 20 | __u16 resvd2; | ||
| 21 | }; | ||
| 22 | |||
| 23 | enum { | ||
| 24 | NEXTHOP_GRP_TYPE_MPATH, /* default type if not specified */ | ||
| 25 | __NEXTHOP_GRP_TYPE_MAX, | ||
| 26 | }; | ||
| 27 | |||
| 28 | #define NEXTHOP_GRP_TYPE_MAX (__NEXTHOP_GRP_TYPE_MAX - 1) | ||
| 29 | |||
| 30 | enum { | ||
| 31 | NHA_UNSPEC, | ||
| 32 | NHA_ID, /* u32; id for nexthop. id == 0 means auto-assign */ | ||
| 33 | |||
| 34 | NHA_GROUP, /* array of nexthop_grp */ | ||
| 35 | NHA_GROUP_TYPE, /* u16 one of NEXTHOP_GRP_TYPE */ | ||
| 36 | /* if NHA_GROUP attribute is added, no other attributes can be set */ | ||
| 37 | |||
| 38 | NHA_BLACKHOLE, /* flag; nexthop used to blackhole packets */ | ||
| 39 | /* if NHA_BLACKHOLE is added, OIF, GATEWAY, ENCAP can not be set */ | ||
| 40 | |||
| 41 | NHA_OIF, /* u32; nexthop device */ | ||
| 42 | NHA_GATEWAY, /* be32 (IPv4) or in6_addr (IPv6) gw address */ | ||
| 43 | NHA_ENCAP_TYPE, /* u16; lwt encap type */ | ||
| 44 | NHA_ENCAP, /* lwt encap data */ | ||
| 45 | |||
| 46 | /* NHA_OIF can be appended to dump request to return only | ||
| 47 | * nexthops using given device | ||
| 48 | */ | ||
| 49 | NHA_GROUPS, /* flag; only return nexthop groups in dump */ | ||
| 50 | NHA_MASTER, /* u32; only return nexthops with given master dev */ | ||
| 51 | |||
| 52 | __NHA_MAX, | ||
| 53 | }; | ||
| 54 | |||
| 55 | #define NHA_MAX (__NHA_MAX - 1) | ||
| 56 | #endif | ||
| @@ -29,7 +29,7 @@ · 28 unmodified lines | |||
| 29 | 29 | ||
| 30 | #include <linux/types.h> | 30 | #include <linux/types.h> |
| 31 | #include <linux/magic.h> | 31 | #include <linux/magic.h> |
| 32 | 32 | #include <asm/byteorder.h> | |
| 33 | 33 | ||
| 34 | #define NILFS_INODE_BMAP_SIZE 7 | 34 | #define NILFS_INODE_BMAP_SIZE 7 |
| 35 | 35 | ||
| @@ -533,19 +533,19 @@ enum { · 497 unmodified lines | |||
| 533 | static inline void \ | 533 | static inline void \ |
| 534 | nilfs_checkpoint_set_##name(struct nilfs_checkpoint *cp) \ | 534 | nilfs_checkpoint_set_##name(struct nilfs_checkpoint *cp) \ |
| 535 | { \ | 535 | { \ |
| 536 | cp->cp_flags = cpu_to_le32(le32_to_cpu(cp->cp_flags) | \ | 536 | cp->cp_flags = __cpu_to_le32(__le32_to_cpu(cp->cp_flags) | \ |
| 537 | (1UL << NILFS_CHECKPOINT_##flag)); \ | 537 | (1UL << NILFS_CHECKPOINT_##flag)); \ |
| 538 | } \ | 538 | } \ |
| 539 | static inline void \ | 539 | static inline void \ |
| 540 | nilfs_checkpoint_clear_##name(struct nilfs_checkpoint *cp) \ | 540 | nilfs_checkpoint_clear_##name(struct nilfs_checkpoint *cp) \ |
| 541 | { \ | 541 | { \ |
| 542 | cp->cp_flags = cpu_to_le32(le32_to_cpu(cp->cp_flags) & \ | 542 | cp->cp_flags = __cpu_to_le32(__le32_to_cpu(cp->cp_flags) & \ |
| 543 | ~(1UL << NILFS_CHECKPOINT_##flag)); \ | 543 | ~(1UL << NILFS_CHECKPOINT_##flag)); \ |
| 544 | } \ | 544 | } \ |
| 545 | static inline int \ | 545 | static inline int \ |
| 546 | nilfs_checkpoint_##name(const struct nilfs_checkpoint *cp) \ | 546 | nilfs_checkpoint_##name(const struct nilfs_checkpoint *cp) \ |
| 547 | { \ | 547 | { \ |
| 548 | return !!(le32_to_cpu(cp->cp_flags) & \ | 548 | return !!(__le32_to_cpu(cp->cp_flags) & \ |
| 549 | (1UL << NILFS_CHECKPOINT_##flag)); \ | 549 | (1UL << NILFS_CHECKPOINT_##flag)); \ |
| 550 | } | 550 | } |
| 551 | 551 | ||
| @@ -595,20 +595,20 @@ enum { · 43 unmodified lines | |||
| 595 | static inline void \ | 595 | static inline void \ |
| 596 | nilfs_segment_usage_set_##name(struct nilfs_segment_usage *su) \ | 596 | nilfs_segment_usage_set_##name(struct nilfs_segment_usage *su) \ |
| 597 | { \ | 597 | { \ |
| 598 | su->su_flags = cpu_to_le32(le32_to_cpu(su->su_flags) | \ | 598 | su->su_flags = __cpu_to_le32(__le32_to_cpu(su->su_flags) | \ |
| 599 | (1UL << NILFS_SEGMENT_USAGE_##flag));\ | 599 | (1UL << NILFS_SEGMENT_USAGE_##flag));\ |
| 600 | } \ | 600 | } \ |
| 601 | static inline void \ | 601 | static inline void \ |
| 602 | nilfs_segment_usage_clear_##name(struct nilfs_segment_usage *su) \ | 602 | nilfs_segment_usage_clear_##name(struct nilfs_segment_usage *su) \ |
| 603 | { \ | 603 | { \ |
| 604 | su->su_flags = \ | 604 | su->su_flags = \ |
| 605 | cpu_to_le32(le32_to_cpu(su->su_flags) & \ | 605 | __cpu_to_le32(__le32_to_cpu(su->su_flags) & \ |
| 606 | ~(1UL << NILFS_SEGMENT_USAGE_##flag)); \ | 606 | ~(1UL << NILFS_SEGMENT_USAGE_##flag)); \ |
| 607 | } \ | 607 | } \ |
| 608 | static inline int \ | 608 | static inline int \ |
| 609 | nilfs_segment_usage_##name(const struct nilfs_segment_usage *su) \ | 609 | nilfs_segment_usage_##name(const struct nilfs_segment_usage *su) \ |
| 610 | { \ | 610 | { \ |
| 611 | return !!(le32_to_cpu(su->su_flags) & \ | 611 | return !!(__le32_to_cpu(su->su_flags) & \ |
| 612 | (1UL << NILFS_SEGMENT_USAGE_##flag)); \ | 612 | (1UL << NILFS_SEGMENT_USAGE_##flag)); \ |
| 613 | } | 613 | } |
| 614 | 614 | ||
| @@ -619,15 +619,15 @@ NILFS_SEGMENT_USAGE_FNS(ERROR, error) · 4 unmodified lines | |||
| 619 | static inline void | 619 | static inline void |
| 620 | nilfs_segment_usage_set_clean(struct nilfs_segment_usage *su) | 620 | nilfs_segment_usage_set_clean(struct nilfs_segment_usage *su) |
| 621 | { | 621 | { |
| 622 | su->su_lastmod = cpu_to_le64(0); | 622 | su->su_lastmod = __cpu_to_le64(0); |
| 623 | su->su_nblocks = cpu_to_le32(0); | 623 | su->su_nblocks = __cpu_to_le32(0); |
| 624 | su->su_flags = cpu_to_le32(0); | 624 | su->su_flags = __cpu_to_le32(0); |
| 625 | } | 625 | } |
| 626 | 626 | ||
| 627 | static inline int | 627 | static inline int |
| 628 | nilfs_segment_usage_clean(const struct nilfs_segment_usage *su) | 628 | nilfs_segment_usage_clean(const struct nilfs_segment_usage *su) |
| 629 | { | 629 | { |
| 630 | return !le32_to_cpu(su->su_flags); | 630 | return !__le32_to_cpu(su->su_flags); |
| 631 | } | 631 | } |
| 632 | 632 | ||
| 633 | /** | 633 | /** |
| @@ -234,6 +234,15 @@ · 233 unmodified lines | |||
| 234 | * use in a FILS shared key connection with PMKSA caching. | 234 | * use in a FILS shared key connection with PMKSA caching. |
| 235 | */ | 235 | */ |
| 236 | 236 | ||
| 237 | /** | ||
| 238 | * DOC: SAE authentication offload | ||
| 239 | * | ||
| 240 | * By setting @NL80211_EXT_FEATURE_SAE_OFFLOAD flag drivers can indicate they | ||
| 241 | * support offloading SAE authentication for WPA3-Personal networks. In | ||
| 242 | * %NL80211_CMD_CONNECT the password for SAE should be specified using | ||
| 243 | * %NL80211_ATTR_SAE_PASSWORD. | ||
| 244 | */ | ||
| 245 | |||
| 237 | /** | 246 | /** |
| 238 | * enum nl80211_commands - supported nl80211 commands | 247 | * enum nl80211_commands - supported nl80211 commands |
| 239 | * | 248 | * |
| @@ -2341,6 +2350,12 @@ enum nl80211_commands { · 2101 unmodified lines | |||
| 2341 | * should be picking up the lowest tx power, either tx power per-interface | 2350 | * should be picking up the lowest tx power, either tx power per-interface |
| 2342 | * or per-station. | 2351 | * or per-station. |
| 2343 | * | 2352 | * |
| 2353 | * @NL80211_ATTR_SAE_PASSWORD: attribute for passing SAE password material. It | ||
| 2354 | * is used with %NL80211_CMD_CONNECT to provide password for offloading | ||
| 2355 | * SAE authentication for WPA3-Personal networks. | ||
| 2356 | * | ||
| 2357 | * @NL80211_ATTR_TWT_RESPONDER: Enable target wait time responder support. | ||
| 2358 | * | ||
| 2344 | * @NUM_NL80211_ATTR: total number of nl80211_attrs available | 2359 | * @NUM_NL80211_ATTR: total number of nl80211_attrs available |
| 2345 | * @NL80211_ATTR_MAX: highest attribute number currently defined | 2360 | * @NL80211_ATTR_MAX: highest attribute number currently defined |
| 2346 | * @__NL80211_ATTR_AFTER_LAST: internal use | 2361 | * @__NL80211_ATTR_AFTER_LAST: internal use |
| @@ -2794,6 +2809,10 @@ enum nl80211_attrs { · 447 unmodified lines | |||
| 2794 | NL80211_ATTR_STA_TX_POWER_SETTING, | 2809 | NL80211_ATTR_STA_TX_POWER_SETTING, |
| 2795 | NL80211_ATTR_STA_TX_POWER, | 2810 | NL80211_ATTR_STA_TX_POWER, |
| 2796 | 2811 | ||
| 2812 | NL80211_ATTR_SAE_PASSWORD, | ||
| 2813 | |||
| 2814 | NL80211_ATTR_TWT_RESPONDER, | ||
| 2815 | |||
| 2797 | /* add attributes here, update the policy in nl80211.c */ | 2816 | /* add attributes here, update the policy in nl80211.c */ |
| 2798 | 2817 | ||
| 2799 | __NL80211_ATTR_AFTER_LAST, | 2818 | __NL80211_ATTR_AFTER_LAST, |
| @@ -2844,7 +2863,7 @@ enum nl80211_attrs { · 44 unmodified lines | |||
| 2844 | #define NL80211_HT_CAPABILITY_LEN 26 | 2863 | #define NL80211_HT_CAPABILITY_LEN 26 |
| 2845 | #define NL80211_VHT_CAPABILITY_LEN 12 | 2864 | #define NL80211_VHT_CAPABILITY_LEN 12 |
| 2846 | #define NL80211_HE_MIN_CAPABILITY_LEN 16 | 2865 | #define NL80211_HE_MIN_CAPABILITY_LEN 16 |
| 2847 | #define NL80211_HE_MAX_CAPABILITY_LEN 51 | 2866 | #define NL80211_HE_MAX_CAPABILITY_LEN 54 |
| 2848 | #define NL80211_MAX_NR_CIPHER_SUITES 5 | 2867 | #define NL80211_MAX_NR_CIPHER_SUITES 5 |
| 2849 | #define NL80211_MAX_NR_AKM_SUITES 2 | 2868 | #define NL80211_MAX_NR_AKM_SUITES 2 |
| 2850 | 2869 | ||
| @@ -4406,6 +4425,7 @@ enum nl80211_mfp { · 1555 unmodified lines | |||
| 4406 | enum nl80211_wpa_versions { | 4425 | enum nl80211_wpa_versions { |
| 4407 | NL80211_WPA_VERSION_1 = 1 << 0, | 4426 | NL80211_WPA_VERSION_1 = 1 << 0, |
| 4408 | NL80211_WPA_VERSION_2 = 1 << 1, | 4427 | NL80211_WPA_VERSION_2 = 1 << 1, |
| 4428 | NL80211_WPA_VERSION_3 = 1 << 2, | ||
| 4409 | }; | 4429 | }; |
| 4410 | 4430 | ||
| 4411 | /** | 4431 | /** |
| @@ -5314,7 +5334,7 @@ enum nl80211_feature_flags { · 902 unmodified lines | |||
| 5314 | NL80211_FEATURE_TDLS_CHANNEL_SWITCH = 1 << 28, | 5334 | NL80211_FEATURE_TDLS_CHANNEL_SWITCH = 1 << 28, |
| 5315 | NL80211_FEATURE_SCAN_RANDOM_MAC_ADDR = 1 << 29, | 5335 | NL80211_FEATURE_SCAN_RANDOM_MAC_ADDR = 1 << 29, |
| 5316 | NL80211_FEATURE_SCHED_SCAN_RANDOM_MAC_ADDR = 1 << 30, | 5336 | NL80211_FEATURE_SCHED_SCAN_RANDOM_MAC_ADDR = 1 << 30, |
| 5317 | NL80211_FEATURE_ND_RANDOM_MAC_ADDR = 1 << 31, | 5337 | NL80211_FEATURE_ND_RANDOM_MAC_ADDR = 1U << 31, |
| 5318 | }; | 5338 | }; |
| 5319 | 5339 | ||
| 5320 | /** | 5340 | /** |
| @@ -5422,6 +5442,9 @@ enum nl80211_feature_flags { · 101 unmodified lines | |||
| 5422 | * @NL80211_EXT_FEATURE_STA_TX_PWR: This driver supports controlling tx power | 5442 | * @NL80211_EXT_FEATURE_STA_TX_PWR: This driver supports controlling tx power |
| 5423 | * to a station. | 5443 | * to a station. |
| 5424 | * | 5444 | * |
| 5445 | * @NL80211_EXT_FEATURE_SAE_OFFLOAD: Device wants to do SAE authentication in | ||
| 5446 | * station mode (SAE password is passed as part of the connect command). | ||
| 5447 | * | ||
| 5425 | * @NUM_NL80211_EXT_FEATURES: number of extended features. | 5448 | * @NUM_NL80211_EXT_FEATURES: number of extended features. |
| 5426 | * @MAX_NL80211_EXT_FEATURES: highest extended feature index. | 5449 | * @MAX_NL80211_EXT_FEATURES: highest extended feature index. |
| 5427 | */ | 5450 | */ |
| @@ -5466,6 +5489,7 @@ enum nl80211_ext_feature_index { · 38 unmodified lines | |||
| 5466 | NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD, | 5489 | NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD, |
| 5467 | NL80211_EXT_FEATURE_EXT_KEY_ID, | 5490 | NL80211_EXT_FEATURE_EXT_KEY_ID, |
| 5468 | NL80211_EXT_FEATURE_STA_TX_PWR, | 5491 | NL80211_EXT_FEATURE_STA_TX_PWR, |
| 5492 | NL80211_EXT_FEATURE_SAE_OFFLOAD, | ||
| 5469 | 5493 | ||
| 5470 | /* add new features before the definition below */ | 5494 | /* add new features before the definition below */ |
| 5471 | NUM_NL80211_EXT_FEATURES, | 5495 | NUM_NL80211_EXT_FEATURES, |
| @@ -528,6 +528,7 @@ · 527 unmodified lines | |||
| 528 | #define PCI_EXP_LNKCAP_SLS_5_0GB 0x00000002 /* LNKCAP2 SLS Vector bit 1 */ | 528 | #define PCI_EXP_LNKCAP_SLS_5_0GB 0x00000002 /* LNKCAP2 SLS Vector bit 1 */ |
| 529 | #define PCI_EXP_LNKCAP_SLS_8_0GB 0x00000003 /* LNKCAP2 SLS Vector bit 2 */ | 529 | #define PCI_EXP_LNKCAP_SLS_8_0GB 0x00000003 /* LNKCAP2 SLS Vector bit 2 */ |
| 530 | #define PCI_EXP_LNKCAP_SLS_16_0GB 0x00000004 /* LNKCAP2 SLS Vector bit 3 */ | 530 | #define PCI_EXP_LNKCAP_SLS_16_0GB 0x00000004 /* LNKCAP2 SLS Vector bit 3 */ |
| 531 | #define PCI_EXP_LNKCAP_SLS_32_0GB 0x00000005 /* LNKCAP2 SLS Vector bit 4 */ | ||
| 531 | #define PCI_EXP_LNKCAP_MLW 0x000003f0 /* Maximum Link Width */ | 532 | #define PCI_EXP_LNKCAP_MLW 0x000003f0 /* Maximum Link Width */ |
| 532 | #define PCI_EXP_LNKCAP_ASPMS 0x00000c00 /* ASPM Support */ | 533 | #define PCI_EXP_LNKCAP_ASPMS 0x00000c00 /* ASPM Support */ |
| 533 | #define PCI_EXP_LNKCAP_L0SEL 0x00007000 /* L0s Exit Latency */ | 534 | #define PCI_EXP_LNKCAP_L0SEL 0x00007000 /* L0s Exit Latency */ |
| @@ -556,6 +557,7 @@ · 22 unmodified lines | |||
| 556 | #define PCI_EXP_LNKSTA_CLS_5_0GB 0x0002 /* Current Link Speed 5.0GT/s */ | 557 | #define PCI_EXP_LNKSTA_CLS_5_0GB 0x0002 /* Current Link Speed 5.0GT/s */ |
| 557 | #define PCI_EXP_LNKSTA_CLS_8_0GB 0x0003 /* Current Link Speed 8.0GT/s */ | 558 | #define PCI_EXP_LNKSTA_CLS_8_0GB 0x0003 /* Current Link Speed 8.0GT/s */ |
| 558 | #define PCI_EXP_LNKSTA_CLS_16_0GB 0x0004 /* Current Link Speed 16.0GT/s */ | 559 | #define PCI_EXP_LNKSTA_CLS_16_0GB 0x0004 /* Current Link Speed 16.0GT/s */ |
| 560 | #define PCI_EXP_LNKSTA_CLS_32_0GB 0x0005 /* Current Link Speed 32.0GT/s */ | ||
| 559 | #define PCI_EXP_LNKSTA_NLW 0x03f0 /* Negotiated Link Width */ | 561 | #define PCI_EXP_LNKSTA_NLW 0x03f0 /* Negotiated Link Width */ |
| 560 | #define PCI_EXP_LNKSTA_NLW_X1 0x0010 /* Current Link Width x1 */ | 562 | #define PCI_EXP_LNKSTA_NLW_X1 0x0010 /* Current Link Width x1 */ |
| 561 | #define PCI_EXP_LNKSTA_NLW_X2 0x0020 /* Current Link Width x2 */ | 563 | #define PCI_EXP_LNKSTA_NLW_X2 0x0020 /* Current Link Width x2 */ |
| @@ -661,6 +663,7 @@ · 99 unmodified lines | |||
| 661 | #define PCI_EXP_LNKCAP2_SLS_5_0GB 0x00000004 /* Supported Speed 5GT/s */ | 663 | #define PCI_EXP_LNKCAP2_SLS_5_0GB 0x00000004 /* Supported Speed 5GT/s */ |
| 662 | #define PCI_EXP_LNKCAP2_SLS_8_0GB 0x00000008 /* Supported Speed 8GT/s */ | 664 | #define PCI_EXP_LNKCAP2_SLS_8_0GB 0x00000008 /* Supported Speed 8GT/s */ |
| 663 | #define PCI_EXP_LNKCAP2_SLS_16_0GB 0x00000010 /* Supported Speed 16GT/s */ | 665 | #define PCI_EXP_LNKCAP2_SLS_16_0GB 0x00000010 /* Supported Speed 16GT/s */ |
| 666 | #define PCI_EXP_LNKCAP2_SLS_32_0GB 0x00000020 /* Supported Speed 32GT/s */ | ||
| 664 | #define PCI_EXP_LNKCAP2_CROSSLINK 0x00000100 /* Crosslink supported */ | 667 | #define PCI_EXP_LNKCAP2_CROSSLINK 0x00000100 /* Crosslink supported */ |
| 665 | #define PCI_EXP_LNKCTL2 48 /* Link Control 2 */ | 668 | #define PCI_EXP_LNKCTL2 48 /* Link Control 2 */ |
| 666 | #define PCI_EXP_LNKCTL2_TLS 0x000f | 669 | #define PCI_EXP_LNKCTL2_TLS 0x000f |
| @@ -668,6 +671,7 @@ · 1 unmodified line | |||
| 668 | #define PCI_EXP_LNKCTL2_TLS_5_0GT 0x0002 /* Supported Speed 5GT/s */ | 671 | #define PCI_EXP_LNKCTL2_TLS_5_0GT 0x0002 /* Supported Speed 5GT/s */ |
| 669 | #define PCI_EXP_LNKCTL2_TLS_8_0GT 0x0003 /* Supported Speed 8GT/s */ | 672 | #define PCI_EXP_LNKCTL2_TLS_8_0GT 0x0003 /* Supported Speed 8GT/s */ |
| 670 | #define PCI_EXP_LNKCTL2_TLS_16_0GT 0x0004 /* Supported Speed 16GT/s */ | 673 | #define PCI_EXP_LNKCTL2_TLS_16_0GT 0x0004 /* Supported Speed 16GT/s */ |
| 674 | #define PCI_EXP_LNKCTL2_TLS_32_0GT 0x0005 /* Supported Speed 32GT/s */ | ||
| 671 | #define PCI_EXP_LNKSTA2 50 /* Link Status 2 */ | 675 | #define PCI_EXP_LNKSTA2 50 /* Link Status 2 */ |
| 672 | #define PCI_CAP_EXP_ENDPOINT_SIZEOF_V2 52 /* v2 endpoints with link end here */ | 676 | #define PCI_CAP_EXP_ENDPOINT_SIZEOF_V2 52 /* v2 endpoints with link end here */ |
| 673 | #define PCI_EXP_SLTCAP2 52 /* Slot Capabilities 2 */ | 677 | #define PCI_EXP_SLTCAP2 52 /* Slot Capabilities 2 */ |
| @@ -104,6 +104,9 @@ enum tca_id { · 103 unmodified lines | |||
| 104 | TCA_ID_SIMP = TCA_ACT_SIMP, | 104 | TCA_ID_SIMP = TCA_ACT_SIMP, |
| 105 | TCA_ID_IFE = TCA_ACT_IFE, | 105 | TCA_ID_IFE = TCA_ACT_IFE, |
| 106 | TCA_ID_SAMPLE = TCA_ACT_SAMPLE, | 106 | TCA_ID_SAMPLE = TCA_ACT_SAMPLE, |
| 107 | TCA_ID_CTINFO, | ||
| 108 | TCA_ID_MPLS, | ||
| 109 | TCA_ID_CT, | ||
| 107 | /* other actions go here */ | 110 | /* other actions go here */ |
| 108 | __TCA_ID_MAX = 255 | 111 | __TCA_ID_MAX = 255 |
| 109 | }; | 112 | }; |
| @@ -294,7 +297,7 @@ enum { · 184 unmodified lines | |||
| 294 | TCA_FW_UNSPEC, | 297 | TCA_FW_UNSPEC, |
| 295 | TCA_FW_CLASSID, | 298 | TCA_FW_CLASSID, |
| 296 | TCA_FW_POLICE, | 299 | TCA_FW_POLICE, |
| 297 | TCA_FW_INDEV, /* used by CONFIG_NET_CLS_IND */ | 300 | TCA_FW_INDEV, |
| 298 | TCA_FW_ACT, /* used by CONFIG_NET_CLS_ACT */ | 301 | TCA_FW_ACT, /* used by CONFIG_NET_CLS_ACT */ |
| 299 | TCA_FW_MASK, | 302 | TCA_FW_MASK, |
| 300 | __TCA_FW_MAX | 303 | __TCA_FW_MAX |
| @@ -534,11 +537,27 @@ enum { · 233 unmodified lines | |||
| 534 | TCA_FLOWER_KEY_PORT_DST_MIN, /* be16 */ | 537 | TCA_FLOWER_KEY_PORT_DST_MIN, /* be16 */ |
| 535 | TCA_FLOWER_KEY_PORT_DST_MAX, /* be16 */ | 538 | TCA_FLOWER_KEY_PORT_DST_MAX, /* be16 */ |
| 536 | 539 | ||
| 540 | TCA_FLOWER_KEY_CT_STATE, /* u16 */ | ||
| 541 | TCA_FLOWER_KEY_CT_STATE_MASK, /* u16 */ | ||
| 542 | TCA_FLOWER_KEY_CT_ZONE, /* u16 */ | ||
| 543 | TCA_FLOWER_KEY_CT_ZONE_MASK, /* u16 */ | ||
| 544 | TCA_FLOWER_KEY_CT_MARK, /* u32 */ | ||
| 545 | TCA_FLOWER_KEY_CT_MARK_MASK, /* u32 */ | ||
| 546 | TCA_FLOWER_KEY_CT_LABELS, /* u128 */ | ||
| 547 | TCA_FLOWER_KEY_CT_LABELS_MASK, /* u128 */ | ||
| 548 | |||
| 537 | __TCA_FLOWER_MAX, | 549 | __TCA_FLOWER_MAX, |
| 538 | }; | 550 | }; |
| 539 | 551 | ||
| 540 | #define TCA_FLOWER_MAX (__TCA_FLOWER_MAX - 1) | 552 | #define TCA_FLOWER_MAX (__TCA_FLOWER_MAX - 1) |
| 541 | 553 | ||
| 554 | enum { | ||
| 555 | TCA_FLOWER_KEY_CT_FLAGS_NEW = 1 << 0, /* Beginning of a new connection. */ | ||
| 556 | TCA_FLOWER_KEY_CT_FLAGS_ESTABLISHED = 1 << 1, /* Part of an existing connection. */ | ||
| 557 | TCA_FLOWER_KEY_CT_FLAGS_RELATED = 1 << 2, /* Related to an established connection. */ | ||
| 558 | TCA_FLOWER_KEY_CT_FLAGS_TRACKED = 1 << 3, /* Conntrack has occurred. */ | ||
| 559 | }; | ||
| 560 | |||
| 542 | enum { | 561 | enum { |
| 543 | TCA_FLOWER_KEY_ENC_OPTS_UNSPEC, | 562 | TCA_FLOWER_KEY_ENC_OPTS_UNSPEC, |
| 544 | TCA_FLOWER_KEY_ENC_OPTS_GENEVE, /* Nested | 563 | TCA_FLOWER_KEY_ENC_OPTS_GENEVE, /* Nested |
| @@ -2,6 +2,7 @@ · 1 unmodified line | |||
| 2 | #ifndef __LINUX_PKT_SCHED_H | 2 | #ifndef __LINUX_PKT_SCHED_H |
| 3 | #define __LINUX_PKT_SCHED_H | 3 | #define __LINUX_PKT_SCHED_H |
| 4 | 4 | ||
| 5 | #include <linux/const.h> | ||
| 5 | #include <linux/types.h> | 6 | #include <linux/types.h> |
| 6 | 7 | ||
| 7 | /* Logical priority bands not depending on specific packet scheduler. | 8 | /* Logical priority bands not depending on specific packet scheduler. |
| @@ -988,8 +989,9 @@ struct tc_etf_qopt { · 980 unmodified lines | |||
| 988 | __s32 delta; | 989 | __s32 delta; |
| 989 | __s32 clockid; | 990 | __s32 clockid; |
| 990 | __u32 flags; | 991 | __u32 flags; |
| 991 | #define TC_ETF_DEADLINE_MODE_ON BIT(0) | 992 | #define TC_ETF_DEADLINE_MODE_ON _BITUL(0) |
| 992 | #define TC_ETF_OFFLOAD_ON BIT(1) | 993 | #define TC_ETF_OFFLOAD_ON _BITUL(1) |
| 994 | #define TC_ETF_SKIP_SOCK_CHECK _BITUL(2) | ||
| 993 | }; | 995 | }; |
| 994 | 996 | ||
| 995 | enum { | 997 | enum { |
| @@ -1158,6 +1160,8 @@ enum { · 162 unmodified lines | |||
| 1158 | * [TCA_TAPRIO_ATTR_SCHED_ENTRY_INTERVAL] | 1160 | * [TCA_TAPRIO_ATTR_SCHED_ENTRY_INTERVAL] |
| 1159 | */ | 1161 | */ |
| 1160 | 1162 | ||
| 1163 | #define TCA_TAPRIO_ATTR_FLAG_TXTIME_ASSIST 0x1 | ||
| 1164 | |||
| 1161 | enum { | 1165 | enum { |
| 1162 | TCA_TAPRIO_ATTR_UNSPEC, | 1166 | TCA_TAPRIO_ATTR_UNSPEC, |
| 1163 | TCA_TAPRIO_ATTR_PRIOMAP, /* struct tc_mqprio_qopt */ | 1167 | TCA_TAPRIO_ATTR_PRIOMAP, /* struct tc_mqprio_qopt */ |
| @@ -1169,6 +1173,8 @@ enum { · 5 unmodified lines | |||
| 1169 | TCA_TAPRIO_ATTR_ADMIN_SCHED, /* The admin sched, only used in dump */ | 1173 | TCA_TAPRIO_ATTR_ADMIN_SCHED, /* The admin sched, only used in dump */ |
| 1170 | TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME, /* s64 */ | 1174 | TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME, /* s64 */ |
| 1171 | TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME_EXTENSION, /* s64 */ | 1175 | TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME_EXTENSION, /* s64 */ |
| 1176 | TCA_TAPRIO_ATTR_FLAGS, /* u32 */ | ||
| 1177 | TCA_TAPRIO_ATTR_TXTIME_DELAY, /* u32 */ | ||
| 1172 | __TCA_TAPRIO_ATTR_MAX, | 1178 | __TCA_TAPRIO_ATTR_MAX, |
| 1173 | }; | 1179 | }; |
| 1174 | 1180 | ||
| @@ -1,3 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0-only WITH Linux-syscall-note */ | ||
| 1 | /* | 2 | /* |
| 2 | * Userspace interface for AMD Secure Encrypted Virtualization (SEV) | 3 | * Userspace interface for AMD Secure Encrypted Virtualization (SEV) |
| 3 | * platform management commands. | 4 | * platform management commands. |
| @@ -7,10 +8,6 @@ · 3 unmodified lines | |||
| 7 | * Author: Brijesh Singh <brijesh.singh@amd.com> | 8 | * Author: Brijesh Singh <brijesh.singh@amd.com> |
| 8 | * | 9 | * |
| 9 | * SEV API specification is available at: https://developer.amd.com/sev/ | 10 | * SEV API specification is available at: https://developer.amd.com/sev/ |
| 10 | * | ||
| 11 | * This program is free software; you can redistribute it and/or modify | ||
| 12 | * it under the terms of the GNU General Public License version 2 as | ||
| 13 | * published by the Free Software Foundation. | ||
| 14 | */ | 11 | */ |
| 15 | 12 | ||
| 16 | #ifndef __PSP_SEV_USER_H__ | 13 | #ifndef __PSP_SEV_USER_H__ |
| @@ -73,6 +73,41 @@ struct seccomp_metadata { · 72 unmodified lines | |||
| 73 | __u64 flags; /* Output: filter's flags */ | 73 | __u64 flags; /* Output: filter's flags */ |
| 74 | }; | 74 | }; |
| 75 | 75 | ||
| 76 | #define PTRACE_GET_SYSCALL_INFO 0x420e | ||
| 77 | #define PTRACE_SYSCALL_INFO_NONE 0 | ||
| 78 | #define PTRACE_SYSCALL_INFO_ENTRY 1 | ||
| 79 | #define PTRACE_SYSCALL_INFO_EXIT 2 | ||
| 80 | #define PTRACE_SYSCALL_INFO_SECCOMP 3 | ||
| 81 | |||
| 82 | struct ptrace_syscall_info { | ||
| 83 | __u8 op; /* PTRACE_SYSCALL_INFO_* */ | ||
| 84 | __u32 arch __attribute__((__aligned__(sizeof(__u32)))); | ||
| 85 | __u64 instruction_pointer; | ||
| 86 | __u64 stack_pointer; | ||
| 87 | union { | ||
| 88 | struct { | ||
| 89 | __u64 nr; | ||
| 90 | __u64 args[6]; | ||
| 91 | } entry; | ||
| 92 | struct { | ||
| 93 | __s64 rval; | ||
| 94 | __u8 is_error; | ||
| 95 | } exit; | ||
| 96 | struct { | ||
| 97 | __u64 nr; | ||
| 98 | __u64 args[6]; | ||
| 99 | __u32 ret_data; | ||
| 100 | } seccomp; | ||
| 101 | }; | ||
| 102 | }; | ||
| 103 | |||
| 104 | /* | ||
| 105 | * These values are stored in task->ptrace_message | ||
| 106 | * by tracehook_report_syscall_* to describe the current syscall-stop. | ||
| 107 | */ | ||
| 108 | #define PTRACE_EVENTMSG_SYSCALL_ENTRY 1 | ||
| 109 | #define PTRACE_EVENTMSG_SYSCALL_EXIT 2 | ||
| 110 | |||
| 76 | /* Read signals from a shared (process wide) queue */ | 111 | /* Read signals from a shared (process wide) queue */ |
| 77 | #define PTRACE_PEEKSIGINFO_SHARED (1 << 0) | 112 | #define PTRACE_PEEKSIGINFO_SHARED (1 << 0) |
| 78 | 113 | ||
| @@ -250,6 +250,7 @@ struct rds_info_rdma_connection { · 249 unmodified lines | |||
| 250 | __u32 rdma_mr_max; | 250 | __u32 rdma_mr_max; |
| 251 | __u32 rdma_mr_size; | 251 | __u32 rdma_mr_size; |
| 252 | __u8 tos; | 252 | __u8 tos; |
| 253 | __u32 cache_allocs; | ||
| 253 | }; | 254 | }; |
| 254 | 255 | ||
| 255 | struct rds6_info_rdma_connection { | 256 | struct rds6_info_rdma_connection { |
| @@ -264,6 +265,7 @@ struct rds6_info_rdma_connection { · 8 unmodified lines | |||
| 264 | __u32 rdma_mr_max; | 265 | __u32 rdma_mr_max; |
| 265 | __u32 rdma_mr_size; | 266 | __u32 rdma_mr_size; |
| 266 | __u8 tos; | 267 | __u8 tos; |
| 268 | __u32 cache_allocs; | ||
| 267 | }; | 269 | }; |
| 268 | 270 | ||
| 269 | /* RDS message Receive Path Latency points */ | 271 | /* RDS message Receive Path Latency points */ |
| @@ -157,6 +157,13 @@ enum { · 156 unmodified lines | |||
| 157 | RTM_GETCHAIN, | 157 | RTM_GETCHAIN, |
| 158 | #define RTM_GETCHAIN RTM_GETCHAIN | 158 | #define RTM_GETCHAIN RTM_GETCHAIN |
| 159 | 159 | ||
| 160 | RTM_NEWNEXTHOP = 104, | ||
| 161 | #define RTM_NEWNEXTHOP RTM_NEWNEXTHOP | ||
| 162 | RTM_DELNEXTHOP, | ||
| 163 | #define RTM_DELNEXTHOP RTM_DELNEXTHOP | ||
| 164 | RTM_GETNEXTHOP, | ||
| 165 | #define RTM_GETNEXTHOP RTM_GETNEXTHOP | ||
| 166 | |||
| 160 | __RTM_MAX, | 167 | __RTM_MAX, |
| 161 | #define RTM_MAX (((__RTM_MAX + 3) & ~3) - 1) | 168 | #define RTM_MAX (((__RTM_MAX + 3) & ~3) - 1) |
| 162 | }; | 169 | }; |
| @@ -342,6 +349,7 @@ enum rtattr_type_t { · 179 unmodified lines | |||
| 342 | RTA_IP_PROTO, | 349 | RTA_IP_PROTO, |
| 343 | RTA_SPORT, | 350 | RTA_SPORT, |
| 344 | RTA_DPORT, | 351 | RTA_DPORT, |
| 352 | RTA_NH_ID, | ||
| 345 | __RTA_MAX | 353 | __RTA_MAX |
| 346 | }; | 354 | }; |
| 347 | 355 | ||
| @@ -704,6 +712,8 @@ enum rtnetlink_groups { · 356 unmodified lines | |||
| 704 | #define RTNLGRP_IPV4_MROUTE_R RTNLGRP_IPV4_MROUTE_R | 712 | #define RTNLGRP_IPV4_MROUTE_R RTNLGRP_IPV4_MROUTE_R |
| 705 | RTNLGRP_IPV6_MROUTE_R, | 713 | RTNLGRP_IPV6_MROUTE_R, |
| 706 | #define RTNLGRP_IPV6_MROUTE_R RTNLGRP_IPV6_MROUTE_R | 714 | #define RTNLGRP_IPV6_MROUTE_R RTNLGRP_IPV6_MROUTE_R |
| 715 | RTNLGRP_NEXTHOP, | ||
| 716 | #define RTNLGRP_NEXTHOP RTNLGRP_NEXTHOP | ||
| 707 | __RTNLGRP_MAX | 717 | __RTNLGRP_MAX |
| 708 | }; | 718 | }; |
| 709 | #define RTNLGRP_MAX (__RTNLGRP_MAX - 1) | 719 | #define RTNLGRP_MAX (__RTNLGRP_MAX - 1) |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0-or-later */ | 1 | /* SPDX-License-Identifier: GPL-2.0-or-later WITH Linux-syscall-note */ |
| 2 | /* Types and definitions for AF_RXRPC. | 2 | /* Types and definitions for AF_RXRPC. |
| 3 | * | 3 | * |
| 4 | * Copyright (C) 2007 Red Hat, Inc. All Rights Reserved. | 4 | * Copyright (C) 2007 Red Hat, Inc. All Rights Reserved. |
| @@ -2,6 +2,8 @@ · 1 unmodified line | |||
| 2 | #ifndef _UAPI_LINUX_SCHED_H | 2 | #ifndef _UAPI_LINUX_SCHED_H |
| 3 | #define _UAPI_LINUX_SCHED_H | 3 | #define _UAPI_LINUX_SCHED_H |
| 4 | 4 | ||
| 5 | #include <linux/types.h> | ||
| 6 | |||
| 5 | /* | 7 | /* |
| 6 | * cloning flags: | 8 | * cloning flags: |
| 7 | */ | 9 | */ |
| @@ -31,6 +33,20 @@ · 23 unmodified lines | |||
| 31 | #define CLONE_NEWNET 0x40000000 /* New network namespace */ | 33 | #define CLONE_NEWNET 0x40000000 /* New network namespace */ |
| 32 | #define CLONE_IO 0x80000000 /* Clone io context */ | 34 | #define CLONE_IO 0x80000000 /* Clone io context */ |
| 33 | 35 | ||
| 36 | /* | ||
| 37 | * Arguments for the clone3 syscall | ||
| 38 | */ | ||
| 39 | struct clone_args { | ||
| 40 | __aligned_u64 flags; | ||
| 41 | __aligned_u64 pidfd; | ||
| 42 | __aligned_u64 child_tid; | ||
| 43 | __aligned_u64 parent_tid; | ||
| 44 | __aligned_u64 exit_signal; | ||
| 45 | __aligned_u64 stack; | ||
| 46 | __aligned_u64 stack_size; | ||
| 47 | __aligned_u64 tls; | ||
| 48 | }; | ||
| 49 | |||
| 34 | /* | 50 | /* |
| 35 | * Scheduling policies | 51 | * Scheduling policies |
| 36 | */ | 52 | */ |
| @@ -51,9 +67,21 @@ · 14 unmodified lines | |||
| 51 | #define SCHED_FLAG_RESET_ON_FORK 0x01 | 67 | #define SCHED_FLAG_RESET_ON_FORK 0x01 |
| 52 | #define SCHED_FLAG_RECLAIM 0x02 | 68 | #define SCHED_FLAG_RECLAIM 0x02 |
| 53 | #define SCHED_FLAG_DL_OVERRUN 0x04 | 69 | #define SCHED_FLAG_DL_OVERRUN 0x04 |
| 70 | #define SCHED_FLAG_KEEP_POLICY 0x08 | ||
| 71 | #define SCHED_FLAG_KEEP_PARAMS 0x10 | ||
| 72 | #define SCHED_FLAG_UTIL_CLAMP_MIN 0x20 | ||
| 73 | #define SCHED_FLAG_UTIL_CLAMP_MAX 0x40 | ||
| 74 | |||
| 75 | #define SCHED_FLAG_KEEP_ALL (SCHED_FLAG_KEEP_POLICY | \ | ||
| 76 | SCHED_FLAG_KEEP_PARAMS) | ||
| 77 | |||
| 78 | #define SCHED_FLAG_UTIL_CLAMP (SCHED_FLAG_UTIL_CLAMP_MIN | \ | ||
| 79 | SCHED_FLAG_UTIL_CLAMP_MAX) | ||
| 54 | 80 | ||
| 55 | #define SCHED_FLAG_ALL (SCHED_FLAG_RESET_ON_FORK | \ | 81 | #define SCHED_FLAG_ALL (SCHED_FLAG_RESET_ON_FORK | \ |
| 56 | SCHED_FLAG_RECLAIM | \ | 82 | SCHED_FLAG_RECLAIM | \ |
| 57 | SCHED_FLAG_DL_OVERRUN) | 83 | SCHED_FLAG_DL_OVERRUN | \ |
| 84 | SCHED_FLAG_KEEP_ALL | \ | ||
| 85 | SCHED_FLAG_UTIL_CLAMP) | ||
| 58 | 86 | ||
| 59 | #endif /* _UAPI_LINUX_SCHED_H */ | 87 | #endif /* _UAPI_LINUX_SCHED_H */ |
| @@ -9,6 +9,7 @@ struct sched_param { · 8 unmodified lines | |||
| 9 | }; | 9 | }; |
| 10 | 10 | ||
| 11 | #define SCHED_ATTR_SIZE_VER0 48 /* sizeof first published struct */ | 11 | #define SCHED_ATTR_SIZE_VER0 48 /* sizeof first published struct */ |
| 12 | #define SCHED_ATTR_SIZE_VER1 56 /* add: util_{min,max} */ | ||
| 12 | 13 | ||
| 13 | /* | 14 | /* |
| 14 | * Extended scheduling parameters data structure. | 15 | * Extended scheduling parameters data structure. |
| @@ -21,8 +22,33 @@ struct sched_param { · 6 unmodified lines | |||
| 21 | * the tasks may be useful for a wide variety of application fields, e.g., | 22 | * the tasks may be useful for a wide variety of application fields, e.g., |
| 22 | * multimedia, streaming, automation and control, and many others. | 23 | * multimedia, streaming, automation and control, and many others. |
| 23 | * | 24 | * |
| 24 | * This variant (sched_attr) is meant at describing a so-called | 25 | * This variant (sched_attr) allows to define additional attributes to |
| 25 | * sporadic time-constrained task. In such model a task is specified by: | 26 | * improve the scheduler knowledge about task requirements. |
| 27 | * | ||
| 28 | * Scheduling Class Attributes | ||
| 29 | * =========================== | ||
| 30 | * | ||
| 31 | * A subset of sched_attr attributes specifies the | ||
| 32 | * scheduling policy and relative POSIX attributes: | ||
| 33 | * | ||
| 34 | * @size size of the structure, for fwd/bwd compat. | ||
| 35 | * | ||
| 36 | * @sched_policy task's scheduling policy | ||
| 37 | * @sched_nice task's nice value (SCHED_NORMAL/BATCH) | ||
| 38 | * @sched_priority task's static priority (SCHED_FIFO/RR) | ||
| 39 | * | ||
| 40 | * Certain more advanced scheduling features can be controlled by a | ||
| 41 | * predefined set of flags via the attribute: | ||
| 42 | * | ||
| 43 | * @sched_flags for customizing the scheduler behaviour | ||
| 44 | * | ||
| 45 | * Sporadic Time-Constrained Task Attributes | ||
| 46 | * ========================================= | ||
| 47 | * | ||
| 48 | * A subset of sched_attr attributes allows to describe a so-called | ||
| 49 | * sporadic time-constrained task. | ||
| 50 | * | ||
| 51 | * In such a model a task is specified by: | ||
| 26 | * - the activation period or minimum instance inter-arrival time; | 52 | * - the activation period or minimum instance inter-arrival time; |
| 27 | * - the maximum (or average, depending on the actual scheduling | 53 | * - the maximum (or average, depending on the actual scheduling |
| 28 | * discipline) computation time of all instances, a.k.a. runtime; | 54 | * discipline) computation time of all instances, a.k.a. runtime; |
| @@ -34,14 +60,8 @@ struct sched_param { · 5 unmodified lines | |||
| 34 | * than the runtime and must be completed by time instant t equal to | 60 | * than the runtime and must be completed by time instant t equal to |
| 35 | * the instance activation time + the deadline. | 61 | * the instance activation time + the deadline. |
| 36 | * | 62 | * |
| 37 | * This is reflected by the actual fields of the sched_attr structure: | 63 | * This is reflected by the following fields of the sched_attr structure: |
| 38 | * | 64 | * |
| 39 | * @size size of the structure, for fwd/bwd compat. | ||
| 40 | * | ||
| 41 | * @sched_policy task's scheduling policy | ||
| 42 | * @sched_flags for customizing the scheduler behaviour | ||
| 43 | * @sched_nice task's nice value (SCHED_NORMAL/BATCH) | ||
| 44 | * @sched_priority task's static priority (SCHED_FIFO/RR) | ||
| 45 | * @sched_deadline representative of the task's deadline | 65 | * @sched_deadline representative of the task's deadline |
| 46 | * @sched_runtime representative of the task's runtime | 66 | * @sched_runtime representative of the task's runtime |
| 47 | * @sched_period representative of the task's period | 67 | * @sched_period representative of the task's period |
| @@ -53,6 +73,29 @@ struct sched_param { · 5 unmodified lines | |||
| 53 | * As of now, the SCHED_DEADLINE policy (sched_dl scheduling class) is the | 73 | * As of now, the SCHED_DEADLINE policy (sched_dl scheduling class) is the |
| 54 | * only user of this new interface. More information about the algorithm | 74 | * only user of this new interface. More information about the algorithm |
| 55 | * available in the scheduling class file or in Documentation/. | 75 | * available in the scheduling class file or in Documentation/. |
| 76 | * | ||
| 77 | * Task Utilization Attributes | ||
| 78 | * =========================== | ||
| 79 | * | ||
| 80 | * A subset of sched_attr attributes allows to specify the utilization | ||
| 81 | * expected for a task. These attributes allow to inform the scheduler about | ||
| 82 | * the utilization boundaries within which it should schedule the task. These | ||
| 83 | * boundaries are valuable hints to support scheduler decisions on both task | ||
| 84 | * placement and frequency selection. | ||
| 85 | * | ||
| 86 | * @sched_util_min represents the minimum utilization | ||
| 87 | * @sched_util_max represents the maximum utilization | ||
| 88 | * | ||
| 89 | * Utilization is a value in the range [0..SCHED_CAPACITY_SCALE]. It | ||
| 90 | * represents the percentage of CPU time used by a task when running at the | ||
| 91 | * maximum frequency on the highest capacity CPU of the system. For example, a | ||
| 92 | * 20% utilization task is a task running for 2ms every 10ms at maximum | ||
| 93 | * frequency. | ||
| 94 | * | ||
| 95 | * A task with a min utilization value bigger than 0 is more likely scheduled | ||
| 96 | * on a CPU with a capacity big enough to fit the specified value. | ||
| 97 | * A task with a max utilization value smaller than 1024 is more likely | ||
| 98 | * scheduled on a CPU with no more capacity than the specified value. | ||
| 56 | */ | 99 | */ |
| 57 | struct sched_attr { | 100 | struct sched_attr { |
| 58 | __u32 size; | 101 | __u32 size; |
| @@ -70,6 +113,11 @@ struct sched_attr { · 11 unmodified lines | |||
| 70 | __u64 sched_runtime; | 113 | __u64 sched_runtime; |
| 71 | __u64 sched_deadline; | 114 | __u64 sched_deadline; |
| 72 | __u64 sched_period; | 115 | __u64 sched_period; |
| 116 | |||
| 117 | /* Utilization hints */ | ||
| 118 | __u32 sched_util_min; | ||
| 119 | __u32 sched_util_max; | ||
| 120 | |||
| 73 | }; | 121 | }; |
| 74 | 122 | ||
| 75 | #endif /* _UAPI_LINUX_SCHED_TYPES_H */ | 123 | #endif /* _UAPI_LINUX_SCHED_TYPES_H */ |
| @@ -20,6 +20,11 @@ enum opal_mbr { · 19 unmodified lines | |||
| 20 | OPAL_MBR_DISABLE = 0x01, | 20 | OPAL_MBR_DISABLE = 0x01, |
| 21 | }; | 21 | }; |
| 22 | 22 | ||
| 23 | enum opal_mbr_done_flag { | ||
| 24 | OPAL_MBR_NOT_DONE = 0x0, | ||
| 25 | OPAL_MBR_DONE = 0x01 | ||
| 26 | }; | ||
| 27 | |||
| 23 | enum opal_user { | 28 | enum opal_user { |
| 24 | OPAL_ADMIN1 = 0x0, | 29 | OPAL_ADMIN1 = 0x0, |
| 25 | OPAL_USER1 = 0x01, | 30 | OPAL_USER1 = 0x01, |
| @@ -95,6 +100,19 @@ struct opal_mbr_data { · 69 unmodified lines | |||
| 95 | __u8 __align[7]; | 100 | __u8 __align[7]; |
| 96 | }; | 101 | }; |
| 97 | 102 | ||
| 103 | struct opal_mbr_done { | ||
| 104 | struct opal_key key; | ||
| 105 | __u8 done_flag; | ||
| 106 | __u8 __align[7]; | ||
| 107 | }; | ||
| 108 | |||
| 109 | struct opal_shadow_mbr { | ||
| 110 | struct opal_key key; | ||
| 111 | const __u64 data; | ||
| 112 | __u64 offset; | ||
| 113 | __u64 size; | ||
| 114 | }; | ||
| 115 | |||
| 98 | #define IOC_OPAL_SAVE _IOW('p', 220, struct opal_lock_unlock) | 116 | #define IOC_OPAL_SAVE _IOW('p', 220, struct opal_lock_unlock) |
| 99 | #define IOC_OPAL_LOCK_UNLOCK _IOW('p', 221, struct opal_lock_unlock) | 117 | #define IOC_OPAL_LOCK_UNLOCK _IOW('p', 221, struct opal_lock_unlock) |
| 100 | #define IOC_OPAL_TAKE_OWNERSHIP _IOW('p', 222, struct opal_key) | 118 | #define IOC_OPAL_TAKE_OWNERSHIP _IOW('p', 222, struct opal_key) |
| @@ -107,5 +125,8 @@ struct opal_mbr_data { · 6 unmodified lines | |||
| 107 | #define IOC_OPAL_ENABLE_DISABLE_MBR _IOW('p', 229, struct opal_mbr_data) | 125 | #define IOC_OPAL_ENABLE_DISABLE_MBR _IOW('p', 229, struct opal_mbr_data) |
| 108 | #define IOC_OPAL_ERASE_LR _IOW('p', 230, struct opal_session_info) | 126 | #define IOC_OPAL_ERASE_LR _IOW('p', 230, struct opal_session_info) |
| 109 | #define IOC_OPAL_SECURE_ERASE_LR _IOW('p', 231, struct opal_session_info) | 127 | #define IOC_OPAL_SECURE_ERASE_LR _IOW('p', 231, struct opal_session_info) |
| 128 | #define IOC_OPAL_PSID_REVERT_TPR _IOW('p', 232, struct opal_key) | ||
| 129 | #define IOC_OPAL_MBR_DONE _IOW('p', 233, struct opal_mbr_done) | ||
| 130 | #define IOC_OPAL_WRITE_SHADOW_MBR _IOW('p', 234, struct opal_shadow_mbr) | ||
| 110 | 131 | ||
| 111 | #endif /* _UAPI_SED_OPAL_H */ | 132 | #endif /* _UAPI_SED_OPAL_H */ |
| @@ -129,7 +129,7 @@ · 128 unmodified lines | |||
| 129 | /* Motorola i.MX SoC */ | 129 | /* Motorola i.MX SoC */ |
| 130 | #define PORT_IMX 62 | 130 | #define PORT_IMX 62 |
| 131 | 131 | ||
| 132 | /* Marvell MPSC */ | 132 | /* Marvell MPSC (obsolete unused) */ |
| 133 | #define PORT_MPSC 63 | 133 | #define PORT_MPSC 63 |
| 134 | 134 | ||
| 135 | /* TXX9 type number */ | 135 | /* TXX9 type number */ |
| @@ -150,9 +150,6 @@ · 14 unmodified lines | |||
| 150 | 150 | ||
| 151 | #define PORT_PNX8XXX 70 | 151 | #define PORT_PNX8XXX 70 |
| 152 | 152 | ||
| 153 | /* Hilscher netx */ | ||
| 154 | #define PORT_NETX 71 | ||
| 155 | |||
| 156 | /* SUN4V Hypervisor Console */ | 153 | /* SUN4V Hypervisor Console */ |
| 157 | #define PORT_SUNHV 72 | 154 | #define PORT_SUNHV 72 |
| 158 | 155 | ||
| @@ -283,6 +283,8 @@ enum · 282 unmodified lines | |||
| 283 | LINUX_MIB_TCPACKCOMPRESSED, /* TCPAckCompressed */ | 283 | LINUX_MIB_TCPACKCOMPRESSED, /* TCPAckCompressed */ |
| 284 | LINUX_MIB_TCPZEROWINDOWDROP, /* TCPZeroWindowDrop */ | 284 | LINUX_MIB_TCPZEROWINDOWDROP, /* TCPZeroWindowDrop */ |
| 285 | LINUX_MIB_TCPRCVQDROP, /* TCPRcvQDrop */ | 285 | LINUX_MIB_TCPRCVQDROP, /* TCPRcvQDrop */ |
| 286 | LINUX_MIB_TCPWQUEUETOOBIG, /* TCPWqueueTooBig */ | ||
| 287 | LINUX_MIB_TCPFASTOPENPASSIVEALTKEY, /* TCPFastOpenPassiveAltKey */ | ||
| 286 | __LINUX_MIB_MAX | 288 | __LINUX_MIB_MAX |
| 287 | }; | 289 | }; |
| 288 | 290 | ||
| @@ -0,0 +1,41 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | #ifndef __UAPI_TC_CT_H | ||
| 3 | #define __UAPI_TC_CT_H | ||
| 4 | |||
| 5 | #include <linux/types.h> | ||
| 6 | #include <linux/pkt_cls.h> | ||
| 7 | |||
| 8 | enum { | ||
| 9 | TCA_CT_UNSPEC, | ||
| 10 | TCA_CT_PARMS, | ||
| 11 | TCA_CT_TM, | ||
| 12 | TCA_CT_ACTION, /* u16 */ | ||
| 13 | TCA_CT_ZONE, /* u16 */ | ||
| 14 | TCA_CT_MARK, /* u32 */ | ||
| 15 | TCA_CT_MARK_MASK, /* u32 */ | ||
| 16 | TCA_CT_LABELS, /* u128 */ | ||
| 17 | TCA_CT_LABELS_MASK, /* u128 */ | ||
| 18 | TCA_CT_NAT_IPV4_MIN, /* be32 */ | ||
| 19 | TCA_CT_NAT_IPV4_MAX, /* be32 */ | ||
| 20 | TCA_CT_NAT_IPV6_MIN, /* struct in6_addr */ | ||
| 21 | TCA_CT_NAT_IPV6_MAX, /* struct in6_addr */ | ||
| 22 | TCA_CT_NAT_PORT_MIN, /* be16 */ | ||
| 23 | TCA_CT_NAT_PORT_MAX, /* be16 */ | ||
| 24 | TCA_CT_PAD, | ||
| 25 | __TCA_CT_MAX | ||
| 26 | }; | ||
| 27 | |||
| 28 | #define TCA_CT_MAX (__TCA_CT_MAX - 1) | ||
| 29 | |||
| 30 | #define TCA_CT_ACT_COMMIT (1 << 0) | ||
| 31 | #define TCA_CT_ACT_FORCE (1 << 1) | ||
| 32 | #define TCA_CT_ACT_CLEAR (1 << 2) | ||
| 33 | #define TCA_CT_ACT_NAT (1 << 3) | ||
| 34 | #define TCA_CT_ACT_NAT_SRC (1 << 4) | ||
| 35 | #define TCA_CT_ACT_NAT_DST (1 << 5) | ||
| 36 | |||
| 37 | struct tc_ct { | ||
| 38 | tc_gen; | ||
| 39 | }; | ||
| 40 | |||
| 41 | #endif /* __UAPI_TC_CT_H */ | ||
| @@ -0,0 +1,29 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | #ifndef __UAPI_TC_CTINFO_H | ||
| 3 | #define __UAPI_TC_CTINFO_H | ||
| 4 | |||
| 5 | #include <linux/types.h> | ||
| 6 | #include <linux/pkt_cls.h> | ||
| 7 | |||
| 8 | struct tc_ctinfo { | ||
| 9 | tc_gen; | ||
| 10 | }; | ||
| 11 | |||
| 12 | enum { | ||
| 13 | TCA_CTINFO_UNSPEC, | ||
| 14 | TCA_CTINFO_PAD, | ||
| 15 | TCA_CTINFO_TM, | ||
| 16 | TCA_CTINFO_ACT, | ||
| 17 | TCA_CTINFO_ZONE, | ||
| 18 | TCA_CTINFO_PARMS_DSCP_MASK, | ||
| 19 | TCA_CTINFO_PARMS_DSCP_STATEMASK, | ||
| 20 | TCA_CTINFO_PARMS_CPMARK_MASK, | ||
| 21 | TCA_CTINFO_STATS_DSCP_SET, | ||
| 22 | TCA_CTINFO_STATS_DSCP_ERROR, | ||
| 23 | TCA_CTINFO_STATS_CPMARK_SET, | ||
| 24 | __TCA_CTINFO_MAX | ||
| 25 | }; | ||
| 26 | |||
| 27 | #define TCA_CTINFO_MAX (__TCA_CTINFO_MAX - 1) | ||
| 28 | |||
| 29 | #endif | ||
| @@ -0,0 +1,33 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* Copyright (C) 2019 Netronome Systems, Inc. */ | ||
| 3 | |||
| 4 | #ifndef __LINUX_TC_MPLS_H | ||
| 5 | #define __LINUX_TC_MPLS_H | ||
| 6 | |||
| 7 | #include <linux/pkt_cls.h> | ||
| 8 | |||
| 9 | #define TCA_MPLS_ACT_POP 1 | ||
| 10 | #define TCA_MPLS_ACT_PUSH 2 | ||
| 11 | #define TCA_MPLS_ACT_MODIFY 3 | ||
| 12 | #define TCA_MPLS_ACT_DEC_TTL 4 | ||
| 13 | |||
| 14 | struct tc_mpls { | ||
| 15 | tc_gen; /* generic TC action fields. */ | ||
| 16 | int m_action; /* action of type TCA_MPLS_ACT_*. */ | ||
| 17 | }; | ||
| 18 | |||
| 19 | enum { | ||
| 20 | TCA_MPLS_UNSPEC, | ||
| 21 | TCA_MPLS_TM, /* struct tcf_t; time values associated with action. */ | ||
| 22 | TCA_MPLS_PARMS, /* struct tc_mpls; action type and general TC fields. */ | ||
| 23 | TCA_MPLS_PAD, | ||
| 24 | TCA_MPLS_PROTO, /* be16; eth_type of pushed or next (for pop) header. */ | ||
| 25 | TCA_MPLS_LABEL, /* u32; MPLS label. Lower 20 bits are used. */ | ||
| 26 | TCA_MPLS_TC, /* u8; MPLS TC field. Lower 3 bits are used. */ | ||
| 27 | TCA_MPLS_TTL, /* u8; MPLS TTL field. Must not be 0. */ | ||
| 28 | TCA_MPLS_BOS, /* u8; MPLS BOS field. Either 1 or 0. */ | ||
| 29 | __TCA_MPLS_MAX, | ||
| 30 | }; | ||
| 31 | #define TCA_MPLS_MAX (__TCA_MPLS_MAX - 1) | ||
| 32 | |||
| 33 | #endif | ||
| @@ -127,6 +127,9 @@ enum { · 126 unmodified lines | |||
| 127 | 127 | ||
| 128 | #define TCP_CM_INQ TCP_INQ | 128 | #define TCP_CM_INQ TCP_INQ |
| 129 | 129 | ||
| 130 | #define TCP_TX_DELAY 37 /* delay outgoing packets by XX usec */ | ||
| 131 | |||
| 132 | |||
| 130 | #define TCP_REPAIR_ON 1 | 133 | #define TCP_REPAIR_ON 1 |
| 131 | #define TCP_REPAIR_OFF 0 | 134 | #define TCP_REPAIR_OFF 0 |
| 132 | #define TCP_REPAIR_OFF_NO_WP -1 /* Turn off without window probes */ | 135 | #define TCP_REPAIR_OFF_NO_WP -1 /* Turn off without window probes */ |
| @@ -20,6 +20,7 @@ struct unix_diag_req { · 19 unmodified lines | |||
| 20 | #define UDIAG_SHOW_ICONS 0x00000008 /* show pending connections */ | 20 | #define UDIAG_SHOW_ICONS 0x00000008 /* show pending connections */ |
| 21 | #define UDIAG_SHOW_RQLEN 0x00000010 /* show skb receive queue len */ | 21 | #define UDIAG_SHOW_RQLEN 0x00000010 /* show skb receive queue len */ |
| 22 | #define UDIAG_SHOW_MEMINFO 0x00000020 /* show memory info of a socket */ | 22 | #define UDIAG_SHOW_MEMINFO 0x00000020 /* show memory info of a socket */ |
| 23 | #define UDIAG_SHOW_UID 0x00000040 /* show socket's UID */ | ||
| 23 | 24 | ||
| 24 | struct unix_diag_msg { | 25 | struct unix_diag_msg { |
| 25 | __u8 udiag_family; | 26 | __u8 udiag_family; |
| @@ -40,6 +41,7 @@ enum { · 14 unmodified lines | |||
| 40 | UNIX_DIAG_RQLEN, | 41 | UNIX_DIAG_RQLEN, |
| 41 | UNIX_DIAG_MEMINFO, | 42 | UNIX_DIAG_MEMINFO, |
| 42 | UNIX_DIAG_SHUTDOWN, | 43 | UNIX_DIAG_SHUTDOWN, |
| 44 | UNIX_DIAG_UID, | ||
| 43 | 45 | ||
| 44 | __UNIX_DIAG_MAX, | 46 | __UNIX_DIAG_MAX, |
| 45 | }; | 47 | }; |
| @@ -450,6 +450,43 @@ static inline __u8 *uac_processing_unit_specific(struct uac_processing_unit_desc · 449 unmodified lines | |||
| 450 | } | 450 | } |
| 451 | } | 451 | } |
| 452 | 452 | ||
| 453 | /* | ||
| 454 | * Extension Unit (XU) has almost compatible layout with Processing Unit, but | ||
| 455 | * on UAC2, it has a different bmControls size (bControlSize); it's 1 byte for | ||
| 456 | * XU while 2 bytes for PU. The last iExtension field is a one-byte index as | ||
| 457 | * well as iProcessing field of PU. | ||
| 458 | */ | ||
| 459 | static inline __u8 uac_extension_unit_bControlSize(struct uac_processing_unit_descriptor *desc, | ||
| 460 | int protocol) | ||
| 461 | { | ||
| 462 | switch (protocol) { | ||
| 463 | case UAC_VERSION_1: | ||
| 464 | return desc->baSourceID[desc->bNrInPins + 4]; | ||
| 465 | case UAC_VERSION_2: | ||
| 466 | return 1; /* in UAC2, this value is constant */ | ||
| 467 | case UAC_VERSION_3: | ||
| 468 | return 4; /* in UAC3, this value is constant */ | ||
| 469 | default: | ||
| 470 | return 1; | ||
| 471 | } | ||
| 472 | } | ||
| 473 | |||
| 474 | static inline __u8 uac_extension_unit_iExtension(struct uac_processing_unit_descriptor *desc, | ||
| 475 | int protocol) | ||
| 476 | { | ||
| 477 | __u8 control_size = uac_extension_unit_bControlSize(desc, protocol); | ||
| 478 | |||
| 479 | switch (protocol) { | ||
| 480 | case UAC_VERSION_1: | ||
| 481 | case UAC_VERSION_2: | ||
| 482 | default: | ||
| 483 | return *(uac_processing_unit_bmControls(desc, protocol) | ||
| 484 | + control_size); | ||
| 485 | case UAC_VERSION_3: | ||
| 486 | return 0; /* UAC3 does not have this field */ | ||
| 487 | } | ||
| 488 | } | ||
| 489 | |||
| 453 | /* 4.5.2 Class-Specific AS Interface Descriptor */ | 490 | /* 4.5.2 Class-Specific AS Interface Descriptor */ |
| 454 | struct uac1_as_header_descriptor { | 491 | struct uac1_as_header_descriptor { |
| 455 | __u8 bLength; /* in bytes: 7 */ | 492 | __u8 bLength; /* in bytes: 7 */ |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0+ */ | 1 | /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * g_uvc.h -- USB Video Class Gadget driver API | 3 | * g_uvc.h -- USB Video Class Gadget driver API |
| 4 | * | 4 | * |
| @@ -76,6 +76,26 @@ struct usbdevfs_connectinfo { · 75 unmodified lines | |||
| 76 | unsigned char slow; | 76 | unsigned char slow; |
| 77 | }; | 77 | }; |
| 78 | 78 | ||
| 79 | struct usbdevfs_conninfo_ex { | ||
| 80 | __u32 size; /* Size of the structure from the kernel's */ | ||
| 81 | /* point of view. Can be used by userspace */ | ||
| 82 | /* to determine how much data can be */ | ||
| 83 | /* used/trusted. */ | ||
| 84 | __u32 busnum; /* USB bus number, as enumerated by the */ | ||
| 85 | /* kernel, the device is connected to. */ | ||
| 86 | __u32 devnum; /* Device address on the bus. */ | ||
| 87 | __u32 speed; /* USB_SPEED_* constants from ch9.h */ | ||
| 88 | __u8 num_ports; /* Number of ports the device is connected */ | ||
| 89 | /* to on the way to the root hub. It may */ | ||
| 90 | /* be bigger than size of 'ports' array so */ | ||
| 91 | /* userspace can detect overflows. */ | ||
| 92 | __u8 ports[7]; /* List of ports on the way from the root */ | ||
| 93 | /* hub to the device. Current limit in */ | ||
| 94 | /* USB specification is 7 tiers (root hub, */ | ||
| 95 | /* 5 intermediate hubs, device), which */ | ||
| 96 | /* gives at most 6 port entries. */ | ||
| 97 | }; | ||
| 98 | |||
| 79 | #define USBDEVFS_URB_SHORT_NOT_OK 0x01 | 99 | #define USBDEVFS_URB_SHORT_NOT_OK 0x01 |
| 80 | #define USBDEVFS_URB_ISO_ASAP 0x02 | 100 | #define USBDEVFS_URB_ISO_ASAP 0x02 |
| 81 | #define USBDEVFS_URB_BULK_CONTINUATION 0x04 | 101 | #define USBDEVFS_URB_BULK_CONTINUATION 0x04 |
| @@ -137,6 +157,7 @@ struct usbdevfs_hub_portinfo { · 55 unmodified lines | |||
| 137 | #define USBDEVFS_CAP_REAP_AFTER_DISCONNECT 0x10 | 157 | #define USBDEVFS_CAP_REAP_AFTER_DISCONNECT 0x10 |
| 138 | #define USBDEVFS_CAP_MMAP 0x20 | 158 | #define USBDEVFS_CAP_MMAP 0x20 |
| 139 | #define USBDEVFS_CAP_DROP_PRIVILEGES 0x40 | 159 | #define USBDEVFS_CAP_DROP_PRIVILEGES 0x40 |
| 160 | #define USBDEVFS_CAP_CONNINFO_EX 0x80 | ||
| 140 | 161 | ||
| 141 | /* USBDEVFS_DISCONNECT_CLAIM flags & struct */ | 162 | /* USBDEVFS_DISCONNECT_CLAIM flags & struct */ |
| 142 | 163 | ||
| @@ -197,5 +218,10 @@ struct usbdevfs_streams { · 54 unmodified lines | |||
| 197 | #define USBDEVFS_FREE_STREAMS _IOR('U', 29, struct usbdevfs_streams) | 218 | #define USBDEVFS_FREE_STREAMS _IOR('U', 29, struct usbdevfs_streams) |
| 198 | #define USBDEVFS_DROP_PRIVILEGES _IOW('U', 30, __u32) | 219 | #define USBDEVFS_DROP_PRIVILEGES _IOW('U', 30, __u32) |
| 199 | #define USBDEVFS_GET_SPEED _IO('U', 31) | 220 | #define USBDEVFS_GET_SPEED _IO('U', 31) |
| 221 | /* | ||
| 222 | * Returns struct usbdevfs_conninfo_ex; length is variable to allow | ||
| 223 | * extending size of the data returned. | ||
| 224 | */ | ||
| 225 | #define USBDEVFS_CONNINFO_EX(len) _IOC(_IOC_READ, 'U', 32, len) | ||
| 200 | 226 | ||
| 201 | #endif /* _UAPI_LINUX_USBDEVICE_FS_H */ | 227 | #endif /* _UAPI_LINUX_USBDEVICE_FS_H */ |
| @@ -392,8 +392,13 @@ enum v4l2_mpeg_video_header_mode { · 391 unmodified lines | |||
| 392 | #define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE (V4L2_CID_MPEG_BASE+221) | 392 | #define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE (V4L2_CID_MPEG_BASE+221) |
| 393 | enum v4l2_mpeg_video_multi_slice_mode { | 393 | enum v4l2_mpeg_video_multi_slice_mode { |
| 394 | V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE = 0, | 394 | V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE = 0, |
| 395 | V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB = 1, | ||
| 396 | V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES = 2, | ||
| 397 | #ifndef __KERNEL__ | ||
| 398 | /* Kept for backwards compatibility reasons. Stupid typo... */ | ||
| 395 | V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_MB = 1, | 399 | V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_MB = 1, |
| 396 | V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_BYTES = 2, | 400 | V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_BYTES = 2, |
| 401 | #endif | ||
| 397 | }; | 402 | }; |
| 398 | #define V4L2_CID_MPEG_VIDEO_VBV_SIZE (V4L2_CID_MPEG_BASE+222) | 403 | #define V4L2_CID_MPEG_VIDEO_VBV_SIZE (V4L2_CID_MPEG_BASE+222) |
| 399 | #define V4L2_CID_MPEG_VIDEO_DEC_PTS (V4L2_CID_MPEG_BASE+223) | 404 | #define V4L2_CID_MPEG_VIDEO_DEC_PTS (V4L2_CID_MPEG_BASE+223) |
| @@ -404,6 +409,24 @@ enum v4l2_mpeg_video_multi_slice_mode { · 4 unmodified lines | |||
| 404 | #define V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (V4L2_CID_MPEG_BASE+228) | 409 | #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) | 410 | #define V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (V4L2_CID_MPEG_BASE+229) |
| 406 | 411 | ||
| 412 | /* CIDs for the MPEG-2 Part 2 (H.262) codec */ | ||
| 413 | #define V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL (V4L2_CID_MPEG_BASE+270) | ||
| 414 | enum v4l2_mpeg_video_mpeg2_level { | ||
| 415 | V4L2_MPEG_VIDEO_MPEG2_LEVEL_LOW = 0, | ||
| 416 | V4L2_MPEG_VIDEO_MPEG2_LEVEL_MAIN = 1, | ||
| 417 | V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH_1440 = 2, | ||
| 418 | V4L2_MPEG_VIDEO_MPEG2_LEVEL_HIGH = 3, | ||
| 419 | }; | ||
| 420 | #define V4L2_CID_MPEG_VIDEO_MPEG2_PROFILE (V4L2_CID_MPEG_BASE+271) | ||
| 421 | enum v4l2_mpeg_video_mpeg2_profile { | ||
| 422 | V4L2_MPEG_VIDEO_MPEG2_PROFILE_SIMPLE = 0, | ||
| 423 | V4L2_MPEG_VIDEO_MPEG2_PROFILE_MAIN = 1, | ||
| 424 | V4L2_MPEG_VIDEO_MPEG2_PROFILE_SNR_SCALABLE = 2, | ||
| 425 | V4L2_MPEG_VIDEO_MPEG2_PROFILE_SPATIALLY_SCALABLE = 3, | ||
| 426 | V4L2_MPEG_VIDEO_MPEG2_PROFILE_HIGH = 4, | ||
| 427 | V4L2_MPEG_VIDEO_MPEG2_PROFILE_MULTIVIEW = 5, | ||
| 428 | }; | ||
| 429 | |||
| 407 | /* CIDs for the FWHT codec as used by the vicodec driver. */ | 430 | /* CIDs for the FWHT codec as used by the vicodec driver. */ |
| 408 | #define V4L2_CID_FWHT_I_FRAME_QP (V4L2_CID_MPEG_BASE + 290) | 431 | #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) | 432 | #define V4L2_CID_FWHT_P_FRAME_QP (V4L2_CID_MPEG_BASE + 291) |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: (GPL-2.0 OR CDDL-1.0) */ | 1 | /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR CDDL-1.0) */ |
| 2 | /* | 2 | /* |
| 3 | * Virtual Device for Guest <-> VMM/Host communication, type definitions | 3 | * Virtual Device for Guest <-> VMM/Host communication, type definitions |
| 4 | * which are also used for the vboxguest ioctl interface / by vboxsf | 4 | * which are also used for the vboxguest ioctl interface / by vboxsf |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: (GPL-2.0 OR CDDL-1.0) */ | 1 | /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR CDDL-1.0) */ |
| 2 | /* | 2 | /* |
| 3 | * VBoxGuest - VirtualBox Guest Additions Driver Interface. | 3 | * VBoxGuest - VirtualBox Guest Additions Driver Interface. |
| 4 | * | 4 | * |
| @@ -80,7 +80,7 @@ · 79 unmodified lines | |||
| 80 | /* Four-character-code (FOURCC) */ | 80 | /* Four-character-code (FOURCC) */ |
| 81 | #define v4l2_fourcc(a, b, c, d)\ | 81 | #define v4l2_fourcc(a, b, c, d)\ |
| 82 | ((__u32)(a) | ((__u32)(b) << 8) | ((__u32)(c) << 16) | ((__u32)(d) << 24)) | 82 | ((__u32)(a) | ((__u32)(b) << 8) | ((__u32)(c) << 16) | ((__u32)(d) << 24)) |
| 83 | #define v4l2_fourcc_be(a, b, c, d) (v4l2_fourcc(a, b, c, d) | (1 << 31)) | 83 | #define v4l2_fourcc_be(a, b, c, d) (v4l2_fourcc(a, b, c, d) | (1U << 31)) |
| 84 | 84 | ||
| 85 | /* | 85 | /* |
| 86 | * E N U M S | 86 | * E N U M S |
| @@ -518,7 +518,13 @@ struct v4l2_pix_format { · 431 unmodified lines | |||
| 518 | #define V4L2_PIX_FMT_RGBX444 v4l2_fourcc('R', 'X', '1', '2') /* 16 rrrrgggg bbbbxxxx */ | 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 */ | 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 */ | 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 */ | 521 | |
| 522 | /* | ||
| 523 | * Originally this had 'BA12' as fourcc, but this clashed with the older | ||
| 524 | * V4L2_PIX_FMT_SGRBG12 which inexplicably used that same fourcc. | ||
| 525 | * So use 'GA12' instead for V4L2_PIX_FMT_BGRA444. | ||
| 526 | */ | ||
| 527 | #define V4L2_PIX_FMT_BGRA444 v4l2_fourcc('G', 'A', '1', '2') /* 16 bbbbgggg rrrraaaa */ | ||
| 522 | #define V4L2_PIX_FMT_BGRX444 v4l2_fourcc('B', 'X', '1', '2') /* 16 bbbbgggg rrrrxxxx */ | 528 | #define V4L2_PIX_FMT_BGRX444 v4l2_fourcc('B', 'X', '1', '2') /* 16 bbbbgggg rrrrxxxx */ |
| 523 | #define V4L2_PIX_FMT_RGB555 v4l2_fourcc('R', 'G', 'B', 'O') /* 16 RGB-5-5-5 */ | 529 | #define V4L2_PIX_FMT_RGB555 v4l2_fourcc('R', 'G', 'B', 'O') /* 16 RGB-5-5-5 */ |
| 524 | #define V4L2_PIX_FMT_ARGB555 v4l2_fourcc('A', 'R', '1', '5') /* 16 ARGB-1-5-5-5 */ | 530 | #define V4L2_PIX_FMT_ARGB555 v4l2_fourcc('A', 'R', '1', '5') /* 16 ARGB-1-5-5-5 */ |
| @@ -43,5 +43,7 @@ · 42 unmodified lines | |||
| 43 | #define VIRTIO_ID_INPUT 18 /* virtio input */ | 43 | #define VIRTIO_ID_INPUT 18 /* virtio input */ |
| 44 | #define VIRTIO_ID_VSOCK 19 /* virtio vsock transport */ | 44 | #define VIRTIO_ID_VSOCK 19 /* virtio vsock transport */ |
| 45 | #define VIRTIO_ID_CRYPTO 20 /* virtio crypto */ | 45 | #define VIRTIO_ID_CRYPTO 20 /* virtio crypto */ |
| 46 | #define VIRTIO_ID_IOMMU 23 /* virtio IOMMU */ | ||
| 47 | #define VIRTIO_ID_PMEM 27 /* virtio pmem */ | ||
| 46 | 48 | ||
| 47 | #endif /* _LINUX_VIRTIO_IDS_H */ | 49 | #endif /* _LINUX_VIRTIO_IDS_H */ |
| @@ -0,0 +1,165 @@ | |||
| 1 | /* SPDX-License-Identifier: BSD-3-Clause */ | ||
| 2 | /* | ||
| 3 | * Virtio-iommu definition v0.12 | ||
| 4 | * | ||
| 5 | * Copyright (C) 2019 Arm Ltd. | ||
| 6 | */ | ||
| 7 | #ifndef _UAPI_LINUX_VIRTIO_IOMMU_H | ||
| 8 | #define _UAPI_LINUX_VIRTIO_IOMMU_H | ||
| 9 | |||
| 10 | #include <linux/types.h> | ||
| 11 | |||
| 12 | /* Feature bits */ | ||
| 13 | #define VIRTIO_IOMMU_F_INPUT_RANGE 0 | ||
| 14 | #define VIRTIO_IOMMU_F_DOMAIN_RANGE 1 | ||
| 15 | #define VIRTIO_IOMMU_F_MAP_UNMAP 2 | ||
| 16 | #define VIRTIO_IOMMU_F_BYPASS 3 | ||
| 17 | #define VIRTIO_IOMMU_F_PROBE 4 | ||
| 18 | #define VIRTIO_IOMMU_F_MMIO 5 | ||
| 19 | |||
| 20 | struct virtio_iommu_range_64 { | ||
| 21 | __le64 start; | ||
| 22 | __le64 end; | ||
| 23 | }; | ||
| 24 | |||
| 25 | struct virtio_iommu_range_32 { | ||
| 26 | __le32 start; | ||
| 27 | __le32 end; | ||
| 28 | }; | ||
| 29 | |||
| 30 | struct virtio_iommu_config { | ||
| 31 | /* Supported page sizes */ | ||
| 32 | __le64 page_size_mask; | ||
| 33 | /* Supported IOVA range */ | ||
| 34 | struct virtio_iommu_range_64 input_range; | ||
| 35 | /* Max domain ID size */ | ||
| 36 | struct virtio_iommu_range_32 domain_range; | ||
| 37 | /* Probe buffer size */ | ||
| 38 | __le32 probe_size; | ||
| 39 | }; | ||
| 40 | |||
| 41 | /* Request types */ | ||
| 42 | #define VIRTIO_IOMMU_T_ATTACH 0x01 | ||
| 43 | #define VIRTIO_IOMMU_T_DETACH 0x02 | ||
| 44 | #define VIRTIO_IOMMU_T_MAP 0x03 | ||
| 45 | #define VIRTIO_IOMMU_T_UNMAP 0x04 | ||
| 46 | #define VIRTIO_IOMMU_T_PROBE 0x05 | ||
| 47 | |||
| 48 | /* Status types */ | ||
| 49 | #define VIRTIO_IOMMU_S_OK 0x00 | ||
| 50 | #define VIRTIO_IOMMU_S_IOERR 0x01 | ||
| 51 | #define VIRTIO_IOMMU_S_UNSUPP 0x02 | ||
| 52 | #define VIRTIO_IOMMU_S_DEVERR 0x03 | ||
| 53 | #define VIRTIO_IOMMU_S_INVAL 0x04 | ||
| 54 | #define VIRTIO_IOMMU_S_RANGE 0x05 | ||
| 55 | #define VIRTIO_IOMMU_S_NOENT 0x06 | ||
| 56 | #define VIRTIO_IOMMU_S_FAULT 0x07 | ||
| 57 | #define VIRTIO_IOMMU_S_NOMEM 0x08 | ||
| 58 | |||
| 59 | struct virtio_iommu_req_head { | ||
| 60 | __u8 type; | ||
| 61 | __u8 reserved[3]; | ||
| 62 | }; | ||
| 63 | |||
| 64 | struct virtio_iommu_req_tail { | ||
| 65 | __u8 status; | ||
| 66 | __u8 reserved[3]; | ||
| 67 | }; | ||
| 68 | |||
| 69 | struct virtio_iommu_req_attach { | ||
| 70 | struct virtio_iommu_req_head head; | ||
| 71 | __le32 domain; | ||
| 72 | __le32 endpoint; | ||
| 73 | __u8 reserved[8]; | ||
| 74 | struct virtio_iommu_req_tail tail; | ||
| 75 | }; | ||
| 76 | |||
| 77 | struct virtio_iommu_req_detach { | ||
| 78 | struct virtio_iommu_req_head head; | ||
| 79 | __le32 domain; | ||
| 80 | __le32 endpoint; | ||
| 81 | __u8 reserved[8]; | ||
| 82 | struct virtio_iommu_req_tail tail; | ||
| 83 | }; | ||
| 84 | |||
| 85 | #define VIRTIO_IOMMU_MAP_F_READ (1 << 0) | ||
| 86 | #define VIRTIO_IOMMU_MAP_F_WRITE (1 << 1) | ||
| 87 | #define VIRTIO_IOMMU_MAP_F_MMIO (1 << 2) | ||
| 88 | |||
| 89 | #define VIRTIO_IOMMU_MAP_F_MASK (VIRTIO_IOMMU_MAP_F_READ | \ | ||
| 90 | VIRTIO_IOMMU_MAP_F_WRITE | \ | ||
| 91 | VIRTIO_IOMMU_MAP_F_MMIO) | ||
| 92 | |||
| 93 | struct virtio_iommu_req_map { | ||
| 94 | struct virtio_iommu_req_head head; | ||
| 95 | __le32 domain; | ||
| 96 | __le64 virt_start; | ||
| 97 | __le64 virt_end; | ||
| 98 | __le64 phys_start; | ||
| 99 | __le32 flags; | ||
| 100 | struct virtio_iommu_req_tail tail; | ||
| 101 | }; | ||
| 102 | |||
| 103 | struct virtio_iommu_req_unmap { | ||
| 104 | struct virtio_iommu_req_head head; | ||
| 105 | __le32 domain; | ||
| 106 | __le64 virt_start; | ||
| 107 | __le64 virt_end; | ||
| 108 | __u8 reserved[4]; | ||
| 109 | struct virtio_iommu_req_tail tail; | ||
| 110 | }; | ||
| 111 | |||
| 112 | #define VIRTIO_IOMMU_PROBE_T_NONE 0 | ||
| 113 | #define VIRTIO_IOMMU_PROBE_T_RESV_MEM 1 | ||
| 114 | |||
| 115 | #define VIRTIO_IOMMU_PROBE_T_MASK 0xfff | ||
| 116 | |||
| 117 | struct virtio_iommu_probe_property { | ||
| 118 | __le16 type; | ||
| 119 | __le16 length; | ||
| 120 | }; | ||
| 121 | |||
| 122 | #define VIRTIO_IOMMU_RESV_MEM_T_RESERVED 0 | ||
| 123 | #define VIRTIO_IOMMU_RESV_MEM_T_MSI 1 | ||
| 124 | |||
| 125 | struct virtio_iommu_probe_resv_mem { | ||
| 126 | struct virtio_iommu_probe_property head; | ||
| 127 | __u8 subtype; | ||
| 128 | __u8 reserved[3]; | ||
| 129 | __le64 start; | ||
| 130 | __le64 end; | ||
| 131 | }; | ||
| 132 | |||
| 133 | struct virtio_iommu_req_probe { | ||
| 134 | struct virtio_iommu_req_head head; | ||
| 135 | __le32 endpoint; | ||
| 136 | __u8 reserved[64]; | ||
| 137 | |||
| 138 | __u8 properties[]; | ||
| 139 | |||
| 140 | /* | ||
| 141 | * Tail follows the variable-length properties array. No padding, | ||
| 142 | * property lengths are all aligned on 8 bytes. | ||
| 143 | */ | ||
| 144 | }; | ||
| 145 | |||
| 146 | /* Fault types */ | ||
| 147 | #define VIRTIO_IOMMU_FAULT_R_UNKNOWN 0 | ||
| 148 | #define VIRTIO_IOMMU_FAULT_R_DOMAIN 1 | ||
| 149 | #define VIRTIO_IOMMU_FAULT_R_MAPPING 2 | ||
| 150 | |||
| 151 | #define VIRTIO_IOMMU_FAULT_F_READ (1 << 0) | ||
| 152 | #define VIRTIO_IOMMU_FAULT_F_WRITE (1 << 1) | ||
| 153 | #define VIRTIO_IOMMU_FAULT_F_EXEC (1 << 2) | ||
| 154 | #define VIRTIO_IOMMU_FAULT_F_ADDRESS (1 << 8) | ||
| 155 | |||
| 156 | struct virtio_iommu_fault { | ||
| 157 | __u8 reason; | ||
| 158 | __u8 reserved[3]; | ||
| 159 | __le32 flags; | ||
| 160 | __le32 endpoint; | ||
| 161 | __u8 reserved2[4]; | ||
| 162 | __le64 address; | ||
| 163 | }; | ||
| 164 | |||
| 165 | #endif | ||
| @@ -0,0 +1,34 @@ | |||
| 1 | /* SPDX-License-Identifier: (GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause */ | ||
| 2 | /* | ||
| 3 | * Definitions for virtio-pmem devices. | ||
| 4 | * | ||
| 5 | * Copyright (C) 2019 Red Hat, Inc. | ||
| 6 | * | ||
| 7 | * Author(s): Pankaj Gupta <pagupta@redhat.com> | ||
| 8 | */ | ||
| 9 | |||
| 10 | #ifndef _UAPI_LINUX_VIRTIO_PMEM_H | ||
| 11 | #define _UAPI_LINUX_VIRTIO_PMEM_H | ||
| 12 | |||
| 13 | #include <linux/types.h> | ||
| 14 | #include <linux/virtio_ids.h> | ||
| 15 | #include <linux/virtio_config.h> | ||
| 16 | |||
| 17 | struct virtio_pmem_config { | ||
| 18 | __u64 start; | ||
| 19 | __u64 size; | ||
| 20 | }; | ||
| 21 | |||
| 22 | #define VIRTIO_PMEM_REQ_TYPE_FLUSH 0 | ||
| 23 | |||
| 24 | struct virtio_pmem_resp { | ||
| 25 | /* Host return status corresponding to flush request */ | ||
| 26 | __le32 ret; | ||
| 27 | }; | ||
| 28 | |||
| 29 | struct virtio_pmem_req { | ||
| 30 | /* command type */ | ||
| 31 | __le32 type; | ||
| 32 | }; | ||
| 33 | |||
| 34 | #endif | ||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
| 2 | #ifndef _UAPI_VMCORE_H | 2 | #ifndef _UAPI_VMCORE_H |
| 3 | #define _UAPI_VMCORE_H | 3 | #define _UAPI_VMCORE_H |
| 4 | 4 | ||
| @@ -1,18 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ | ||
| 2 | /* | ||
| 3 | * wanrouter.h Legacy declarations kept around until X25 is removed | ||
| 4 | */ | ||
| 5 | |||
| 6 | #ifndef _UAPI_ROUTER_H | ||
| 7 | #define _UAPI_ROUTER_H | ||
| 8 | |||
| 9 | /* 'state' defines */ | ||
| 10 | enum wan_states | ||
| 11 | { | ||
| 12 | WAN_UNCONFIGURED, /* link/channel is not configured */ | ||
| 13 | WAN_DISCONNECTED, /* link/channel is disconnected */ | ||
| 14 | WAN_CONNECTING, /* connection is in progress */ | ||
| 15 | WAN_CONNECTED /* link/channel is operational */ | ||
| 16 | }; | ||
| 17 | |||
| 18 | #endif /* _UAPI_ROUTER_H */ | ||
| @@ -1,11 +1,8 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0-only WITH Linux-syscall-note */ | ||
| 1 | /* | 2 | /* |
| 2 | * User API methods for ACPI-WMI mapping driver | 3 | * User API methods for ACPI-WMI mapping driver |
| 3 | * | 4 | * |
| 4 | * Copyright (C) 2017 Dell, Inc. | 5 | * Copyright (C) 2017 Dell, Inc. |
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License version 2 as | ||
| 8 | * published by the Free Software Foundation. | ||
| 9 | */ | 6 | */ |
| 10 | #ifndef _UAPI_LINUX_WMI_H | 7 | #ifndef _UAPI_LINUX_WMI_H |
| 11 | #define _UAPI_LINUX_WMI_H | 8 | #define _UAPI_LINUX_WMI_H |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
| 2 | 2 | ||
| 3 | #ifndef __QCOM_FASTRPC_H__ | 3 | #ifndef __QCOM_FASTRPC_H__ |
| 4 | #define __QCOM_FASTRPC_H__ | 4 | #define __QCOM_FASTRPC_H__ |
| @@ -45,6 +45,30 @@ enum goya_queue_id { · 44 unmodified lines | |||
| 45 | GOYA_QUEUE_ID_SIZE | 45 | GOYA_QUEUE_ID_SIZE |
| 46 | }; | 46 | }; |
| 47 | 47 | ||
| 48 | /* | ||
| 49 | * Engine Numbering | ||
| 50 | * | ||
| 51 | * Used in the "busy_engines_mask" field in `struct hl_info_hw_idle' | ||
| 52 | */ | ||
| 53 | |||
| 54 | enum goya_engine_id { | ||
| 55 | GOYA_ENGINE_ID_DMA_0 = 0, | ||
| 56 | GOYA_ENGINE_ID_DMA_1, | ||
| 57 | GOYA_ENGINE_ID_DMA_2, | ||
| 58 | GOYA_ENGINE_ID_DMA_3, | ||
| 59 | GOYA_ENGINE_ID_DMA_4, | ||
| 60 | GOYA_ENGINE_ID_MME_0, | ||
| 61 | GOYA_ENGINE_ID_TPC_0, | ||
| 62 | GOYA_ENGINE_ID_TPC_1, | ||
| 63 | GOYA_ENGINE_ID_TPC_2, | ||
| 64 | GOYA_ENGINE_ID_TPC_3, | ||
| 65 | GOYA_ENGINE_ID_TPC_4, | ||
| 66 | GOYA_ENGINE_ID_TPC_5, | ||
| 67 | GOYA_ENGINE_ID_TPC_6, | ||
| 68 | GOYA_ENGINE_ID_TPC_7, | ||
| 69 | GOYA_ENGINE_ID_SIZE | ||
| 70 | }; | ||
| 71 | |||
| 48 | enum hl_device_status { | 72 | enum hl_device_status { |
| 49 | HL_DEVICE_STATUS_OPERATIONAL, | 73 | HL_DEVICE_STATUS_OPERATIONAL, |
| 50 | HL_DEVICE_STATUS_IN_RESET, | 74 | HL_DEVICE_STATUS_IN_RESET, |
| @@ -86,7 +110,11 @@ struct hl_info_dram_usage { · 35 unmodified lines | |||
| 86 | 110 | ||
| 87 | struct hl_info_hw_idle { | 111 | struct hl_info_hw_idle { |
| 88 | __u32 is_idle; | 112 | __u32 is_idle; |
| 89 | __u32 pad; | 113 | /* |
| 114 | * Bitmask of busy engines. | ||
| 115 | * Bits definition is according to `enum <chip>_enging_id'. | ||
| 116 | */ | ||
| 117 | __u32 busy_engines_mask; | ||
| 90 | }; | 118 | }; |
| 91 | 119 | ||
| 92 | struct hl_info_device_status { | 120 | struct hl_info_device_status { |
| @@ -33,23 +33,23 @@ struct ocxl_ioctl_attach { · 32 unmodified lines | |||
| 33 | }; | 33 | }; |
| 34 | 34 | ||
| 35 | struct ocxl_ioctl_metadata { | 35 | struct ocxl_ioctl_metadata { |
| 36 | __u16 version; // struct version, always backwards compatible | 36 | __u16 version; /* struct version, always backwards compatible */ |
| 37 | 37 | ||
| 38 | // Version 0 fields | 38 | /* Version 0 fields */ |
| 39 | __u8 afu_version_major; | 39 | __u8 afu_version_major; |
| 40 | __u8 afu_version_minor; | 40 | __u8 afu_version_minor; |
| 41 | __u32 pasid; // PASID assigned to the current context | 41 | __u32 pasid; /* PASID assigned to the current context */ |
| 42 | 42 | ||
| 43 | __u64 pp_mmio_size; // Per PASID MMIO size | 43 | __u64 pp_mmio_size; /* Per PASID MMIO size */ |
| 44 | __u64 global_mmio_size; | 44 | __u64 global_mmio_size; |
| 45 | 45 | ||
| 46 | // End version 0 fields | 46 | /* End version 0 fields */ |
| 47 | 47 | ||
| 48 | __u64 reserved[13]; // Total of 16*u64 | 48 | __u64 reserved[13]; /* Total of 16*u64 */ |
| 49 | }; | 49 | }; |
| 50 | 50 | ||
| 51 | struct ocxl_ioctl_p9_wait { | 51 | struct ocxl_ioctl_p9_wait { |
| 52 | __u16 thread_id; // The thread ID required to wake this thread | 52 | __u16 thread_id; /* The thread ID required to wake this thread */ |
| 53 | __u16 reserved1; | 53 | __u16 reserved1; |
| 54 | __u32 reserved2; | 54 | __u32 reserved2; |
| 55 | __u64 reserved3[3]; | 55 | __u64 reserved3[3]; |
| @@ -113,11 +113,11 @@ struct mtd_write_req { · 112 unmodified lines | |||
| 113 | #define MTD_CAP_NVRAM (MTD_WRITEABLE | MTD_BIT_WRITEABLE | MTD_NO_ERASE) | 113 | #define MTD_CAP_NVRAM (MTD_WRITEABLE | MTD_BIT_WRITEABLE | MTD_NO_ERASE) |
| 114 | 114 | ||
| 115 | /* Obsolete ECC byte placement modes (used with obsolete MEMGETOOBSEL) */ | 115 | /* Obsolete ECC byte placement modes (used with obsolete MEMGETOOBSEL) */ |
| 116 | #define MTD_NANDECC_OFF 0 // Switch off ECC (Not recommended) | 116 | #define MTD_NANDECC_OFF 0 /* Switch off ECC (Not recommended) */ |
| 117 | #define MTD_NANDECC_PLACE 1 // Use the given placement in the structure (YAFFS1 legacy mode) | 117 | #define MTD_NANDECC_PLACE 1 /* Use the given placement in the structure (YAFFS1 legacy mode) */ |
| 118 | #define MTD_NANDECC_AUTOPLACE 2 // Use the default placement scheme | 118 | #define MTD_NANDECC_AUTOPLACE 2 /* Use the default placement scheme */ |
| 119 | #define MTD_NANDECC_PLACEONLY 3 // Use the given placement in the structure (Do not store ecc result on read) | 119 | #define MTD_NANDECC_PLACEONLY 3 /* Use the given placement in the structure (Do not store ecc result on read) */ |
| 120 | #define MTD_NANDECC_AUTOPL_USR 4 // Use the given autoplacement scheme rather than using the default | 120 | #define MTD_NANDECC_AUTOPL_USR 4 /* Use the given autoplacement scheme rather than using the default */ |
| 121 | 121 | ||
| 122 | /* OTP mode selection */ | 122 | /* OTP mode selection */ |
| 123 | #define MTD_OTP_OFF 0 | 123 | #define MTD_OTP_OFF 0 |
| @@ -1,326 +0,0 @@ | |||
| 1 | /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR Linux-OpenIB) */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2005 Topspin Communications. All rights reserved. | ||
| 4 | * Copyright (c) 2005 Intel Corporation. All rights reserved. | ||
| 5 | * | ||
| 6 | * This software is available to you under a choice of one of two | ||
| 7 | * licenses. You may choose to be licensed under the terms of the GNU | ||
| 8 | * General Public License (GPL) Version 2, available from the file | ||
| 9 | * COPYING in the main directory of this source tree, or the | ||
| 10 | * OpenIB.org BSD license below: | ||
| 11 | * | ||
| 12 | * Redistribution and use in source and binary forms, with or | ||
| 13 | * without modification, are permitted provided that the following | ||
| 14 | * conditions are met: | ||
| 15 | * | ||
| 16 | * - Redistributions of source code must retain the above | ||
| 17 | * copyright notice, this list of conditions and the following | ||
| 18 | * disclaimer. | ||
| 19 | * | ||
| 20 | * - Redistributions in binary form must reproduce the above | ||
| 21 | * copyright notice, this list of conditions and the following | ||
| 22 | * disclaimer in the documentation and/or other materials | ||
| 23 | * provided with the distribution. | ||
| 24 | * | ||
| 25 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 26 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
| 27 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
| 28 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS | ||
| 29 | * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN | ||
| 30 | * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
| 31 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
| 32 | * SOFTWARE. | ||
| 33 | */ | ||
| 34 | |||
| 35 | #ifndef IB_USER_CM_H | ||
| 36 | #define IB_USER_CM_H | ||
| 37 | |||
| 38 | #include <linux/types.h> | ||
| 39 | #include <rdma/ib_user_sa.h> | ||
| 40 | |||
| 41 | #define IB_USER_CM_ABI_VERSION 5 | ||
| 42 | |||
| 43 | enum { | ||
| 44 | IB_USER_CM_CMD_CREATE_ID, | ||
| 45 | IB_USER_CM_CMD_DESTROY_ID, | ||
| 46 | IB_USER_CM_CMD_ATTR_ID, | ||
| 47 | |||
| 48 | IB_USER_CM_CMD_LISTEN, | ||
| 49 | IB_USER_CM_CMD_NOTIFY, | ||
| 50 | |||
| 51 | IB_USER_CM_CMD_SEND_REQ, | ||
| 52 | IB_USER_CM_CMD_SEND_REP, | ||
| 53 | IB_USER_CM_CMD_SEND_RTU, | ||
| 54 | IB_USER_CM_CMD_SEND_DREQ, | ||
| 55 | IB_USER_CM_CMD_SEND_DREP, | ||
| 56 | IB_USER_CM_CMD_SEND_REJ, | ||
| 57 | IB_USER_CM_CMD_SEND_MRA, | ||
| 58 | IB_USER_CM_CMD_SEND_LAP, | ||
| 59 | IB_USER_CM_CMD_SEND_APR, | ||
| 60 | IB_USER_CM_CMD_SEND_SIDR_REQ, | ||
| 61 | IB_USER_CM_CMD_SEND_SIDR_REP, | ||
| 62 | |||
| 63 | IB_USER_CM_CMD_EVENT, | ||
| 64 | IB_USER_CM_CMD_INIT_QP_ATTR, | ||
| 65 | }; | ||
| 66 | /* | ||
| 67 | * command ABI structures. | ||
| 68 | */ | ||
| 69 | struct ib_ucm_cmd_hdr { | ||
| 70 | __u32 cmd; | ||
| 71 | __u16 in; | ||
| 72 | __u16 out; | ||
| 73 | }; | ||
| 74 | |||
| 75 | struct ib_ucm_create_id { | ||
| 76 | __aligned_u64 uid; | ||
| 77 | __aligned_u64 response; | ||
| 78 | }; | ||
| 79 | |||
| 80 | struct ib_ucm_create_id_resp { | ||
| 81 | __u32 id; | ||
| 82 | }; | ||
| 83 | |||
| 84 | struct ib_ucm_destroy_id { | ||
| 85 | __aligned_u64 response; | ||
| 86 | __u32 id; | ||
| 87 | __u32 reserved; | ||
| 88 | }; | ||
| 89 | |||
| 90 | struct ib_ucm_destroy_id_resp { | ||
| 91 | __u32 events_reported; | ||
| 92 | }; | ||
| 93 | |||
| 94 | struct ib_ucm_attr_id { | ||
| 95 | __aligned_u64 response; | ||
| 96 | __u32 id; | ||
| 97 | __u32 reserved; | ||
| 98 | }; | ||
| 99 | |||
| 100 | struct ib_ucm_attr_id_resp { | ||
| 101 | __be64 service_id; | ||
| 102 | __be64 service_mask; | ||
| 103 | __be32 local_id; | ||
| 104 | __be32 remote_id; | ||
| 105 | }; | ||
| 106 | |||
| 107 | struct ib_ucm_init_qp_attr { | ||
| 108 | __aligned_u64 response; | ||
| 109 | __u32 id; | ||
| 110 | __u32 qp_state; | ||
| 111 | }; | ||
| 112 | |||
| 113 | struct ib_ucm_listen { | ||
| 114 | __be64 service_id; | ||
| 115 | __be64 service_mask; | ||
| 116 | __u32 id; | ||
| 117 | __u32 reserved; | ||
| 118 | }; | ||
| 119 | |||
| 120 | struct ib_ucm_notify { | ||
| 121 | __u32 id; | ||
| 122 | __u32 event; | ||
| 123 | }; | ||
| 124 | |||
| 125 | struct ib_ucm_private_data { | ||
| 126 | __aligned_u64 data; | ||
| 127 | __u32 id; | ||
| 128 | __u8 len; | ||
| 129 | __u8 reserved[3]; | ||
| 130 | }; | ||
| 131 | |||
| 132 | struct ib_ucm_req { | ||
| 133 | __u32 id; | ||
| 134 | __u32 qpn; | ||
| 135 | __u32 qp_type; | ||
| 136 | __u32 psn; | ||
| 137 | __be64 sid; | ||
| 138 | __aligned_u64 data; | ||
| 139 | __aligned_u64 primary_path; | ||
| 140 | __aligned_u64 alternate_path; | ||
| 141 | __u8 len; | ||
| 142 | __u8 peer_to_peer; | ||
| 143 | __u8 responder_resources; | ||
| 144 | __u8 initiator_depth; | ||
| 145 | __u8 remote_cm_response_timeout; | ||
| 146 | __u8 flow_control; | ||
| 147 | __u8 local_cm_response_timeout; | ||
| 148 | __u8 retry_count; | ||
| 149 | __u8 rnr_retry_count; | ||
| 150 | __u8 max_cm_retries; | ||
| 151 | __u8 srq; | ||
| 152 | __u8 reserved[5]; | ||
| 153 | }; | ||
| 154 | |||
| 155 | struct ib_ucm_rep { | ||
| 156 | __aligned_u64 uid; | ||
| 157 | __aligned_u64 data; | ||
| 158 | __u32 id; | ||
| 159 | __u32 qpn; | ||
| 160 | __u32 psn; | ||
| 161 | __u8 len; | ||
| 162 | __u8 responder_resources; | ||
| 163 | __u8 initiator_depth; | ||
| 164 | __u8 target_ack_delay; | ||
| 165 | __u8 failover_accepted; | ||
| 166 | __u8 flow_control; | ||
| 167 | __u8 rnr_retry_count; | ||
| 168 | __u8 srq; | ||
| 169 | __u8 reserved[4]; | ||
| 170 | }; | ||
| 171 | |||
| 172 | struct ib_ucm_info { | ||
| 173 | __u32 id; | ||
| 174 | __u32 status; | ||
| 175 | __aligned_u64 info; | ||
| 176 | __aligned_u64 data; | ||
| 177 | __u8 info_len; | ||
| 178 | __u8 data_len; | ||
| 179 | __u8 reserved[6]; | ||
| 180 | }; | ||
| 181 | |||
| 182 | struct ib_ucm_mra { | ||
| 183 | __aligned_u64 data; | ||
| 184 | __u32 id; | ||
| 185 | __u8 len; | ||
| 186 | __u8 timeout; | ||
| 187 | __u8 reserved[2]; | ||
| 188 | }; | ||
| 189 | |||
| 190 | struct ib_ucm_lap { | ||
| 191 | __aligned_u64 path; | ||
| 192 | __aligned_u64 data; | ||
| 193 | __u32 id; | ||
| 194 | __u8 len; | ||
| 195 | __u8 reserved[3]; | ||
| 196 | }; | ||
| 197 | |||
| 198 | struct ib_ucm_sidr_req { | ||
| 199 | __u32 id; | ||
| 200 | __u32 timeout; | ||
| 201 | __be64 sid; | ||
| 202 | __aligned_u64 data; | ||
| 203 | __aligned_u64 path; | ||
| 204 | __u16 reserved_pkey; | ||
| 205 | __u8 len; | ||
| 206 | __u8 max_cm_retries; | ||
| 207 | __u8 reserved[4]; | ||
| 208 | }; | ||
| 209 | |||
| 210 | struct ib_ucm_sidr_rep { | ||
| 211 | __u32 id; | ||
| 212 | __u32 qpn; | ||
| 213 | __u32 qkey; | ||
| 214 | __u32 status; | ||
| 215 | __aligned_u64 info; | ||
| 216 | __aligned_u64 data; | ||
| 217 | __u8 info_len; | ||
| 218 | __u8 data_len; | ||
| 219 | __u8 reserved[6]; | ||
| 220 | }; | ||
| 221 | /* | ||
| 222 | * event notification ABI structures. | ||
| 223 | */ | ||
| 224 | struct ib_ucm_event_get { | ||
| 225 | __aligned_u64 response; | ||
| 226 | __aligned_u64 data; | ||
| 227 | __aligned_u64 info; | ||
| 228 | __u8 data_len; | ||
| 229 | __u8 info_len; | ||
| 230 | __u8 reserved[6]; | ||
| 231 | }; | ||
| 232 | |||
| 233 | struct ib_ucm_req_event_resp { | ||
| 234 | struct ib_user_path_rec primary_path; | ||
| 235 | struct ib_user_path_rec alternate_path; | ||
| 236 | __be64 remote_ca_guid; | ||
| 237 | __u32 remote_qkey; | ||
| 238 | __u32 remote_qpn; | ||
| 239 | __u32 qp_type; | ||
| 240 | __u32 starting_psn; | ||
| 241 | __u8 responder_resources; | ||
| 242 | __u8 initiator_depth; | ||
| 243 | __u8 local_cm_response_timeout; | ||
| 244 | __u8 flow_control; | ||
| 245 | __u8 remote_cm_response_timeout; | ||
| 246 | __u8 retry_count; | ||
| 247 | __u8 rnr_retry_count; | ||
| 248 | __u8 srq; | ||
| 249 | __u8 port; | ||
| 250 | __u8 reserved[7]; | ||
| 251 | }; | ||
| 252 | |||
| 253 | struct ib_ucm_rep_event_resp { | ||
| 254 | __be64 remote_ca_guid; | ||
| 255 | __u32 remote_qkey; | ||
| 256 | __u32 remote_qpn; | ||
| 257 | __u32 starting_psn; | ||
| 258 | __u8 responder_resources; | ||
| 259 | __u8 initiator_depth; | ||
| 260 | __u8 target_ack_delay; | ||
| 261 | __u8 failover_accepted; | ||
| 262 | __u8 flow_control; | ||
| 263 | __u8 rnr_retry_count; | ||
| 264 | __u8 srq; | ||
| 265 | __u8 reserved[5]; | ||
| 266 | }; | ||
| 267 | |||
| 268 | struct ib_ucm_rej_event_resp { | ||
| 269 | __u32 reason; | ||
| 270 | /* ari in ib_ucm_event_get info field. */ | ||
| 271 | }; | ||
| 272 | |||
| 273 | struct ib_ucm_mra_event_resp { | ||
| 274 | __u8 timeout; | ||
| 275 | __u8 reserved[3]; | ||
| 276 | }; | ||
| 277 | |||
| 278 | struct ib_ucm_lap_event_resp { | ||
| 279 | struct ib_user_path_rec path; | ||
| 280 | }; | ||
| 281 | |||
| 282 | struct ib_ucm_apr_event_resp { | ||
| 283 | __u32 status; | ||
| 284 | /* apr info in ib_ucm_event_get info field. */ | ||
| 285 | }; | ||
| 286 | |||
| 287 | struct ib_ucm_sidr_req_event_resp { | ||
| 288 | __u16 pkey; | ||
| 289 | __u8 port; | ||
| 290 | __u8 reserved; | ||
| 291 | }; | ||
| 292 | |||
| 293 | struct ib_ucm_sidr_rep_event_resp { | ||
| 294 | __u32 status; | ||
| 295 | __u32 qkey; | ||
| 296 | __u32 qpn; | ||
| 297 | /* info in ib_ucm_event_get info field. */ | ||
| 298 | }; | ||
| 299 | |||
| 300 | #define IB_UCM_PRES_DATA 0x01 | ||
| 301 | #define IB_UCM_PRES_INFO 0x02 | ||
| 302 | #define IB_UCM_PRES_PRIMARY 0x04 | ||
| 303 | #define IB_UCM_PRES_ALTERNATE 0x08 | ||
| 304 | |||
| 305 | struct ib_ucm_event_resp { | ||
| 306 | __aligned_u64 uid; | ||
| 307 | __u32 id; | ||
| 308 | __u32 event; | ||
| 309 | __u32 present; | ||
| 310 | __u32 reserved; | ||
| 311 | union { | ||
| 312 | struct ib_ucm_req_event_resp req_resp; | ||
| 313 | struct ib_ucm_rep_event_resp rep_resp; | ||
| 314 | struct ib_ucm_rej_event_resp rej_resp; | ||
| 315 | struct ib_ucm_mra_event_resp mra_resp; | ||
| 316 | struct ib_ucm_lap_event_resp lap_resp; | ||
| 317 | struct ib_ucm_apr_event_resp apr_resp; | ||
| 318 | |||
| 319 | struct ib_ucm_sidr_req_event_resp sidr_req_resp; | ||
| 320 | struct ib_ucm_sidr_rep_event_resp sidr_rep_resp; | ||
| 321 | |||
| 322 | __u32 send_status; | ||
| 323 | } u; | ||
| 324 | }; | ||
| 325 | |||
| 326 | #endif /* IB_USER_CM_H */ | ||
| @@ -51,6 +51,7 @@ enum mlx5_ib_devx_methods { · 50 unmodified lines | |||
| 51 | MLX5_IB_METHOD_DEVX_OTHER = (1U << UVERBS_ID_NS_SHIFT), | 51 | MLX5_IB_METHOD_DEVX_OTHER = (1U << UVERBS_ID_NS_SHIFT), |
| 52 | MLX5_IB_METHOD_DEVX_QUERY_UAR, | 52 | MLX5_IB_METHOD_DEVX_QUERY_UAR, |
| 53 | MLX5_IB_METHOD_DEVX_QUERY_EQN, | 53 | MLX5_IB_METHOD_DEVX_QUERY_EQN, |
| 54 | MLX5_IB_METHOD_DEVX_SUBSCRIBE_EVENT, | ||
| 54 | }; | 55 | }; |
| 55 | 56 | ||
| 56 | enum mlx5_ib_devx_other_attrs { | 57 | enum mlx5_ib_devx_other_attrs { |
| @@ -93,6 +94,14 @@ enum mlx5_ib_devx_obj_query_async_attrs { · 36 unmodified lines | |||
| 93 | MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_OUT_LEN, | 94 | MLX5_IB_ATTR_DEVX_OBJ_QUERY_ASYNC_OUT_LEN, |
| 94 | }; | 95 | }; |
| 95 | 96 | ||
| 97 | enum mlx5_ib_devx_subscribe_event_attrs { | ||
| 98 | MLX5_IB_ATTR_DEVX_SUBSCRIBE_EVENT_FD_HANDLE = (1U << UVERBS_ID_NS_SHIFT), | ||
| 99 | MLX5_IB_ATTR_DEVX_SUBSCRIBE_EVENT_OBJ_HANDLE, | ||
| 100 | MLX5_IB_ATTR_DEVX_SUBSCRIBE_EVENT_TYPE_NUM_LIST, | ||
| 101 | MLX5_IB_ATTR_DEVX_SUBSCRIBE_EVENT_FD_NUM, | ||
| 102 | MLX5_IB_ATTR_DEVX_SUBSCRIBE_EVENT_COOKIE, | ||
| 103 | }; | ||
| 104 | |||
| 96 | enum mlx5_ib_devx_query_eqn_attrs { | 105 | enum mlx5_ib_devx_query_eqn_attrs { |
| 97 | MLX5_IB_ATTR_DEVX_QUERY_EQN_USER_VEC = (1U << UVERBS_ID_NS_SHIFT), | 106 | MLX5_IB_ATTR_DEVX_QUERY_EQN_USER_VEC = (1U << UVERBS_ID_NS_SHIFT), |
| 98 | MLX5_IB_ATTR_DEVX_QUERY_EQN_DEV_EQN, | 107 | MLX5_IB_ATTR_DEVX_QUERY_EQN_DEV_EQN, |
| @@ -127,16 +136,26 @@ enum mlx5_ib_devx_async_cmd_fd_alloc_attrs { · 28 unmodified lines | |||
| 127 | MLX5_IB_ATTR_DEVX_ASYNC_CMD_FD_ALLOC_HANDLE = (1U << UVERBS_ID_NS_SHIFT), | 136 | MLX5_IB_ATTR_DEVX_ASYNC_CMD_FD_ALLOC_HANDLE = (1U << UVERBS_ID_NS_SHIFT), |
| 128 | }; | 137 | }; |
| 129 | 138 | ||
| 139 | enum mlx5_ib_devx_async_event_fd_alloc_attrs { | ||
| 140 | MLX5_IB_ATTR_DEVX_ASYNC_EVENT_FD_ALLOC_HANDLE = (1U << UVERBS_ID_NS_SHIFT), | ||
| 141 | MLX5_IB_ATTR_DEVX_ASYNC_EVENT_FD_ALLOC_FLAGS, | ||
| 142 | }; | ||
| 143 | |||
| 130 | enum mlx5_ib_devx_async_cmd_fd_methods { | 144 | enum mlx5_ib_devx_async_cmd_fd_methods { |
| 131 | MLX5_IB_METHOD_DEVX_ASYNC_CMD_FD_ALLOC = (1U << UVERBS_ID_NS_SHIFT), | 145 | MLX5_IB_METHOD_DEVX_ASYNC_CMD_FD_ALLOC = (1U << UVERBS_ID_NS_SHIFT), |
| 132 | }; | 146 | }; |
| 133 | 147 | ||
| 148 | enum mlx5_ib_devx_async_event_fd_methods { | ||
| 149 | MLX5_IB_METHOD_DEVX_ASYNC_EVENT_FD_ALLOC = (1U << UVERBS_ID_NS_SHIFT), | ||
| 150 | }; | ||
| 151 | |||
| 134 | enum mlx5_ib_objects { | 152 | enum mlx5_ib_objects { |
| 135 | MLX5_IB_OBJECT_DEVX = (1U << UVERBS_ID_NS_SHIFT), | 153 | MLX5_IB_OBJECT_DEVX = (1U << UVERBS_ID_NS_SHIFT), |
| 136 | MLX5_IB_OBJECT_DEVX_OBJ, | 154 | MLX5_IB_OBJECT_DEVX_OBJ, |
| 137 | MLX5_IB_OBJECT_DEVX_UMEM, | 155 | MLX5_IB_OBJECT_DEVX_UMEM, |
| 138 | MLX5_IB_OBJECT_FLOW_MATCHER, | 156 | MLX5_IB_OBJECT_FLOW_MATCHER, |
| 139 | MLX5_IB_OBJECT_DEVX_ASYNC_CMD_FD, | 157 | MLX5_IB_OBJECT_DEVX_ASYNC_CMD_FD, |
| 158 | MLX5_IB_OBJECT_DEVX_ASYNC_EVENT_FD, | ||
| 140 | }; | 159 | }; |
| 141 | 160 | ||
| 142 | enum mlx5_ib_flow_matcher_create_attrs { | 161 | enum mlx5_ib_flow_matcher_create_attrs { |
| @@ -63,5 +63,14 @@ enum mlx5_ib_uapi_dm_type { · 62 unmodified lines | |||
| 63 | MLX5_IB_UAPI_DM_TYPE_HEADER_MODIFY_SW_ICM, | 63 | MLX5_IB_UAPI_DM_TYPE_HEADER_MODIFY_SW_ICM, |
| 64 | }; | 64 | }; |
| 65 | 65 | ||
| 66 | enum mlx5_ib_uapi_devx_create_event_channel_flags { | ||
| 67 | MLX5_IB_UAPI_DEVX_CR_EV_CH_FLAGS_OMIT_DATA = 1 << 0, | ||
| 68 | }; | ||
| 69 | |||
| 70 | struct mlx5_ib_uapi_devx_async_event_hdr { | ||
| 71 | __aligned_u64 cookie; | ||
| 72 | __u8 out_data[]; | ||
| 73 | }; | ||
| 74 | |||
| 66 | #endif | 75 | #endif |
| 67 | 76 | ||
| @@ -147,6 +147,18 @@ enum { · 146 unmodified lines | |||
| 147 | IWPM_NLA_HELLO_MAX | 147 | IWPM_NLA_HELLO_MAX |
| 148 | }; | 148 | }; |
| 149 | 149 | ||
| 150 | /* For RDMA_NLDEV_ATTR_DEV_NODE_TYPE */ | ||
| 151 | enum { | ||
| 152 | /* IB values map to NodeInfo:NodeType. */ | ||
| 153 | RDMA_NODE_IB_CA = 1, | ||
| 154 | RDMA_NODE_IB_SWITCH, | ||
| 155 | RDMA_NODE_IB_ROUTER, | ||
| 156 | RDMA_NODE_RNIC, | ||
| 157 | RDMA_NODE_USNIC, | ||
| 158 | RDMA_NODE_USNIC_UDP, | ||
| 159 | RDMA_NODE_UNSPECIFIED, | ||
| 160 | }; | ||
| 161 | |||
| 150 | /* | 162 | /* |
| 151 | * Local service operations: | 163 | * Local service operations: |
| 152 | * RESOLVE - The client requests the local service to resolve a path. | 164 | * RESOLVE - The client requests the local service to resolve a path. |
| @@ -267,11 +279,15 @@ enum rdma_nldev_command { · 114 unmodified lines | |||
| 267 | 279 | ||
| 268 | RDMA_NLDEV_CMD_RES_PD_GET, /* can dump */ | 280 | RDMA_NLDEV_CMD_RES_PD_GET, /* can dump */ |
| 269 | 281 | ||
| 270 | RDMA_NLDEV_NUM_OPS | 282 | RDMA_NLDEV_CMD_GET_CHARDEV, |
| 271 | }; | ||
| 272 | 283 | ||
| 273 | enum { | 284 | RDMA_NLDEV_CMD_STAT_SET, |
| 274 | RDMA_NLDEV_ATTR_ENTRY_STRLEN = 16, | 285 | |
| 286 | RDMA_NLDEV_CMD_STAT_GET, /* can dump */ | ||
| 287 | |||
| 288 | RDMA_NLDEV_CMD_STAT_DEL, | ||
| 289 | |||
| 290 | RDMA_NLDEV_NUM_OPS | ||
| 275 | }; | 291 | }; |
| 276 | 292 | ||
| 277 | enum rdma_nldev_print_type { | 293 | enum rdma_nldev_print_type { |
| @@ -478,10 +494,72 @@ enum rdma_nldev_attr { · 200 unmodified lines | |||
| 478 | * File descriptor handle of the net namespace object | 494 | * File descriptor handle of the net namespace object |
| 479 | */ | 495 | */ |
| 480 | RDMA_NLDEV_NET_NS_FD, /* u32 */ | 496 | RDMA_NLDEV_NET_NS_FD, /* u32 */ |
| 497 | /* | ||
| 498 | * Information about a chardev. | ||
| 499 | * CHARDEV_TYPE is the name of the chardev ABI (ie uverbs, umad, etc) | ||
| 500 | * CHARDEV_ABI signals the ABI revision (historical) | ||
| 501 | * CHARDEV_NAME is the kernel name for the /dev/ file (no directory) | ||
| 502 | * CHARDEV is the 64 bit dev_t for the inode | ||
| 503 | */ | ||
| 504 | RDMA_NLDEV_ATTR_CHARDEV_TYPE, /* string */ | ||
| 505 | RDMA_NLDEV_ATTR_CHARDEV_NAME, /* string */ | ||
| 506 | RDMA_NLDEV_ATTR_CHARDEV_ABI, /* u64 */ | ||
| 507 | RDMA_NLDEV_ATTR_CHARDEV, /* u64 */ | ||
| 508 | RDMA_NLDEV_ATTR_UVERBS_DRIVER_ID, /* u64 */ | ||
| 509 | /* | ||
| 510 | * Counter-specific attributes. | ||
| 511 | */ | ||
| 512 | RDMA_NLDEV_ATTR_STAT_MODE, /* u32 */ | ||
| 513 | RDMA_NLDEV_ATTR_STAT_RES, /* u32 */ | ||
| 514 | RDMA_NLDEV_ATTR_STAT_AUTO_MODE_MASK, /* u32 */ | ||
| 515 | RDMA_NLDEV_ATTR_STAT_COUNTER, /* nested table */ | ||
| 516 | RDMA_NLDEV_ATTR_STAT_COUNTER_ENTRY, /* nested table */ | ||
| 517 | RDMA_NLDEV_ATTR_STAT_COUNTER_ID, /* u32 */ | ||
| 518 | RDMA_NLDEV_ATTR_STAT_HWCOUNTERS, /* nested table */ | ||
| 519 | RDMA_NLDEV_ATTR_STAT_HWCOUNTER_ENTRY, /* nested table */ | ||
| 520 | RDMA_NLDEV_ATTR_STAT_HWCOUNTER_ENTRY_NAME, /* string */ | ||
| 521 | RDMA_NLDEV_ATTR_STAT_HWCOUNTER_ENTRY_VALUE, /* u64 */ | ||
| 522 | |||
| 523 | /* | ||
| 524 | * CQ adaptive moderatio (DIM) | ||
| 525 | */ | ||
| 526 | RDMA_NLDEV_ATTR_DEV_DIM, /* u8 */ | ||
| 481 | 527 | ||
| 482 | /* | 528 | /* |
| 483 | * Always the end | 529 | * Always the end |
| 484 | */ | 530 | */ |
| 485 | RDMA_NLDEV_ATTR_MAX | 531 | RDMA_NLDEV_ATTR_MAX |
| 486 | }; | 532 | }; |
| 533 | |||
| 534 | /* | ||
| 535 | * Supported counter bind modes. All modes are mutual-exclusive. | ||
| 536 | */ | ||
| 537 | enum rdma_nl_counter_mode { | ||
| 538 | RDMA_COUNTER_MODE_NONE, | ||
| 539 | |||
| 540 | /* | ||
| 541 | * A qp is bound with a counter automatically during initialization | ||
| 542 | * based on the auto mode (e.g., qp type, ...) | ||
| 543 | */ | ||
| 544 | RDMA_COUNTER_MODE_AUTO, | ||
| 545 | |||
| 546 | /* | ||
| 547 | * Which qp are bound with which counter is explicitly specified | ||
| 548 | * by the user | ||
| 549 | */ | ||
| 550 | RDMA_COUNTER_MODE_MANUAL, | ||
| 551 | |||
| 552 | /* | ||
| 553 | * Always the end | ||
| 554 | */ | ||
| 555 | RDMA_COUNTER_MODE_MAX, | ||
| 556 | }; | ||
| 557 | |||
| 558 | /* | ||
| 559 | * Supported criteria in counter auto mode. | ||
| 560 | * Currently only "qp type" is supported | ||
| 561 | */ | ||
| 562 | enum rdma_nl_counter_mask { | ||
| 563 | RDMA_COUNTER_MASK_QP_TYPE = 1, | ||
| 564 | }; | ||
| 487 | #endif /* _UAPI_RDMA_NETLINK_H */ | 565 | #endif /* _UAPI_RDMA_NETLINK_H */ |
| @@ -36,7 +36,7 @@ · 35 unmodified lines | |||
| 36 | #include <linux/types.h> | 36 | #include <linux/types.h> |
| 37 | #include <linux/ioctl.h> | 37 | #include <linux/ioctl.h> |
| 38 | 38 | ||
| 39 | /* Documentation/ioctl/ioctl-number.txt */ | 39 | /* Documentation/ioctl/ioctl-number.rst */ |
| 40 | #define RDMA_IOCTL_MAGIC 0x1b | 40 | #define RDMA_IOCTL_MAGIC 0x1b |
| 41 | #define RDMA_VERBS_IOCTL \ | 41 | #define RDMA_VERBS_IOCTL \ |
| 42 | _IOWR(RDMA_IOCTL_MAGIC, 1, struct ib_uverbs_ioctl_hdr) | 42 | _IOWR(RDMA_IOCTL_MAGIC, 1, struct ib_uverbs_ioctl_hdr) |
| @@ -103,6 +103,7 @@ enum rdma_driver_id { · 60 unmodified lines | |||
| 103 | RDMA_DRIVER_HFI1, | 103 | RDMA_DRIVER_HFI1, |
| 104 | RDMA_DRIVER_QIB, | 104 | RDMA_DRIVER_QIB, |
| 105 | RDMA_DRIVER_EFA, | 105 | RDMA_DRIVER_EFA, |
| 106 | RDMA_DRIVER_SIW, | ||
| 106 | }; | 107 | }; |
| 107 | 108 | ||
| 108 | #endif | 109 | #endif |
| @@ -0,0 +1,66 @@ | |||
| 1 | /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */ | ||
| 2 | |||
| 3 | /* | ||
| 4 | * This file contains defines, structures, etc. that are used | ||
| 5 | * to communicate between kernel and user code. | ||
| 6 | */ | ||
| 7 | |||
| 8 | #ifndef RVT_ABI_USER_H | ||
| 9 | #define RVT_ABI_USER_H | ||
| 10 | |||
| 11 | #include <linux/types.h> | ||
| 12 | #include <rdma/ib_user_verbs.h> | ||
| 13 | #ifndef RDMA_ATOMIC_UAPI | ||
| 14 | #define RDMA_ATOMIC_UAPI(_type, _name) struct{ _type val; } _name | ||
| 15 | #endif | ||
| 16 | |||
| 17 | struct rvt_wqe_sge { | ||
| 18 | __aligned_u64 addr; | ||
| 19 | __u32 length; | ||
| 20 | __u32 lkey; | ||
| 21 | }; | ||
| 22 | |||
| 23 | /* | ||
| 24 | * This structure is used to contain the head pointer, tail pointer, | ||
| 25 | * and completion queue entries as a single memory allocation so | ||
| 26 | * it can be mmap'ed into user space. | ||
| 27 | */ | ||
| 28 | struct rvt_cq_wc { | ||
| 29 | /* index of next entry to fill */ | ||
| 30 | RDMA_ATOMIC_UAPI(__u32, head); | ||
| 31 | /* index of next ib_poll_cq() entry */ | ||
| 32 | RDMA_ATOMIC_UAPI(__u32, tail); | ||
| 33 | |||
| 34 | /* these are actually size ibcq.cqe + 1 */ | ||
| 35 | struct ib_uverbs_wc uqueue[]; | ||
| 36 | }; | ||
| 37 | |||
| 38 | /* | ||
| 39 | * Receive work request queue entry. | ||
| 40 | * The size of the sg_list is determined when the QP (or SRQ) is created | ||
| 41 | * and stored in qp->r_rq.max_sge (or srq->rq.max_sge). | ||
| 42 | */ | ||
| 43 | struct rvt_rwqe { | ||
| 44 | __u64 wr_id; | ||
| 45 | __u8 num_sge; | ||
| 46 | __u8 padding[7]; | ||
| 47 | struct rvt_wqe_sge sg_list[]; | ||
| 48 | }; | ||
| 49 | |||
| 50 | /* | ||
| 51 | * This structure is used to contain the head pointer, tail pointer, | ||
| 52 | * and receive work queue entries as a single memory allocation so | ||
| 53 | * it can be mmap'ed into user space. | ||
| 54 | * Note that the wq array elements are variable size so you can't | ||
| 55 | * just index into the array to get the N'th element; | ||
| 56 | * use get_rwqe_ptr() for user space and rvt_get_rwqe_ptr() | ||
| 57 | * for kernel space. | ||
| 58 | */ | ||
| 59 | struct rvt_rwq { | ||
| 60 | /* new work requests posted to the head */ | ||
| 61 | RDMA_ATOMIC_UAPI(__u32, head); | ||
| 62 | /* receives pull requests from here. */ | ||
| 63 | RDMA_ATOMIC_UAPI(__u32, tail); | ||
| 64 | struct rvt_rwqe wq[]; | ||
| 65 | }; | ||
| 66 | #endif /* RVT_ABI_USER_H */ | ||
| @@ -0,0 +1,185 @@ | |||
| 1 | /* SPDX-License-Identifier: (GPL-2.0 WITH Linux-syscall-note) or BSD-3-Clause */ | ||
| 2 | |||
| 3 | /* Authors: Bernard Metzler <bmt@zurich.ibm.com> */ | ||
| 4 | /* Copyright (c) 2008-2019, IBM Corporation */ | ||
| 5 | |||
| 6 | #ifndef _SIW_USER_H | ||
| 7 | #define _SIW_USER_H | ||
| 8 | |||
| 9 | #include <linux/types.h> | ||
| 10 | |||
| 11 | #define SIW_NODE_DESC_COMMON "Software iWARP stack" | ||
| 12 | #define SIW_ABI_VERSION 1 | ||
| 13 | #define SIW_MAX_SGE 6 | ||
| 14 | #define SIW_UOBJ_MAX_KEY 0x08FFFF | ||
| 15 | #define SIW_INVAL_UOBJ_KEY (SIW_UOBJ_MAX_KEY + 1) | ||
| 16 | |||
| 17 | struct siw_uresp_create_cq { | ||
| 18 | __u32 cq_id; | ||
| 19 | __u32 num_cqe; | ||
| 20 | __aligned_u64 cq_key; | ||
| 21 | }; | ||
| 22 | |||
| 23 | struct siw_uresp_create_qp { | ||
| 24 | __u32 qp_id; | ||
| 25 | __u32 num_sqe; | ||
| 26 | __u32 num_rqe; | ||
| 27 | __u32 pad; | ||
| 28 | __aligned_u64 sq_key; | ||
| 29 | __aligned_u64 rq_key; | ||
| 30 | }; | ||
| 31 | |||
| 32 | struct siw_ureq_reg_mr { | ||
| 33 | __u8 stag_key; | ||
| 34 | __u8 reserved[3]; | ||
| 35 | __u32 pad; | ||
| 36 | }; | ||
| 37 | |||
| 38 | struct siw_uresp_reg_mr { | ||
| 39 | __u32 stag; | ||
| 40 | __u32 pad; | ||
| 41 | }; | ||
| 42 | |||
| 43 | struct siw_uresp_create_srq { | ||
| 44 | __u32 num_rqe; | ||
| 45 | __u32 pad; | ||
| 46 | __aligned_u64 srq_key; | ||
| 47 | }; | ||
| 48 | |||
| 49 | struct siw_uresp_alloc_ctx { | ||
| 50 | __u32 dev_id; | ||
| 51 | __u32 pad; | ||
| 52 | }; | ||
| 53 | |||
| 54 | enum siw_opcode { | ||
| 55 | SIW_OP_WRITE, | ||
| 56 | SIW_OP_READ, | ||
| 57 | SIW_OP_READ_LOCAL_INV, | ||
| 58 | SIW_OP_SEND, | ||
| 59 | SIW_OP_SEND_WITH_IMM, | ||
| 60 | SIW_OP_SEND_REMOTE_INV, | ||
| 61 | |||
| 62 | /* Unsupported */ | ||
| 63 | SIW_OP_FETCH_AND_ADD, | ||
| 64 | SIW_OP_COMP_AND_SWAP, | ||
| 65 | |||
| 66 | SIW_OP_RECEIVE, | ||
| 67 | /* provider internal SQE */ | ||
| 68 | SIW_OP_READ_RESPONSE, | ||
| 69 | /* | ||
| 70 | * below opcodes valid for | ||
| 71 | * in-kernel clients only | ||
| 72 | */ | ||
| 73 | SIW_OP_INVAL_STAG, | ||
| 74 | SIW_OP_REG_MR, | ||
| 75 | SIW_NUM_OPCODES | ||
| 76 | }; | ||
| 77 | |||
| 78 | /* Keep it same as ibv_sge to allow for memcpy */ | ||
| 79 | struct siw_sge { | ||
| 80 | __aligned_u64 laddr; | ||
| 81 | __u32 length; | ||
| 82 | __u32 lkey; | ||
| 83 | }; | ||
| 84 | |||
| 85 | /* | ||
| 86 | * Inline data are kept within the work request itself occupying | ||
| 87 | * the space of sge[1] .. sge[n]. Therefore, inline data cannot be | ||
| 88 | * supported if SIW_MAX_SGE is below 2 elements. | ||
| 89 | */ | ||
| 90 | #define SIW_MAX_INLINE (sizeof(struct siw_sge) * (SIW_MAX_SGE - 1)) | ||
| 91 | |||
| 92 | #if SIW_MAX_SGE < 2 | ||
| 93 | #error "SIW_MAX_SGE must be at least 2" | ||
| 94 | #endif | ||
| 95 | |||
| 96 | enum siw_wqe_flags { | ||
| 97 | SIW_WQE_VALID = 1, | ||
| 98 | SIW_WQE_INLINE = (1 << 1), | ||
| 99 | SIW_WQE_SIGNALLED = (1 << 2), | ||
| 100 | SIW_WQE_SOLICITED = (1 << 3), | ||
| 101 | SIW_WQE_READ_FENCE = (1 << 4), | ||
| 102 | SIW_WQE_REM_INVAL = (1 << 5), | ||
| 103 | SIW_WQE_COMPLETED = (1 << 6) | ||
| 104 | }; | ||
| 105 | |||
| 106 | /* Send Queue Element */ | ||
| 107 | struct siw_sqe { | ||
| 108 | __aligned_u64 id; | ||
| 109 | __u16 flags; | ||
| 110 | __u8 num_sge; | ||
| 111 | /* Contains enum siw_opcode values */ | ||
| 112 | __u8 opcode; | ||
| 113 | __u32 rkey; | ||
| 114 | union { | ||
| 115 | __aligned_u64 raddr; | ||
| 116 | __aligned_u64 base_mr; | ||
| 117 | }; | ||
| 118 | union { | ||
| 119 | struct siw_sge sge[SIW_MAX_SGE]; | ||
| 120 | __aligned_u64 access; | ||
| 121 | }; | ||
| 122 | }; | ||
| 123 | |||
| 124 | /* Receive Queue Element */ | ||
| 125 | struct siw_rqe { | ||
| 126 | __aligned_u64 id; | ||
| 127 | __u16 flags; | ||
| 128 | __u8 num_sge; | ||
| 129 | /* | ||
| 130 | * only used by kernel driver, | ||
| 131 | * ignored if set by user | ||
| 132 | */ | ||
| 133 | __u8 opcode; | ||
| 134 | __u32 unused; | ||
| 135 | struct siw_sge sge[SIW_MAX_SGE]; | ||
| 136 | }; | ||
| 137 | |||
| 138 | enum siw_notify_flags { | ||
| 139 | SIW_NOTIFY_NOT = (0), | ||
| 140 | SIW_NOTIFY_SOLICITED = (1 << 0), | ||
| 141 | SIW_NOTIFY_NEXT_COMPLETION = (1 << 1), | ||
| 142 | SIW_NOTIFY_MISSED_EVENTS = (1 << 2), | ||
| 143 | SIW_NOTIFY_ALL = SIW_NOTIFY_SOLICITED | SIW_NOTIFY_NEXT_COMPLETION | | ||
| 144 | SIW_NOTIFY_MISSED_EVENTS | ||
| 145 | }; | ||
| 146 | |||
| 147 | enum siw_wc_status { | ||
| 148 | SIW_WC_SUCCESS, | ||
| 149 | SIW_WC_LOC_LEN_ERR, | ||
| 150 | SIW_WC_LOC_PROT_ERR, | ||
| 151 | SIW_WC_LOC_QP_OP_ERR, | ||
| 152 | SIW_WC_WR_FLUSH_ERR, | ||
| 153 | SIW_WC_BAD_RESP_ERR, | ||
| 154 | SIW_WC_LOC_ACCESS_ERR, | ||
| 155 | SIW_WC_REM_ACCESS_ERR, | ||
| 156 | SIW_WC_REM_INV_REQ_ERR, | ||
| 157 | SIW_WC_GENERAL_ERR, | ||
| 158 | SIW_NUM_WC_STATUS | ||
| 159 | }; | ||
| 160 | |||
| 161 | struct siw_cqe { | ||
| 162 | __aligned_u64 id; | ||
| 163 | __u8 flags; | ||
| 164 | __u8 opcode; | ||
| 165 | __u16 status; | ||
| 166 | __u32 bytes; | ||
| 167 | union { | ||
| 168 | __aligned_u64 imm_data; | ||
| 169 | __u32 inval_stag; | ||
| 170 | }; | ||
| 171 | /* QP number or QP pointer */ | ||
| 172 | union { | ||
| 173 | struct ib_qp *base_qp; | ||
| 174 | __aligned_u64 qp_id; | ||
| 175 | }; | ||
| 176 | }; | ||
| 177 | |||
| 178 | /* | ||
| 179 | * Shared structure between user and kernel | ||
| 180 | * to control CQ arming. | ||
| 181 | */ | ||
| 182 | struct siw_cq_ctrl { | ||
| 183 | __aligned_u64 notify; | ||
| 184 | }; | ||
| 185 | #endif | ||
| @@ -2,19 +2,6 @@ · 1 unmodified line | |||
| 2 | /* | 2 | /* |
| 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. | 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. |
| 4 | * | 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify it | ||
| 6 | * under the terms and conditions of the GNU General Public License, | ||
| 7 | * version 2, as published by the Free Software Foundation. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope it will be useful, but WITHOUT | ||
| 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
| 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
| 12 | * more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License along with | ||
| 15 | * this program; if not, write to the Free Software Foundation, Inc., | ||
| 16 | * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. | ||
| 17 | * | ||
| 18 | * Maintained at www.Open-FCoE.org | 5 | * Maintained at www.Open-FCoE.org |
| 19 | */ | 6 | */ |
| 20 | 7 | ||
| @@ -2,19 +2,6 @@ · 1 unmodified line | |||
| 2 | /* | 2 | /* |
| 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. | 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. |
| 4 | * | 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify it | ||
| 6 | * under the terms and conditions of the GNU General Public License, | ||
| 7 | * version 2, as published by the Free Software Foundation. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope it will be useful, but WITHOUT | ||
| 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
| 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
| 12 | * more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License along with | ||
| 15 | * this program; if not, write to the Free Software Foundation, Inc., | ||
| 16 | * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. | ||
| 17 | * | ||
| 18 | * Maintained at www.Open-FCoE.org | 5 | * Maintained at www.Open-FCoE.org |
| 19 | */ | 6 | */ |
| 20 | 7 | ||
| @@ -2,19 +2,6 @@ · 1 unmodified line | |||
| 2 | /* | 2 | /* |
| 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. | 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. |
| 4 | * | 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify it | ||
| 6 | * under the terms and conditions of the GNU General Public License, | ||
| 7 | * version 2, as published by the Free Software Foundation. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope it will be useful, but WITHOUT | ||
| 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
| 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
| 12 | * more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License along with | ||
| 15 | * this program; if not, write to the Free Software Foundation, Inc., | ||
| 16 | * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. | ||
| 17 | * | ||
| 18 | * Maintained at www.Open-FCoE.org | 5 | * Maintained at www.Open-FCoE.org |
| 19 | */ | 6 | */ |
| 20 | 7 | ||
| @@ -2,19 +2,6 @@ · 1 unmodified line | |||
| 2 | /* | 2 | /* |
| 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. | 3 | * Copyright(c) 2007 Intel Corporation. All rights reserved. |
| 4 | * | 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify it | ||
| 6 | * under the terms and conditions of the GNU General Public License, | ||
| 7 | * version 2, as published by the Free Software Foundation. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope it will be useful, but WITHOUT | ||
| 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
| 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
| 12 | * more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License along with | ||
| 15 | * this program; if not, write to the Free Software Foundation, Inc., | ||
| 16 | * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. | ||
| 17 | * | ||
| 18 | * Maintained at www.Open-FCoE.org | 5 | * Maintained at www.Open-FCoE.org |
| 19 | */ | 6 | */ |
| 20 | 7 | ||
| @@ -3,21 +3,6 @@ · 2 unmodified lines | |||
| 3 | * FC Transport BSG Interface | 3 | * FC Transport BSG Interface |
| 4 | * | 4 | * |
| 5 | * Copyright (C) 2008 James Smart, Emulex Corporation | 5 | * Copyright (C) 2008 James Smart, Emulex Corporation |
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License as published by | ||
| 9 | * the Free Software Foundation; either version 2 of the License, or | ||
| 10 | * (at your option) any later version. | ||
| 11 | * | ||
| 12 | * This program is distributed in the hope that it will be useful, | ||
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | * GNU General Public License for more details. | ||
| 16 | * | ||
| 17 | * You should have received a copy of the GNU General Public License | ||
| 18 | * along with this program; if not, write to the Free Software | ||
| 19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 20 | * | ||
| 21 | */ | 6 | */ |
| 22 | 7 | ||
| 23 | #ifndef SCSI_BSG_FC_H | 8 | #ifndef SCSI_BSG_FC_H |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * UFS Transport SGIO v4 BSG Message Support | 3 | * UFS Transport SGIO v4 BSG Message Support |
| 4 | * | 4 | * |
| @@ -4,21 +4,6 @@ · 3 unmodified lines | |||
| 4 | * Used for the posting of outbound SCSI transport events | 4 | * Used for the posting of outbound SCSI transport events |
| 5 | * | 5 | * |
| 6 | * Copyright (C) 2006 James Smart, Emulex Corporation | 6 | * Copyright (C) 2006 James Smart, Emulex Corporation |
| 7 | * | ||
| 8 | * This program is free software; you can redistribute it and/or modify | ||
| 9 | * it under the terms of the GNU General Public License as published by | ||
| 10 | * the Free Software Foundation; either version 2 of the License, or | ||
| 11 | * (at your option) any later version. | ||
| 12 | * | ||
| 13 | * This program is distributed in the hope that it will be useful, | ||
| 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 16 | * GNU General Public License for more details. | ||
| 17 | * | ||
| 18 | * You should have received a copy of the GNU General Public License | ||
| 19 | * along with this program; if not, write to the Free Software | ||
| 20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 21 | * | ||
| 22 | */ | 7 | */ |
| 23 | #ifndef SCSI_NETLINK_H | 8 | #ifndef SCSI_NETLINK_H |
| 24 | #define SCSI_NETLINK_H | 9 | #define SCSI_NETLINK_H |
| @@ -3,21 +3,6 @@ · 2 unmodified lines | |||
| 3 | * FC Transport Netlink Interface | 3 | * FC Transport Netlink Interface |
| 4 | * | 4 | * |
| 5 | * Copyright (C) 2006 James Smart, Emulex Corporation | 5 | * Copyright (C) 2006 James Smart, Emulex Corporation |
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License as published by | ||
| 9 | * the Free Software Foundation; either version 2 of the License, or | ||
| 10 | * (at your option) any later version. | ||
| 11 | * | ||
| 12 | * This program is distributed in the hope that it will be useful, | ||
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | * GNU General Public License for more details. | ||
| 16 | * | ||
| 17 | * You should have received a copy of the GNU General Public License | ||
| 18 | * along with this program; if not, write to the Free Software | ||
| 19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 20 | * | ||
| 21 | */ | 6 | */ |
| 22 | #ifndef SCSI_NETLINK_FC_H | 7 | #ifndef SCSI_NETLINK_FC_H |
| 23 | #define SCSI_NETLINK_FC_H | 8 | #define SCSI_NETLINK_FC_H |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ |
| 2 | /* | 2 | /* |
| 3 | * skl-tplg-interface.h - Intel DSP FW private data interface | 3 | * skl-tplg-interface.h - Intel DSP FW private data interface |
| 4 | * | 4 | * |
| @@ -26,7 +26,7 @@ · 25 unmodified lines | |||
| 26 | 26 | ||
| 27 | /* SOF ABI version major, minor and patch numbers */ | 27 | /* SOF ABI version major, minor and patch numbers */ |
| 28 | #define SOF_ABI_MAJOR 3 | 28 | #define SOF_ABI_MAJOR 3 |
| 29 | #define SOF_ABI_MINOR 6 | 29 | #define SOF_ABI_MINOR 8 |
| 30 | #define SOF_ABI_PATCH 0 | 30 | #define SOF_ABI_PATCH 0 |
| 31 | 31 | ||
| 32 | /* SOF ABI version number. Format within 32bit word is MMmmmppp */ | 32 | /* SOF ABI version number. Format within 32bit word is MMmmmppp */ |
| @@ -1,172 +0,0 @@ | |||
| 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 | |||
| 53 | struct 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 | |||
| 64 | struct 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 | |||
| 124 | struct 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 | |||
| 135 | struct 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 | |||
| 145 | struct 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 | ||
| @@ -1,188 +0,0 @@ | |||
| 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 | |||
| 22 | struct 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 | |||
| 37 | union 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 | */ | ||
| 56 | struct 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 | */ | ||
| 74 | struct 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 | */ | ||
| 92 | struct 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 | */ | ||
| 119 | struct 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 | */ | ||
| 142 | struct 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 | */ | ||
| 160 | struct 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 | */ | ||
| 172 | struct 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 | */ | ||
| 183 | struct sof_man_module_manifest { | ||
| 184 | struct sof_man_module module; | ||
| 185 | uint32_t text_size; | ||
| 186 | } __packed; | ||
| 187 | |||
| 188 | #endif | ||
| @@ -85,6 +85,7 @@ · 84 unmodified lines | |||
| 85 | #define SOF_TKN_INTEL_DMIC_NUM_PDM_ACTIVE 605 | 85 | #define SOF_TKN_INTEL_DMIC_NUM_PDM_ACTIVE 605 |
| 86 | #define SOF_TKN_INTEL_DMIC_SAMPLE_RATE 608 | 86 | #define SOF_TKN_INTEL_DMIC_SAMPLE_RATE 608 |
| 87 | #define SOF_TKN_INTEL_DMIC_FIFO_WORD_LENGTH 609 | 87 | #define SOF_TKN_INTEL_DMIC_FIFO_WORD_LENGTH 609 |
| 88 | #define SOF_TKN_INTEL_DMIC_UNMUTE_RAMP_TIME_MS 610 | ||
| 88 | 89 | ||
| 89 | /* DMIC PDM */ | 90 | /* DMIC PDM */ |
| 90 | #define SOF_TKN_INTEL_DMIC_PDM_CTRL_ID 700 | 91 | #define SOF_TKN_INTEL_DMIC_PDM_CTRL_ID 700 |
| @@ -1,21 +0,0 @@ | |||
| 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 | ||
| @@ -1,66 +0,0 @@ | |||
| 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 | */ | ||
| 22 | struct 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 | */ | ||
| 36 | struct 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 | */ | ||
| 45 | struct 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 | */ | ||
| 57 | struct 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 | ||