mirror of
https://github.com/MiSTer-devel/Linux-Kernel_MiSTer.git
synced 2026-04-19 03:04:24 +00:00
v5.15.1
This commit is contained in:
@@ -225,7 +225,14 @@ struct binder_freeze_info {
|
||||
|
||||
struct binder_frozen_status_info {
|
||||
__u32 pid;
|
||||
|
||||
/* process received sync transactions since last frozen
|
||||
* bit 0: received sync transaction after being frozen
|
||||
* bit 1: new pending sync transaction during freezing
|
||||
*/
|
||||
__u32 sync_recv;
|
||||
|
||||
/* process received async transactions since last frozen */
|
||||
__u32 async_recv;
|
||||
};
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ struct bpf_lpm_trie_key {
|
||||
|
||||
struct bpf_cgroup_storage_key {
|
||||
__u64 cgroup_inode_id; /* cgroup inode id */
|
||||
__u32 attach_type; /* program attach type */
|
||||
__u32 attach_type; /* program attach type (enum bpf_attach_type) */
|
||||
};
|
||||
|
||||
union bpf_iter_link_info {
|
||||
@@ -324,9 +324,6 @@ union bpf_iter_link_info {
|
||||
* **BPF_PROG_TYPE_SK_LOOKUP**
|
||||
* *data_in* and *data_out* must be NULL.
|
||||
*
|
||||
* **BPF_PROG_TYPE_XDP**
|
||||
* *ctx_in* and *ctx_out* must be NULL.
|
||||
*
|
||||
* **BPF_PROG_TYPE_RAW_TRACEPOINT**,
|
||||
* **BPF_PROG_TYPE_RAW_TRACEPOINT_WRITABLE**
|
||||
*
|
||||
@@ -996,6 +993,7 @@ enum bpf_attach_type {
|
||||
BPF_SK_SKB_VERDICT,
|
||||
BPF_SK_REUSEPORT_SELECT,
|
||||
BPF_SK_REUSEPORT_SELECT_OR_MIGRATE,
|
||||
BPF_PERF_EVENT,
|
||||
__MAX_BPF_ATTACH_TYPE
|
||||
};
|
||||
|
||||
@@ -1009,6 +1007,7 @@ enum bpf_link_type {
|
||||
BPF_LINK_TYPE_ITER = 4,
|
||||
BPF_LINK_TYPE_NETNS = 5,
|
||||
BPF_LINK_TYPE_XDP = 6,
|
||||
BPF_LINK_TYPE_PERF_EVENT = 7,
|
||||
|
||||
MAX_BPF_LINK_TYPE,
|
||||
};
|
||||
@@ -1449,6 +1448,13 @@ union bpf_attr {
|
||||
__aligned_u64 iter_info; /* extra bpf_iter_link_info */
|
||||
__u32 iter_info_len; /* iter_info length */
|
||||
};
|
||||
struct {
|
||||
/* black box user-provided value passed through
|
||||
* to BPF program at the execution time and
|
||||
* accessible through bpf_get_attach_cookie() BPF helper
|
||||
*/
|
||||
__u64 bpf_cookie;
|
||||
} perf_event;
|
||||
};
|
||||
} link_create;
|
||||
|
||||
@@ -4780,6 +4786,97 @@ union bpf_attr {
|
||||
* Execute close syscall for given FD.
|
||||
* Return
|
||||
* A syscall result.
|
||||
*
|
||||
* long bpf_timer_init(struct bpf_timer *timer, struct bpf_map *map, u64 flags)
|
||||
* Description
|
||||
* Initialize the timer.
|
||||
* First 4 bits of *flags* specify clockid.
|
||||
* Only CLOCK_MONOTONIC, CLOCK_REALTIME, CLOCK_BOOTTIME are allowed.
|
||||
* All other bits of *flags* are reserved.
|
||||
* The verifier will reject the program if *timer* is not from
|
||||
* the same *map*.
|
||||
* Return
|
||||
* 0 on success.
|
||||
* **-EBUSY** if *timer* is already initialized.
|
||||
* **-EINVAL** if invalid *flags* are passed.
|
||||
* **-EPERM** if *timer* is in a map that doesn't have any user references.
|
||||
* The user space should either hold a file descriptor to a map with timers
|
||||
* or pin such map in bpffs. When map is unpinned or file descriptor is
|
||||
* closed all timers in the map will be cancelled and freed.
|
||||
*
|
||||
* long bpf_timer_set_callback(struct bpf_timer *timer, void *callback_fn)
|
||||
* Description
|
||||
* Configure the timer to call *callback_fn* static function.
|
||||
* Return
|
||||
* 0 on success.
|
||||
* **-EINVAL** if *timer* was not initialized with bpf_timer_init() earlier.
|
||||
* **-EPERM** if *timer* is in a map that doesn't have any user references.
|
||||
* The user space should either hold a file descriptor to a map with timers
|
||||
* or pin such map in bpffs. When map is unpinned or file descriptor is
|
||||
* closed all timers in the map will be cancelled and freed.
|
||||
*
|
||||
* long bpf_timer_start(struct bpf_timer *timer, u64 nsecs, u64 flags)
|
||||
* Description
|
||||
* Set timer expiration N nanoseconds from the current time. The
|
||||
* configured callback will be invoked in soft irq context on some cpu
|
||||
* and will not repeat unless another bpf_timer_start() is made.
|
||||
* In such case the next invocation can migrate to a different cpu.
|
||||
* Since struct bpf_timer is a field inside map element the map
|
||||
* owns the timer. The bpf_timer_set_callback() will increment refcnt
|
||||
* of BPF program to make sure that callback_fn code stays valid.
|
||||
* When user space reference to a map reaches zero all timers
|
||||
* in a map are cancelled and corresponding program's refcnts are
|
||||
* decremented. This is done to make sure that Ctrl-C of a user
|
||||
* process doesn't leave any timers running. If map is pinned in
|
||||
* bpffs the callback_fn can re-arm itself indefinitely.
|
||||
* bpf_map_update/delete_elem() helpers and user space sys_bpf commands
|
||||
* cancel and free the timer in the given map element.
|
||||
* The map can contain timers that invoke callback_fn-s from different
|
||||
* programs. The same callback_fn can serve different timers from
|
||||
* different maps if key/value layout matches across maps.
|
||||
* Every bpf_timer_set_callback() can have different callback_fn.
|
||||
*
|
||||
* Return
|
||||
* 0 on success.
|
||||
* **-EINVAL** if *timer* was not initialized with bpf_timer_init() earlier
|
||||
* or invalid *flags* are passed.
|
||||
*
|
||||
* long bpf_timer_cancel(struct bpf_timer *timer)
|
||||
* Description
|
||||
* Cancel the timer and wait for callback_fn to finish if it was running.
|
||||
* Return
|
||||
* 0 if the timer was not active.
|
||||
* 1 if the timer was active.
|
||||
* **-EINVAL** if *timer* was not initialized with bpf_timer_init() earlier.
|
||||
* **-EDEADLK** if callback_fn tried to call bpf_timer_cancel() on its
|
||||
* own timer which would have led to a deadlock otherwise.
|
||||
*
|
||||
* u64 bpf_get_func_ip(void *ctx)
|
||||
* Description
|
||||
* Get address of the traced function (for tracing and kprobe programs).
|
||||
* Return
|
||||
* Address of the traced function.
|
||||
*
|
||||
* u64 bpf_get_attach_cookie(void *ctx)
|
||||
* Description
|
||||
* Get bpf_cookie value provided (optionally) during the program
|
||||
* attachment. It might be different for each individual
|
||||
* attachment, even if BPF program itself is the same.
|
||||
* Expects BPF program context *ctx* as a first argument.
|
||||
*
|
||||
* Supported for the following program types:
|
||||
* - kprobe/uprobe;
|
||||
* - tracepoint;
|
||||
* - perf_event.
|
||||
* Return
|
||||
* Value specified by user at BPF link creation/attachment time
|
||||
* or 0, if it was not specified.
|
||||
*
|
||||
* long bpf_task_pt_regs(struct task_struct *task)
|
||||
* Description
|
||||
* Get the struct pt_regs associated with **task**.
|
||||
* Return
|
||||
* A pointer to struct pt_regs.
|
||||
*/
|
||||
#define __BPF_FUNC_MAPPER(FN) \
|
||||
FN(unspec), \
|
||||
@@ -4951,6 +5048,13 @@ union bpf_attr {
|
||||
FN(sys_bpf), \
|
||||
FN(btf_find_by_name_kind), \
|
||||
FN(sys_close), \
|
||||
FN(timer_init), \
|
||||
FN(timer_set_callback), \
|
||||
FN(timer_start), \
|
||||
FN(timer_cancel), \
|
||||
FN(get_func_ip), \
|
||||
FN(get_attach_cookie), \
|
||||
FN(task_pt_regs), \
|
||||
/* */
|
||||
|
||||
/* integer value in 'imm' field of BPF_CALL instruction selects which helper
|
||||
@@ -6077,6 +6181,11 @@ struct bpf_spin_lock {
|
||||
__u32 val;
|
||||
};
|
||||
|
||||
struct bpf_timer {
|
||||
__u64 :64;
|
||||
__u64 :64;
|
||||
} __attribute__((aligned(8)));
|
||||
|
||||
struct bpf_sysctl {
|
||||
__u32 write; /* Sysctl is being read (= 0) or written (= 1).
|
||||
* Allows 1,2,4-byte read, but no write.
|
||||
|
||||
@@ -288,6 +288,7 @@ struct btrfs_ioctl_fs_info_args {
|
||||
* first mount when booting older kernel versions.
|
||||
*/
|
||||
#define BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE_VALID (1ULL << 1)
|
||||
#define BTRFS_FEATURE_COMPAT_RO_VERITY (1ULL << 2)
|
||||
|
||||
#define BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF (1ULL << 0)
|
||||
#define BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL (1ULL << 1)
|
||||
|
||||
@@ -118,6 +118,29 @@
|
||||
#define BTRFS_INODE_REF_KEY 12
|
||||
#define BTRFS_INODE_EXTREF_KEY 13
|
||||
#define BTRFS_XATTR_ITEM_KEY 24
|
||||
|
||||
/*
|
||||
* fs verity items are stored under two different key types on disk.
|
||||
* The descriptor items:
|
||||
* [ inode objectid, BTRFS_VERITY_DESC_ITEM_KEY, offset ]
|
||||
*
|
||||
* At offset 0, we store a btrfs_verity_descriptor_item which tracks the size
|
||||
* of the descriptor item and some extra data for encryption.
|
||||
* Starting at offset 1, these hold the generic fs verity descriptor. The
|
||||
* latter are opaque to btrfs, we just read and write them as a blob for the
|
||||
* higher level verity code. The most common descriptor size is 256 bytes.
|
||||
*
|
||||
* The merkle tree items:
|
||||
* [ inode objectid, BTRFS_VERITY_MERKLE_ITEM_KEY, offset ]
|
||||
*
|
||||
* These also start at offset 0, and correspond to the merkle tree bytes. When
|
||||
* fsverity asks for page 0 of the merkle tree, we pull up one page starting at
|
||||
* offset 0 for this key type. These are also opaque to btrfs, we're blindly
|
||||
* storing whatever fsverity sends down.
|
||||
*/
|
||||
#define BTRFS_VERITY_DESC_ITEM_KEY 36
|
||||
#define BTRFS_VERITY_MERKLE_ITEM_KEY 37
|
||||
|
||||
#define BTRFS_ORPHAN_ITEM_KEY 48
|
||||
/* reserve 2-15 close to the inode for later flexibility */
|
||||
|
||||
@@ -991,4 +1014,16 @@ struct btrfs_qgroup_limit_item {
|
||||
__le64 rsv_excl;
|
||||
} __attribute__ ((__packed__));
|
||||
|
||||
struct btrfs_verity_descriptor_item {
|
||||
/* Size of the verity descriptor in bytes */
|
||||
__le64 size;
|
||||
/*
|
||||
* When we implement support for fscrypt, we will need to encrypt the
|
||||
* Merkle tree for encrypted verity files. These 128 bits are for the
|
||||
* eventual storage of an fscrypt initialization vector.
|
||||
*/
|
||||
__le64 reserved[2];
|
||||
__u8 encryption;
|
||||
} __attribute__ ((__packed__));
|
||||
|
||||
#endif /* _BTRFS_CTREE_H_ */
|
||||
|
||||
@@ -78,11 +78,20 @@ enum {
|
||||
enum {
|
||||
J1939_NLA_PAD,
|
||||
J1939_NLA_BYTES_ACKED,
|
||||
J1939_NLA_TOTAL_SIZE,
|
||||
J1939_NLA_PGN,
|
||||
J1939_NLA_SRC_NAME,
|
||||
J1939_NLA_DEST_NAME,
|
||||
J1939_NLA_SRC_ADDR,
|
||||
J1939_NLA_DEST_ADDR,
|
||||
};
|
||||
|
||||
enum {
|
||||
J1939_EE_INFO_NONE,
|
||||
J1939_EE_INFO_TX_ABORT,
|
||||
J1939_EE_INFO_RX_RTS,
|
||||
J1939_EE_INFO_RX_DPO,
|
||||
J1939_EE_INFO_RX_ABORT,
|
||||
};
|
||||
|
||||
struct j1939_filter {
|
||||
|
||||
@@ -243,7 +243,6 @@ struct vfs_ns_cap_data {
|
||||
/* Allow examination and configuration of disk quotas */
|
||||
/* Allow setting the domainname */
|
||||
/* Allow setting the hostname */
|
||||
/* Allow calling bdflush() */
|
||||
/* Allow mount() and umount(), setting up new smb connection */
|
||||
/* Allow some autofs root ioctls */
|
||||
/* Allow nfsservctl */
|
||||
|
||||
@@ -642,7 +642,7 @@ struct cec_event {
|
||||
#define CEC_OP_REC_SEQ_WEDNESDAY 0x08
|
||||
#define CEC_OP_REC_SEQ_THURSDAY 0x10
|
||||
#define CEC_OP_REC_SEQ_FRIDAY 0x20
|
||||
#define CEC_OP_REC_SEQ_SATERDAY 0x40
|
||||
#define CEC_OP_REC_SEQ_SATURDAY 0x40
|
||||
#define CEC_OP_REC_SEQ_ONCE_ONLY 0x00
|
||||
|
||||
#define CEC_MSG_CLEAR_DIGITAL_TIMER 0x99
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1+ WITH Linux-syscall-note */
|
||||
/*
|
||||
* include/uapi/linux/cifs/cifs_mount.h
|
||||
*
|
||||
* Author(s): Scott Lovenberg (scott.lovenberg@gmail.com)
|
||||
*
|
||||
|
||||
@@ -50,7 +50,7 @@ enum { CXL_CMDS };
|
||||
#define ___C(a, b) { b }
|
||||
static const struct {
|
||||
const char *name;
|
||||
} cxl_command_names[] = { CXL_CMDS };
|
||||
} cxl_command_names[] __attribute__((__unused__)) = { CXL_CMDS };
|
||||
|
||||
/*
|
||||
* Here's how this actually breaks out:
|
||||
|
||||
@@ -376,4 +376,10 @@ enum {
|
||||
*/
|
||||
#define DM_INTERNAL_SUSPEND_FLAG (1 << 18) /* Out */
|
||||
|
||||
/*
|
||||
* If set, returns in the in buffer passed by UM, the raw table information
|
||||
* that would be measured by IMA subsystem on device state change.
|
||||
*/
|
||||
#define DM_IMA_MEASUREMENT_FLAG (1 << 19) /* In */
|
||||
|
||||
#endif /* _LINUX_DM_IOCTL_H */
|
||||
|
||||
@@ -22,8 +22,56 @@
|
||||
|
||||
#include <linux/types.h>
|
||||
|
||||
/* begin/end dma-buf functions used for userspace mmap. */
|
||||
/**
|
||||
* struct dma_buf_sync - Synchronize with CPU access.
|
||||
*
|
||||
* When a DMA buffer is accessed from the CPU via mmap, it is not always
|
||||
* possible to guarantee coherency between the CPU-visible map and underlying
|
||||
* memory. To manage coherency, DMA_BUF_IOCTL_SYNC must be used to bracket
|
||||
* any CPU access to give the kernel the chance to shuffle memory around if
|
||||
* needed.
|
||||
*
|
||||
* Prior to accessing the map, the client must call DMA_BUF_IOCTL_SYNC
|
||||
* with DMA_BUF_SYNC_START and the appropriate read/write flags. Once the
|
||||
* access is complete, the client should call DMA_BUF_IOCTL_SYNC with
|
||||
* DMA_BUF_SYNC_END and the same read/write flags.
|
||||
*
|
||||
* The synchronization provided via DMA_BUF_IOCTL_SYNC only provides cache
|
||||
* coherency. It does not prevent other processes or devices from
|
||||
* accessing the memory at the same time. If synchronization with a GPU or
|
||||
* other device driver is required, it is the client's responsibility to
|
||||
* wait for buffer to be ready for reading or writing before calling this
|
||||
* ioctl with DMA_BUF_SYNC_START. Likewise, the client must ensure that
|
||||
* follow-up work is not submitted to GPU or other device driver until
|
||||
* after this ioctl has been called with DMA_BUF_SYNC_END?
|
||||
*
|
||||
* If the driver or API with which the client is interacting uses implicit
|
||||
* synchronization, waiting for prior work to complete can be done via
|
||||
* poll() on the DMA buffer file descriptor. If the driver or API requires
|
||||
* explicit synchronization, the client may have to wait on a sync_file or
|
||||
* other synchronization primitive outside the scope of the DMA buffer API.
|
||||
*/
|
||||
struct dma_buf_sync {
|
||||
/**
|
||||
* @flags: Set of access flags
|
||||
*
|
||||
* DMA_BUF_SYNC_START:
|
||||
* Indicates the start of a map access session.
|
||||
*
|
||||
* DMA_BUF_SYNC_END:
|
||||
* Indicates the end of a map access session.
|
||||
*
|
||||
* DMA_BUF_SYNC_READ:
|
||||
* Indicates that the mapped DMA buffer will be read by the
|
||||
* client via the CPU map.
|
||||
*
|
||||
* DMA_BUF_SYNC_WRITE:
|
||||
* Indicates that the mapped DMA buffer will be written by the
|
||||
* client via the CPU map.
|
||||
*
|
||||
* DMA_BUF_SYNC_RW:
|
||||
* An alias for DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE.
|
||||
*/
|
||||
__u64 flags;
|
||||
};
|
||||
|
||||
|
||||
@@ -639,6 +639,8 @@ enum ethtool_link_ext_substate_link_logical_mismatch {
|
||||
enum ethtool_link_ext_substate_bad_signal_integrity {
|
||||
ETHTOOL_LINK_EXT_SUBSTATE_BSI_LARGE_NUMBER_OF_PHYSICAL_ERRORS = 1,
|
||||
ETHTOOL_LINK_EXT_SUBSTATE_BSI_UNSUPPORTED_RATE,
|
||||
ETHTOOL_LINK_EXT_SUBSTATE_BSI_SERDES_REFERENCE_CLOCK_LOST,
|
||||
ETHTOOL_LINK_EXT_SUBSTATE_BSI_SERDES_ALOS,
|
||||
};
|
||||
|
||||
/* More information in addition to ETHTOOL_LINK_EXT_STATE_CABLE_ISSUE. */
|
||||
|
||||
@@ -377,6 +377,8 @@ enum {
|
||||
ETHTOOL_A_COALESCE_TX_USECS_HIGH, /* u32 */
|
||||
ETHTOOL_A_COALESCE_TX_MAX_FRAMES_HIGH, /* u32 */
|
||||
ETHTOOL_A_COALESCE_RATE_SAMPLE_INTERVAL, /* u32 */
|
||||
ETHTOOL_A_COALESCE_USE_CQE_MODE_TX, /* u8 */
|
||||
ETHTOOL_A_COALESCE_USE_CQE_MODE_RX, /* u8 */
|
||||
|
||||
/* add new constants above here */
|
||||
__ETHTOOL_A_COALESCE_CNT,
|
||||
|
||||
@@ -51,6 +51,7 @@
|
||||
#define FAN_ENABLE_AUDIT 0x00000040
|
||||
|
||||
/* Flags to determine fanotify event format */
|
||||
#define FAN_REPORT_PIDFD 0x00000080 /* Report pidfd for event->pid */
|
||||
#define FAN_REPORT_TID 0x00000100 /* event->pid is thread id */
|
||||
#define FAN_REPORT_FID 0x00000200 /* Report unique file id */
|
||||
#define FAN_REPORT_DIR_FID 0x00000400 /* Report unique directory id */
|
||||
@@ -123,6 +124,7 @@ struct fanotify_event_metadata {
|
||||
#define FAN_EVENT_INFO_TYPE_FID 1
|
||||
#define FAN_EVENT_INFO_TYPE_DFID_NAME 2
|
||||
#define FAN_EVENT_INFO_TYPE_DFID 3
|
||||
#define FAN_EVENT_INFO_TYPE_PIDFD 4
|
||||
|
||||
/* Variable length info record following event metadata */
|
||||
struct fanotify_event_info_header {
|
||||
@@ -148,6 +150,15 @@ struct fanotify_event_info_fid {
|
||||
unsigned char handle[0];
|
||||
};
|
||||
|
||||
/*
|
||||
* This structure is used for info records of type FAN_EVENT_INFO_TYPE_PIDFD.
|
||||
* It holds a pidfd for the pid that was responsible for generating an event.
|
||||
*/
|
||||
struct fanotify_event_info_pidfd {
|
||||
struct fanotify_event_info_header hdr;
|
||||
__s32 pidfd;
|
||||
};
|
||||
|
||||
struct fanotify_response {
|
||||
__s32 fd;
|
||||
__u32 response;
|
||||
@@ -160,6 +171,8 @@ struct fanotify_response {
|
||||
|
||||
/* No fd set in event */
|
||||
#define FAN_NOFD -1
|
||||
#define FAN_NOPIDFD FAN_NOFD
|
||||
#define FAN_EPIDFD -2
|
||||
|
||||
/* Helper functions to deal with fanotify_event_metadata buffers */
|
||||
#define FAN_EVENT_METADATA_LEN (sizeof(struct fanotify_event_metadata))
|
||||
|
||||
@@ -184,6 +184,7 @@ struct fsxattr {
|
||||
#define BLKSECDISCARD _IO(0x12,125)
|
||||
#define BLKROTATIONAL _IO(0x12,126)
|
||||
#define BLKZEROOUT _IO(0x12,127)
|
||||
#define BLKGETDISKSEQ _IOR(0x12,128,__u64)
|
||||
/*
|
||||
* A jump here: 130-136 are reserved for zoned block devices
|
||||
* (see uapi/linux/blkzoned.h)
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
#ifndef _UAPI_HYPERV_H
|
||||
#define _UAPI_HYPERV_H
|
||||
|
||||
#include <linux/uuid.h>
|
||||
#include <linux/types.h>
|
||||
|
||||
/*
|
||||
* Framework version for util services.
|
||||
|
||||
@@ -9,6 +9,30 @@
|
||||
#include <stdint.h>
|
||||
#endif
|
||||
|
||||
/* Driver command error status */
|
||||
enum idxd_scmd_stat {
|
||||
IDXD_SCMD_DEV_ENABLED = 0x80000010,
|
||||
IDXD_SCMD_DEV_NOT_ENABLED = 0x80000020,
|
||||
IDXD_SCMD_WQ_ENABLED = 0x80000021,
|
||||
IDXD_SCMD_DEV_DMA_ERR = 0x80020000,
|
||||
IDXD_SCMD_WQ_NO_GRP = 0x80030000,
|
||||
IDXD_SCMD_WQ_NO_NAME = 0x80040000,
|
||||
IDXD_SCMD_WQ_NO_SVM = 0x80050000,
|
||||
IDXD_SCMD_WQ_NO_THRESH = 0x80060000,
|
||||
IDXD_SCMD_WQ_PORTAL_ERR = 0x80070000,
|
||||
IDXD_SCMD_WQ_RES_ALLOC_ERR = 0x80080000,
|
||||
IDXD_SCMD_PERCPU_ERR = 0x80090000,
|
||||
IDXD_SCMD_DMA_CHAN_ERR = 0x800a0000,
|
||||
IDXD_SCMD_CDEV_ERR = 0x800b0000,
|
||||
IDXD_SCMD_WQ_NO_SWQ_SUPPORT = 0x800c0000,
|
||||
IDXD_SCMD_WQ_NONE_CONFIGURED = 0x800d0000,
|
||||
IDXD_SCMD_WQ_NO_SIZE = 0x800e0000,
|
||||
IDXD_SCMD_WQ_NO_PRIV = 0x800f0000,
|
||||
};
|
||||
|
||||
#define IDXD_SCMD_SOFTERR_MASK 0x80000000
|
||||
#define IDXD_SCMD_SOFTERR_SHIFT 16
|
||||
|
||||
/* Descriptor flags */
|
||||
#define IDXD_OP_FLAG_FENCE 0x0001
|
||||
#define IDXD_OP_FLAG_BOF 0x0002
|
||||
|
||||
@@ -54,6 +54,7 @@
|
||||
#define ARPHRD_X25 271 /* CCITT X.25 */
|
||||
#define ARPHRD_HWX25 272 /* Boards with X.25 in firmware */
|
||||
#define ARPHRD_CAN 280 /* Controller Area Network */
|
||||
#define ARPHRD_MCTP 290
|
||||
#define ARPHRD_PPP 512
|
||||
#define ARPHRD_CISCO 513 /* Cisco HDLC */
|
||||
#define ARPHRD_HDLC ARPHRD_CISCO
|
||||
|
||||
@@ -479,16 +479,22 @@ enum {
|
||||
|
||||
/* flags used in BRIDGE_VLANDB_DUMP_FLAGS attribute to affect dumps */
|
||||
#define BRIDGE_VLANDB_DUMPF_STATS (1 << 0) /* Include stats in the dump */
|
||||
#define BRIDGE_VLANDB_DUMPF_GLOBAL (1 << 1) /* Dump global vlan options only */
|
||||
|
||||
/* Bridge vlan RTM attributes
|
||||
* [BRIDGE_VLANDB_ENTRY] = {
|
||||
* [BRIDGE_VLANDB_ENTRY_INFO]
|
||||
* ...
|
||||
* }
|
||||
* [BRIDGE_VLANDB_GLOBAL_OPTIONS] = {
|
||||
* [BRIDGE_VLANDB_GOPTS_ID]
|
||||
* ...
|
||||
* }
|
||||
*/
|
||||
enum {
|
||||
BRIDGE_VLANDB_UNSPEC,
|
||||
BRIDGE_VLANDB_ENTRY,
|
||||
BRIDGE_VLANDB_GLOBAL_OPTIONS,
|
||||
__BRIDGE_VLANDB_MAX,
|
||||
};
|
||||
#define BRIDGE_VLANDB_MAX (__BRIDGE_VLANDB_MAX - 1)
|
||||
@@ -500,6 +506,7 @@ enum {
|
||||
BRIDGE_VLANDB_ENTRY_STATE,
|
||||
BRIDGE_VLANDB_ENTRY_TUNNEL_INFO,
|
||||
BRIDGE_VLANDB_ENTRY_STATS,
|
||||
BRIDGE_VLANDB_ENTRY_MCAST_ROUTER,
|
||||
__BRIDGE_VLANDB_ENTRY_MAX,
|
||||
};
|
||||
#define BRIDGE_VLANDB_ENTRY_MAX (__BRIDGE_VLANDB_ENTRY_MAX - 1)
|
||||
@@ -538,6 +545,29 @@ enum {
|
||||
};
|
||||
#define BRIDGE_VLANDB_STATS_MAX (__BRIDGE_VLANDB_STATS_MAX - 1)
|
||||
|
||||
enum {
|
||||
BRIDGE_VLANDB_GOPTS_UNSPEC,
|
||||
BRIDGE_VLANDB_GOPTS_ID,
|
||||
BRIDGE_VLANDB_GOPTS_RANGE,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_SNOOPING,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_IGMP_VERSION,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_MLD_VERSION,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_LAST_MEMBER_CNT,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_STARTUP_QUERY_CNT,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_LAST_MEMBER_INTVL,
|
||||
BRIDGE_VLANDB_GOPTS_PAD,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_MEMBERSHIP_INTVL,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_QUERIER_INTVL,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_QUERY_INTVL,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_QUERY_RESPONSE_INTVL,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_STARTUP_QUERY_INTVL,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_QUERIER,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_ROUTER_PORTS,
|
||||
BRIDGE_VLANDB_GOPTS_MCAST_QUERIER_STATE,
|
||||
__BRIDGE_VLANDB_GOPTS_MAX
|
||||
};
|
||||
#define BRIDGE_VLANDB_GOPTS_MAX (__BRIDGE_VLANDB_GOPTS_MAX - 1)
|
||||
|
||||
/* Bridge multicast database attributes
|
||||
* [MDBA_MDB] = {
|
||||
* [MDBA_MDB_ENTRY] = {
|
||||
@@ -629,6 +659,7 @@ enum {
|
||||
MDBA_ROUTER_PATTR_TYPE,
|
||||
MDBA_ROUTER_PATTR_INET_TIMER,
|
||||
MDBA_ROUTER_PATTR_INET6_TIMER,
|
||||
MDBA_ROUTER_PATTR_VID,
|
||||
__MDBA_ROUTER_PATTR_MAX
|
||||
};
|
||||
#define MDBA_ROUTER_PATTR_MAX (__MDBA_ROUTER_PATTR_MAX - 1)
|
||||
@@ -720,12 +751,14 @@ struct br_mcast_stats {
|
||||
|
||||
/* bridge boolean options
|
||||
* BR_BOOLOPT_NO_LL_LEARN - disable learning from link-local packets
|
||||
* BR_BOOLOPT_MCAST_VLAN_SNOOPING - control vlan multicast snooping
|
||||
*
|
||||
* IMPORTANT: if adding a new option do not forget to handle
|
||||
* it in br_boolopt_toggle/get and bridge sysfs
|
||||
*/
|
||||
enum br_boolopt_id {
|
||||
BR_BOOLOPT_NO_LL_LEARN,
|
||||
BR_BOOLOPT_MCAST_VLAN_SNOOPING,
|
||||
BR_BOOLOPT_MAX
|
||||
};
|
||||
|
||||
@@ -738,4 +771,17 @@ struct br_boolopt_multi {
|
||||
__u32 optval;
|
||||
__u32 optmask;
|
||||
};
|
||||
|
||||
enum {
|
||||
BRIDGE_QUERIER_UNSPEC,
|
||||
BRIDGE_QUERIER_IP_ADDRESS,
|
||||
BRIDGE_QUERIER_IP_PORT,
|
||||
BRIDGE_QUERIER_IP_OTHER_TIMER,
|
||||
BRIDGE_QUERIER_PAD,
|
||||
BRIDGE_QUERIER_IPV6_ADDRESS,
|
||||
BRIDGE_QUERIER_IPV6_PORT,
|
||||
BRIDGE_QUERIER_IPV6_OTHER_TIMER,
|
||||
__BRIDGE_QUERIER_MAX
|
||||
};
|
||||
#define BRIDGE_QUERIER_MAX (__BRIDGE_QUERIER_MAX - 1)
|
||||
#endif /* _UAPI_LINUX_IF_BRIDGE_H */
|
||||
|
||||
@@ -151,6 +151,9 @@
|
||||
#define ETH_P_MAP 0x00F9 /* Qualcomm multiplexing and
|
||||
* aggregation protocol
|
||||
*/
|
||||
#define ETH_P_MCTP 0x00FA /* Management component transport
|
||||
* protocol packets
|
||||
*/
|
||||
|
||||
/*
|
||||
* This is an Ethernet frame header.
|
||||
|
||||
@@ -417,6 +417,7 @@ enum {
|
||||
IFLA_INET6_ICMP6STATS, /* statistics (icmpv6) */
|
||||
IFLA_INET6_TOKEN, /* device token */
|
||||
IFLA_INET6_ADDR_GEN_MODE, /* implicit address generator mode */
|
||||
IFLA_INET6_RA_MTU, /* mtu carried in the RA message */
|
||||
__IFLA_INET6_MAX
|
||||
};
|
||||
|
||||
@@ -479,6 +480,7 @@ enum {
|
||||
IFLA_BR_MCAST_MLD_VERSION,
|
||||
IFLA_BR_VLAN_STATS_PER_PORT,
|
||||
IFLA_BR_MULTI_BOOLOPT,
|
||||
IFLA_BR_MCAST_QUERIER_STATE,
|
||||
__IFLA_BR_MAX,
|
||||
};
|
||||
|
||||
@@ -855,6 +857,7 @@ enum {
|
||||
IFLA_BOND_AD_ACTOR_SYSTEM,
|
||||
IFLA_BOND_TLB_DYNAMIC_LB,
|
||||
IFLA_BOND_PEER_NOTIF_DELAY,
|
||||
IFLA_BOND_AD_LACP_ACTIVE,
|
||||
__IFLA_BOND_MAX,
|
||||
};
|
||||
|
||||
@@ -1260,4 +1263,14 @@ struct ifla_rmnet_flags {
|
||||
__u32 mask;
|
||||
};
|
||||
|
||||
/* MCTP section */
|
||||
|
||||
enum {
|
||||
IFLA_MCTP_UNSPEC,
|
||||
IFLA_MCTP_NET,
|
||||
__IFLA_MCTP_MAX,
|
||||
};
|
||||
|
||||
#define IFLA_MCTP_MAX (__IFLA_MCTP_MAX - 1)
|
||||
|
||||
#endif /* _UAPI_LINUX_IF_LINK_H */
|
||||
|
||||
@@ -188,11 +188,22 @@ struct ip_mreq_source {
|
||||
};
|
||||
|
||||
struct ip_msfilter {
|
||||
__be32 imsf_multiaddr;
|
||||
__be32 imsf_interface;
|
||||
__u32 imsf_fmode;
|
||||
__u32 imsf_numsrc;
|
||||
__be32 imsf_slist[1];
|
||||
union {
|
||||
struct {
|
||||
__be32 imsf_multiaddr_aux;
|
||||
__be32 imsf_interface_aux;
|
||||
__u32 imsf_fmode_aux;
|
||||
__u32 imsf_numsrc_aux;
|
||||
__be32 imsf_slist[1];
|
||||
};
|
||||
struct {
|
||||
__be32 imsf_multiaddr;
|
||||
__be32 imsf_interface;
|
||||
__u32 imsf_fmode;
|
||||
__u32 imsf_numsrc;
|
||||
__be32 imsf_slist_flex[];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
#define IP_MSFILTER_SIZE(numsrc) \
|
||||
@@ -211,11 +222,22 @@ struct group_source_req {
|
||||
};
|
||||
|
||||
struct group_filter {
|
||||
__u32 gf_interface; /* interface index */
|
||||
struct __kernel_sockaddr_storage gf_group; /* multicast address */
|
||||
__u32 gf_fmode; /* filter mode */
|
||||
__u32 gf_numsrc; /* number of sources */
|
||||
struct __kernel_sockaddr_storage gf_slist[1]; /* interface index */
|
||||
union {
|
||||
struct {
|
||||
__u32 gf_interface_aux; /* interface index */
|
||||
struct __kernel_sockaddr_storage gf_group_aux; /* multicast address */
|
||||
__u32 gf_fmode_aux; /* filter mode */
|
||||
__u32 gf_numsrc_aux; /* number of sources */
|
||||
struct __kernel_sockaddr_storage gf_slist[1]; /* interface index */
|
||||
};
|
||||
struct {
|
||||
__u32 gf_interface; /* interface index */
|
||||
struct __kernel_sockaddr_storage gf_group; /* multicast address */
|
||||
__u32 gf_fmode; /* filter mode */
|
||||
__u32 gf_numsrc; /* number of sources */
|
||||
struct __kernel_sockaddr_storage gf_slist_flex[]; /* interface index */
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
#define GROUP_FILTER_SIZE(numsrc) \
|
||||
|
||||
@@ -145,6 +145,7 @@ struct in6_flowlabel_req {
|
||||
#define IPV6_TLV_PADN 1
|
||||
#define IPV6_TLV_ROUTERALERT 5
|
||||
#define IPV6_TLV_CALIPSO 7 /* RFC 5570 */
|
||||
#define IPV6_TLV_IOAM 49 /* TEMPORARY IANA allocation for IOAM */
|
||||
#define IPV6_TLV_JUMBO 194
|
||||
#define IPV6_TLV_HAO 201 /* home address option */
|
||||
|
||||
|
||||
@@ -44,6 +44,7 @@ struct io_uring_sqe {
|
||||
__u32 splice_flags;
|
||||
__u32 rename_flags;
|
||||
__u32 unlink_flags;
|
||||
__u32 hardlink_flags;
|
||||
};
|
||||
__u64 user_data; /* data to be passed back at completion time */
|
||||
/* pack this to avoid bogus arm OABI complaints */
|
||||
@@ -55,7 +56,10 @@ struct io_uring_sqe {
|
||||
} __attribute__((packed));
|
||||
/* personality to use, if used */
|
||||
__u16 personality;
|
||||
__s32 splice_fd_in;
|
||||
union {
|
||||
__s32 splice_fd_in;
|
||||
__u32 file_index;
|
||||
};
|
||||
__u64 __pad2[2];
|
||||
};
|
||||
|
||||
@@ -133,6 +137,9 @@ enum {
|
||||
IORING_OP_SHUTDOWN,
|
||||
IORING_OP_RENAMEAT,
|
||||
IORING_OP_UNLINKAT,
|
||||
IORING_OP_MKDIRAT,
|
||||
IORING_OP_SYMLINKAT,
|
||||
IORING_OP_LINKAT,
|
||||
|
||||
/* this goes last, obviously */
|
||||
IORING_OP_LAST,
|
||||
@@ -146,9 +153,13 @@ enum {
|
||||
/*
|
||||
* sqe->timeout_flags
|
||||
*/
|
||||
#define IORING_TIMEOUT_ABS (1U << 0)
|
||||
#define IORING_TIMEOUT_UPDATE (1U << 1)
|
||||
|
||||
#define IORING_TIMEOUT_ABS (1U << 0)
|
||||
#define IORING_TIMEOUT_UPDATE (1U << 1)
|
||||
#define IORING_TIMEOUT_BOOTTIME (1U << 2)
|
||||
#define IORING_TIMEOUT_REALTIME (1U << 3)
|
||||
#define IORING_LINK_TIMEOUT_UPDATE (1U << 4)
|
||||
#define IORING_TIMEOUT_CLOCK_MASK (IORING_TIMEOUT_BOOTTIME | IORING_TIMEOUT_REALTIME)
|
||||
#define IORING_TIMEOUT_UPDATE_MASK (IORING_TIMEOUT_UPDATE | IORING_LINK_TIMEOUT_UPDATE)
|
||||
/*
|
||||
* sqe->splice_flags
|
||||
* extends splice(2) flags
|
||||
@@ -306,10 +317,19 @@ enum {
|
||||
IORING_REGISTER_IOWQ_AFF = 17,
|
||||
IORING_UNREGISTER_IOWQ_AFF = 18,
|
||||
|
||||
/* set/get max number of io-wq workers */
|
||||
IORING_REGISTER_IOWQ_MAX_WORKERS = 19,
|
||||
|
||||
/* this goes last */
|
||||
IORING_REGISTER_LAST
|
||||
};
|
||||
|
||||
/* io-wq worker categories */
|
||||
enum {
|
||||
IO_WQ_BOUND,
|
||||
IO_WQ_UNBOUND,
|
||||
};
|
||||
|
||||
/* deprecated, see struct io_uring_rsrc_update */
|
||||
struct io_uring_files_update {
|
||||
__u32 offset;
|
||||
|
||||
133
include/uapi/linux/ioam6.h
Normal file
133
include/uapi/linux/ioam6.h
Normal file
@@ -0,0 +1,133 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
|
||||
/*
|
||||
* IPv6 IOAM implementation
|
||||
*
|
||||
* Author:
|
||||
* Justin Iurman <justin.iurman@uliege.be>
|
||||
*/
|
||||
|
||||
#ifndef _UAPI_LINUX_IOAM6_H
|
||||
#define _UAPI_LINUX_IOAM6_H
|
||||
|
||||
#include <asm/byteorder.h>
|
||||
#include <linux/types.h>
|
||||
|
||||
#define IOAM6_U16_UNAVAILABLE U16_MAX
|
||||
#define IOAM6_U32_UNAVAILABLE U32_MAX
|
||||
#define IOAM6_U64_UNAVAILABLE U64_MAX
|
||||
|
||||
#define IOAM6_DEFAULT_ID (IOAM6_U32_UNAVAILABLE >> 8)
|
||||
#define IOAM6_DEFAULT_ID_WIDE (IOAM6_U64_UNAVAILABLE >> 8)
|
||||
#define IOAM6_DEFAULT_IF_ID IOAM6_U16_UNAVAILABLE
|
||||
#define IOAM6_DEFAULT_IF_ID_WIDE IOAM6_U32_UNAVAILABLE
|
||||
|
||||
/*
|
||||
* IPv6 IOAM Option Header
|
||||
*/
|
||||
struct ioam6_hdr {
|
||||
__u8 opt_type;
|
||||
__u8 opt_len;
|
||||
__u8 :8; /* reserved */
|
||||
#define IOAM6_TYPE_PREALLOC 0
|
||||
__u8 type;
|
||||
} __attribute__((packed));
|
||||
|
||||
/*
|
||||
* IOAM Trace Header
|
||||
*/
|
||||
struct ioam6_trace_hdr {
|
||||
__be16 namespace_id;
|
||||
|
||||
#if defined(__LITTLE_ENDIAN_BITFIELD)
|
||||
|
||||
__u8 :1, /* unused */
|
||||
:1, /* unused */
|
||||
overflow:1,
|
||||
nodelen:5;
|
||||
|
||||
__u8 remlen:7,
|
||||
:1; /* unused */
|
||||
|
||||
union {
|
||||
__be32 type_be32;
|
||||
|
||||
struct {
|
||||
__u32 bit7:1,
|
||||
bit6:1,
|
||||
bit5:1,
|
||||
bit4:1,
|
||||
bit3:1,
|
||||
bit2:1,
|
||||
bit1:1,
|
||||
bit0:1,
|
||||
bit15:1, /* unused */
|
||||
bit14:1, /* unused */
|
||||
bit13:1, /* unused */
|
||||
bit12:1, /* unused */
|
||||
bit11:1,
|
||||
bit10:1,
|
||||
bit9:1,
|
||||
bit8:1,
|
||||
bit23:1, /* reserved */
|
||||
bit22:1,
|
||||
bit21:1, /* unused */
|
||||
bit20:1, /* unused */
|
||||
bit19:1, /* unused */
|
||||
bit18:1, /* unused */
|
||||
bit17:1, /* unused */
|
||||
bit16:1, /* unused */
|
||||
:8; /* reserved */
|
||||
} type;
|
||||
};
|
||||
|
||||
#elif defined(__BIG_ENDIAN_BITFIELD)
|
||||
|
||||
__u8 nodelen:5,
|
||||
overflow:1,
|
||||
:1, /* unused */
|
||||
:1; /* unused */
|
||||
|
||||
__u8 :1, /* unused */
|
||||
remlen:7;
|
||||
|
||||
union {
|
||||
__be32 type_be32;
|
||||
|
||||
struct {
|
||||
__u32 bit0:1,
|
||||
bit1:1,
|
||||
bit2:1,
|
||||
bit3:1,
|
||||
bit4:1,
|
||||
bit5:1,
|
||||
bit6:1,
|
||||
bit7:1,
|
||||
bit8:1,
|
||||
bit9:1,
|
||||
bit10:1,
|
||||
bit11:1,
|
||||
bit12:1, /* unused */
|
||||
bit13:1, /* unused */
|
||||
bit14:1, /* unused */
|
||||
bit15:1, /* unused */
|
||||
bit16:1, /* unused */
|
||||
bit17:1, /* unused */
|
||||
bit18:1, /* unused */
|
||||
bit19:1, /* unused */
|
||||
bit20:1, /* unused */
|
||||
bit21:1, /* unused */
|
||||
bit22:1,
|
||||
bit23:1, /* reserved */
|
||||
:8; /* reserved */
|
||||
} type;
|
||||
};
|
||||
|
||||
#else
|
||||
#error "Please fix <asm/byteorder.h>"
|
||||
#endif
|
||||
|
||||
#define IOAM6_TRACE_DATA_SIZE_MAX 244
|
||||
__u8 data[0];
|
||||
} __attribute__((packed));
|
||||
|
||||
#endif /* _UAPI_LINUX_IOAM6_H */
|
||||
52
include/uapi/linux/ioam6_genl.h
Normal file
52
include/uapi/linux/ioam6_genl.h
Normal file
@@ -0,0 +1,52 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
|
||||
/*
|
||||
* IPv6 IOAM Generic Netlink API
|
||||
*
|
||||
* Author:
|
||||
* Justin Iurman <justin.iurman@uliege.be>
|
||||
*/
|
||||
|
||||
#ifndef _UAPI_LINUX_IOAM6_GENL_H
|
||||
#define _UAPI_LINUX_IOAM6_GENL_H
|
||||
|
||||
#define IOAM6_GENL_NAME "IOAM6"
|
||||
#define IOAM6_GENL_VERSION 0x1
|
||||
|
||||
enum {
|
||||
IOAM6_ATTR_UNSPEC,
|
||||
|
||||
IOAM6_ATTR_NS_ID, /* u16 */
|
||||
IOAM6_ATTR_NS_DATA, /* u32 */
|
||||
IOAM6_ATTR_NS_DATA_WIDE,/* u64 */
|
||||
|
||||
#define IOAM6_MAX_SCHEMA_DATA_LEN (255 * 4)
|
||||
IOAM6_ATTR_SC_ID, /* u32 */
|
||||
IOAM6_ATTR_SC_DATA, /* Binary */
|
||||
IOAM6_ATTR_SC_NONE, /* Flag */
|
||||
|
||||
IOAM6_ATTR_PAD,
|
||||
|
||||
__IOAM6_ATTR_MAX,
|
||||
};
|
||||
|
||||
#define IOAM6_ATTR_MAX (__IOAM6_ATTR_MAX - 1)
|
||||
|
||||
enum {
|
||||
IOAM6_CMD_UNSPEC,
|
||||
|
||||
IOAM6_CMD_ADD_NAMESPACE,
|
||||
IOAM6_CMD_DEL_NAMESPACE,
|
||||
IOAM6_CMD_DUMP_NAMESPACES,
|
||||
|
||||
IOAM6_CMD_ADD_SCHEMA,
|
||||
IOAM6_CMD_DEL_SCHEMA,
|
||||
IOAM6_CMD_DUMP_SCHEMAS,
|
||||
|
||||
IOAM6_CMD_NS_SET_SCHEMA,
|
||||
|
||||
__IOAM6_CMD_MAX,
|
||||
};
|
||||
|
||||
#define IOAM6_CMD_MAX (__IOAM6_CMD_MAX - 1)
|
||||
|
||||
#endif /* _UAPI_LINUX_IOAM6_GENL_H */
|
||||
20
include/uapi/linux/ioam6_iptunnel.h
Normal file
20
include/uapi/linux/ioam6_iptunnel.h
Normal file
@@ -0,0 +1,20 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
|
||||
/*
|
||||
* IPv6 IOAM Lightweight Tunnel API
|
||||
*
|
||||
* Author:
|
||||
* Justin Iurman <justin.iurman@uliege.be>
|
||||
*/
|
||||
|
||||
#ifndef _UAPI_LINUX_IOAM6_IPTUNNEL_H
|
||||
#define _UAPI_LINUX_IOAM6_IPTUNNEL_H
|
||||
|
||||
enum {
|
||||
IOAM6_IPTUNNEL_UNSPEC,
|
||||
IOAM6_IPTUNNEL_TRACE, /* struct ioam6_trace_hdr */
|
||||
__IOAM6_IPTUNNEL_MAX,
|
||||
};
|
||||
|
||||
#define IOAM6_IPTUNNEL_MAX (__IOAM6_IPTUNNEL_MAX - 1)
|
||||
|
||||
#endif /* _UAPI_LINUX_IOAM6_IPTUNNEL_H */
|
||||
52
include/uapi/linux/ioprio.h
Normal file
52
include/uapi/linux/ioprio.h
Normal file
@@ -0,0 +1,52 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
#ifndef _UAPI_LINUX_IOPRIO_H
|
||||
#define _UAPI_LINUX_IOPRIO_H
|
||||
|
||||
/*
|
||||
* Gives us 8 prio classes with 13-bits of data for each class
|
||||
*/
|
||||
#define IOPRIO_CLASS_SHIFT 13
|
||||
#define IOPRIO_CLASS_MASK 0x07
|
||||
#define IOPRIO_PRIO_MASK ((1UL << IOPRIO_CLASS_SHIFT) - 1)
|
||||
|
||||
#define IOPRIO_PRIO_CLASS(ioprio) \
|
||||
(((ioprio) >> IOPRIO_CLASS_SHIFT) & IOPRIO_CLASS_MASK)
|
||||
#define IOPRIO_PRIO_DATA(ioprio) ((ioprio) & IOPRIO_PRIO_MASK)
|
||||
#define IOPRIO_PRIO_VALUE(class, data) \
|
||||
((((class) & IOPRIO_CLASS_MASK) << IOPRIO_CLASS_SHIFT) | \
|
||||
((data) & IOPRIO_PRIO_MASK))
|
||||
|
||||
/*
|
||||
* These are the io priority groups as implemented by the BFQ and mq-deadline
|
||||
* schedulers. RT is the realtime class, it always gets premium service. For
|
||||
* ATA disks supporting NCQ IO priority, RT class IOs will be processed using
|
||||
* high priority NCQ commands. BE is the best-effort scheduling class, the
|
||||
* default for any process. IDLE is the idle scheduling class, it is only
|
||||
* served when no one else is using the disk.
|
||||
*/
|
||||
enum {
|
||||
IOPRIO_CLASS_NONE,
|
||||
IOPRIO_CLASS_RT,
|
||||
IOPRIO_CLASS_BE,
|
||||
IOPRIO_CLASS_IDLE,
|
||||
};
|
||||
|
||||
/*
|
||||
* The RT and BE priority classes both support up to 8 priority levels.
|
||||
*/
|
||||
#define IOPRIO_NR_LEVELS 8
|
||||
#define IOPRIO_BE_NR IOPRIO_NR_LEVELS
|
||||
|
||||
enum {
|
||||
IOPRIO_WHO_PROCESS = 1,
|
||||
IOPRIO_WHO_PGRP,
|
||||
IOPRIO_WHO_USER,
|
||||
};
|
||||
|
||||
/*
|
||||
* Fallback BE priority level.
|
||||
*/
|
||||
#define IOPRIO_NORM 4
|
||||
#define IOPRIO_BE_NORM IOPRIO_NORM
|
||||
|
||||
#endif /* _UAPI_LINUX_IOPRIO_H */
|
||||
@@ -190,6 +190,9 @@ enum {
|
||||
DEVCONF_NDISC_TCLASS,
|
||||
DEVCONF_RPL_SEG_ENABLED,
|
||||
DEVCONF_RA_DEFRTR_METRIC,
|
||||
DEVCONF_IOAM6_ENABLED,
|
||||
DEVCONF_IOAM6_ID,
|
||||
DEVCONF_IOAM6_ID_WIDE,
|
||||
DEVCONF_MAX
|
||||
};
|
||||
|
||||
|
||||
@@ -1,87 +0,0 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
#ifndef _IPX_H_
|
||||
#define _IPX_H_
|
||||
#include <linux/libc-compat.h> /* for compatibility with glibc netipx/ipx.h */
|
||||
#include <linux/types.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/socket.h>
|
||||
#define IPX_NODE_LEN 6
|
||||
#define IPX_MTU 576
|
||||
|
||||
#if __UAPI_DEF_SOCKADDR_IPX
|
||||
struct sockaddr_ipx {
|
||||
__kernel_sa_family_t sipx_family;
|
||||
__be16 sipx_port;
|
||||
__be32 sipx_network;
|
||||
unsigned char sipx_node[IPX_NODE_LEN];
|
||||
__u8 sipx_type;
|
||||
unsigned char sipx_zero; /* 16 byte fill */
|
||||
};
|
||||
#endif /* __UAPI_DEF_SOCKADDR_IPX */
|
||||
|
||||
/*
|
||||
* So we can fit the extra info for SIOCSIFADDR into the address nicely
|
||||
*/
|
||||
#define sipx_special sipx_port
|
||||
#define sipx_action sipx_zero
|
||||
#define IPX_DLTITF 0
|
||||
#define IPX_CRTITF 1
|
||||
|
||||
#if __UAPI_DEF_IPX_ROUTE_DEFINITION
|
||||
struct ipx_route_definition {
|
||||
__be32 ipx_network;
|
||||
__be32 ipx_router_network;
|
||||
unsigned char ipx_router_node[IPX_NODE_LEN];
|
||||
};
|
||||
#endif /* __UAPI_DEF_IPX_ROUTE_DEFINITION */
|
||||
|
||||
#if __UAPI_DEF_IPX_INTERFACE_DEFINITION
|
||||
struct ipx_interface_definition {
|
||||
__be32 ipx_network;
|
||||
unsigned char ipx_device[16];
|
||||
unsigned char ipx_dlink_type;
|
||||
#define IPX_FRAME_NONE 0
|
||||
#define IPX_FRAME_SNAP 1
|
||||
#define IPX_FRAME_8022 2
|
||||
#define IPX_FRAME_ETHERII 3
|
||||
#define IPX_FRAME_8023 4
|
||||
#define IPX_FRAME_TR_8022 5 /* obsolete */
|
||||
unsigned char ipx_special;
|
||||
#define IPX_SPECIAL_NONE 0
|
||||
#define IPX_PRIMARY 1
|
||||
#define IPX_INTERNAL 2
|
||||
unsigned char ipx_node[IPX_NODE_LEN];
|
||||
};
|
||||
#endif /* __UAPI_DEF_IPX_INTERFACE_DEFINITION */
|
||||
|
||||
#if __UAPI_DEF_IPX_CONFIG_DATA
|
||||
struct ipx_config_data {
|
||||
unsigned char ipxcfg_auto_select_primary;
|
||||
unsigned char ipxcfg_auto_create_interfaces;
|
||||
};
|
||||
#endif /* __UAPI_DEF_IPX_CONFIG_DATA */
|
||||
|
||||
/*
|
||||
* OLD Route Definition for backward compatibility.
|
||||
*/
|
||||
|
||||
#if __UAPI_DEF_IPX_ROUTE_DEF
|
||||
struct ipx_route_def {
|
||||
__be32 ipx_network;
|
||||
__be32 ipx_router_network;
|
||||
#define IPX_ROUTE_NO_ROUTER 0
|
||||
unsigned char ipx_router_node[IPX_NODE_LEN];
|
||||
unsigned char ipx_device[16];
|
||||
unsigned short ipx_flags;
|
||||
#define IPX_RT_SNAP 8
|
||||
#define IPX_RT_8022 4
|
||||
#define IPX_RT_BLUEBOOK 2
|
||||
#define IPX_RT_ROUTED 1
|
||||
};
|
||||
#endif /* __UAPI_DEF_IPX_ROUTE_DEF */
|
||||
|
||||
#define SIOCAIPXITFCRT (SIOCPROTOPRIVATE)
|
||||
#define SIOCAIPXPRISLT (SIOCPROTOPRIVATE + 1)
|
||||
#define SIOCIPXCFGDATA (SIOCPROTOPRIVATE + 2)
|
||||
#define SIOCIPXNCPCONN (SIOCPROTOPRIVATE + 3)
|
||||
#endif /* _IPX_H_ */
|
||||
@@ -31,9 +31,10 @@
|
||||
* - 1.3 - Add SMI events support
|
||||
* - 1.4 - Indicate new SRAM EDC bit in device properties
|
||||
* - 1.5 - Add SVM API
|
||||
* - 1.6 - Query clear flags in SVM get_attr API
|
||||
*/
|
||||
#define KFD_IOCTL_MAJOR_VERSION 1
|
||||
#define KFD_IOCTL_MINOR_VERSION 5
|
||||
#define KFD_IOCTL_MINOR_VERSION 6
|
||||
|
||||
struct kfd_ioctl_get_version_args {
|
||||
__u32 major_version; /* from KFD */
|
||||
@@ -575,18 +576,19 @@ struct kfd_ioctl_svm_attribute {
|
||||
* @KFD_IOCTL_SVM_ATTR_PREFERRED_LOC or
|
||||
* @KFD_IOCTL_SVM_ATTR_PREFETCH_LOC resepctively. For
|
||||
* @KFD_IOCTL_SVM_ATTR_SET_FLAGS, flags of all pages will be
|
||||
* aggregated by bitwise AND. The minimum migration granularity
|
||||
* throughout the range will be returned for
|
||||
* @KFD_IOCTL_SVM_ATTR_GRANULARITY.
|
||||
* aggregated by bitwise AND. That means, a flag will be set in the
|
||||
* output, if that flag is set for all pages in the range. For
|
||||
* @KFD_IOCTL_SVM_ATTR_CLR_FLAGS, flags of all pages will be
|
||||
* aggregated by bitwise NOR. That means, a flag will be set in the
|
||||
* output, if that flag is clear for all pages in the range.
|
||||
* The minimum migration granularity throughout the range will be
|
||||
* returned for @KFD_IOCTL_SVM_ATTR_GRANULARITY.
|
||||
*
|
||||
* Querying of accessibility attributes works by initializing the
|
||||
* attribute type to @KFD_IOCTL_SVM_ATTR_ACCESS and the value to the
|
||||
* GPUID being queried. Multiple attributes can be given to allow
|
||||
* querying multiple GPUIDs. The ioctl function overwrites the
|
||||
* attribute type to indicate the access for the specified GPU.
|
||||
*
|
||||
* @KFD_IOCTL_SVM_ATTR_CLR_FLAGS is invalid for
|
||||
* @KFD_IOCTL_SVM_OP_GET_ATTR.
|
||||
*/
|
||||
struct kfd_ioctl_svm_args {
|
||||
__u64 start_addr;
|
||||
|
||||
@@ -1965,7 +1965,9 @@ struct kvm_stats_header {
|
||||
#define KVM_STATS_TYPE_CUMULATIVE (0x0 << KVM_STATS_TYPE_SHIFT)
|
||||
#define KVM_STATS_TYPE_INSTANT (0x1 << KVM_STATS_TYPE_SHIFT)
|
||||
#define KVM_STATS_TYPE_PEAK (0x2 << KVM_STATS_TYPE_SHIFT)
|
||||
#define KVM_STATS_TYPE_MAX KVM_STATS_TYPE_PEAK
|
||||
#define KVM_STATS_TYPE_LINEAR_HIST (0x3 << KVM_STATS_TYPE_SHIFT)
|
||||
#define KVM_STATS_TYPE_LOG_HIST (0x4 << KVM_STATS_TYPE_SHIFT)
|
||||
#define KVM_STATS_TYPE_MAX KVM_STATS_TYPE_LOG_HIST
|
||||
|
||||
#define KVM_STATS_UNIT_SHIFT 4
|
||||
#define KVM_STATS_UNIT_MASK (0xF << KVM_STATS_UNIT_SHIFT)
|
||||
@@ -1988,8 +1990,9 @@ struct kvm_stats_header {
|
||||
* @size: The number of data items for this stats.
|
||||
* Every data item is of type __u64.
|
||||
* @offset: The offset of the stats to the start of stat structure in
|
||||
* struture kvm or kvm_vcpu.
|
||||
* @unused: Unused field for future usage. Always 0 for now.
|
||||
* structure kvm or kvm_vcpu.
|
||||
* @bucket_size: A parameter value used for histogram stats. It is only used
|
||||
* for linear histogram stats, specifying the size of the bucket;
|
||||
* @name: The name string for the stats. Its size is indicated by the
|
||||
* &kvm_stats_header->name_size.
|
||||
*/
|
||||
@@ -1998,7 +2001,7 @@ struct kvm_stats_desc {
|
||||
__s16 exponent;
|
||||
__u16 size;
|
||||
__u32 offset;
|
||||
__u32 unused;
|
||||
__u32 bucket_size;
|
||||
char name[];
|
||||
};
|
||||
|
||||
|
||||
@@ -1,224 +0,0 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
/*
|
||||
* Copyright (C) 2015 CNEX Labs. All rights reserved.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License version
|
||||
* 2 as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; see the file COPYING. If not, write to
|
||||
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139,
|
||||
* USA.
|
||||
*/
|
||||
|
||||
#ifndef _UAPI_LINUX_LIGHTNVM_H
|
||||
#define _UAPI_LINUX_LIGHTNVM_H
|
||||
|
||||
#ifdef __KERNEL__
|
||||
#include <linux/const.h>
|
||||
#else /* __KERNEL__ */
|
||||
#include <stdio.h>
|
||||
#include <sys/ioctl.h>
|
||||
#define DISK_NAME_LEN 32
|
||||
#endif /* __KERNEL__ */
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/ioctl.h>
|
||||
|
||||
#define NVM_TTYPE_NAME_MAX 48
|
||||
#define NVM_TTYPE_MAX 63
|
||||
#define NVM_MMTYPE_LEN 8
|
||||
|
||||
#define NVM_CTRL_FILE "/dev/lightnvm/control"
|
||||
|
||||
struct nvm_ioctl_info_tgt {
|
||||
__u32 version[3];
|
||||
__u32 reserved;
|
||||
char tgtname[NVM_TTYPE_NAME_MAX];
|
||||
};
|
||||
|
||||
struct nvm_ioctl_info {
|
||||
__u32 version[3]; /* in/out - major, minor, patch */
|
||||
__u16 tgtsize; /* number of targets */
|
||||
__u16 reserved16; /* pad to 4K page */
|
||||
__u32 reserved[12];
|
||||
struct nvm_ioctl_info_tgt tgts[NVM_TTYPE_MAX];
|
||||
};
|
||||
|
||||
enum {
|
||||
NVM_DEVICE_ACTIVE = 1 << 0,
|
||||
};
|
||||
|
||||
struct nvm_ioctl_device_info {
|
||||
char devname[DISK_NAME_LEN];
|
||||
char bmname[NVM_TTYPE_NAME_MAX];
|
||||
__u32 bmversion[3];
|
||||
__u32 flags;
|
||||
__u32 reserved[8];
|
||||
};
|
||||
|
||||
struct nvm_ioctl_get_devices {
|
||||
__u32 nr_devices;
|
||||
__u32 reserved[31];
|
||||
struct nvm_ioctl_device_info info[31];
|
||||
};
|
||||
|
||||
struct nvm_ioctl_create_simple {
|
||||
__u32 lun_begin;
|
||||
__u32 lun_end;
|
||||
};
|
||||
|
||||
struct nvm_ioctl_create_extended {
|
||||
__u16 lun_begin;
|
||||
__u16 lun_end;
|
||||
__u16 op;
|
||||
__u16 rsv;
|
||||
};
|
||||
|
||||
enum {
|
||||
NVM_CONFIG_TYPE_SIMPLE = 0,
|
||||
NVM_CONFIG_TYPE_EXTENDED = 1,
|
||||
};
|
||||
|
||||
struct nvm_ioctl_create_conf {
|
||||
__u32 type;
|
||||
union {
|
||||
struct nvm_ioctl_create_simple s;
|
||||
struct nvm_ioctl_create_extended e;
|
||||
};
|
||||
};
|
||||
|
||||
enum {
|
||||
NVM_TARGET_FACTORY = 1 << 0, /* Init target in factory mode */
|
||||
};
|
||||
|
||||
struct nvm_ioctl_create {
|
||||
char dev[DISK_NAME_LEN]; /* open-channel SSD device */
|
||||
char tgttype[NVM_TTYPE_NAME_MAX]; /* target type name */
|
||||
char tgtname[DISK_NAME_LEN]; /* dev to expose target as */
|
||||
|
||||
__u32 flags;
|
||||
|
||||
struct nvm_ioctl_create_conf conf;
|
||||
};
|
||||
|
||||
struct nvm_ioctl_remove {
|
||||
char tgtname[DISK_NAME_LEN];
|
||||
|
||||
__u32 flags;
|
||||
};
|
||||
|
||||
struct nvm_ioctl_dev_init {
|
||||
char dev[DISK_NAME_LEN]; /* open-channel SSD device */
|
||||
char mmtype[NVM_MMTYPE_LEN]; /* register to media manager */
|
||||
|
||||
__u32 flags;
|
||||
};
|
||||
|
||||
enum {
|
||||
NVM_FACTORY_ERASE_ONLY_USER = 1 << 0, /* erase only blocks used as
|
||||
* host blks or grown blks */
|
||||
NVM_FACTORY_RESET_HOST_BLKS = 1 << 1, /* remove host blk marks */
|
||||
NVM_FACTORY_RESET_GRWN_BBLKS = 1 << 2, /* remove grown blk marks */
|
||||
NVM_FACTORY_NR_BITS = 1 << 3, /* stops here */
|
||||
};
|
||||
|
||||
struct nvm_ioctl_dev_factory {
|
||||
char dev[DISK_NAME_LEN];
|
||||
|
||||
__u32 flags;
|
||||
};
|
||||
|
||||
struct nvm_user_vio {
|
||||
__u8 opcode;
|
||||
__u8 flags;
|
||||
__u16 control;
|
||||
__u16 nppas;
|
||||
__u16 rsvd;
|
||||
__u64 metadata;
|
||||
__u64 addr;
|
||||
__u64 ppa_list;
|
||||
__u32 metadata_len;
|
||||
__u32 data_len;
|
||||
__u64 status;
|
||||
__u32 result;
|
||||
__u32 rsvd3[3];
|
||||
};
|
||||
|
||||
struct nvm_passthru_vio {
|
||||
__u8 opcode;
|
||||
__u8 flags;
|
||||
__u8 rsvd[2];
|
||||
__u32 nsid;
|
||||
__u32 cdw2;
|
||||
__u32 cdw3;
|
||||
__u64 metadata;
|
||||
__u64 addr;
|
||||
__u32 metadata_len;
|
||||
__u32 data_len;
|
||||
__u64 ppa_list;
|
||||
__u16 nppas;
|
||||
__u16 control;
|
||||
__u32 cdw13;
|
||||
__u32 cdw14;
|
||||
__u32 cdw15;
|
||||
__u64 status;
|
||||
__u32 result;
|
||||
__u32 timeout_ms;
|
||||
};
|
||||
|
||||
/* The ioctl type, 'L', 0x20 - 0x2F documented in ioctl-number.txt */
|
||||
enum {
|
||||
/* top level cmds */
|
||||
NVM_INFO_CMD = 0x20,
|
||||
NVM_GET_DEVICES_CMD,
|
||||
|
||||
/* device level cmds */
|
||||
NVM_DEV_CREATE_CMD,
|
||||
NVM_DEV_REMOVE_CMD,
|
||||
|
||||
/* Init a device to support LightNVM media managers */
|
||||
NVM_DEV_INIT_CMD,
|
||||
|
||||
/* Factory reset device */
|
||||
NVM_DEV_FACTORY_CMD,
|
||||
|
||||
/* Vector user I/O */
|
||||
NVM_DEV_VIO_ADMIN_CMD = 0x41,
|
||||
NVM_DEV_VIO_CMD = 0x42,
|
||||
NVM_DEV_VIO_USER_CMD = 0x43,
|
||||
};
|
||||
|
||||
#define NVM_IOCTL 'L' /* 0x4c */
|
||||
|
||||
#define NVM_INFO _IOWR(NVM_IOCTL, NVM_INFO_CMD, \
|
||||
struct nvm_ioctl_info)
|
||||
#define NVM_GET_DEVICES _IOR(NVM_IOCTL, NVM_GET_DEVICES_CMD, \
|
||||
struct nvm_ioctl_get_devices)
|
||||
#define NVM_DEV_CREATE _IOW(NVM_IOCTL, NVM_DEV_CREATE_CMD, \
|
||||
struct nvm_ioctl_create)
|
||||
#define NVM_DEV_REMOVE _IOW(NVM_IOCTL, NVM_DEV_REMOVE_CMD, \
|
||||
struct nvm_ioctl_remove)
|
||||
#define NVM_DEV_INIT _IOW(NVM_IOCTL, NVM_DEV_INIT_CMD, \
|
||||
struct nvm_ioctl_dev_init)
|
||||
#define NVM_DEV_FACTORY _IOW(NVM_IOCTL, NVM_DEV_FACTORY_CMD, \
|
||||
struct nvm_ioctl_dev_factory)
|
||||
|
||||
#define NVME_NVM_IOCTL_IO_VIO _IOWR(NVM_IOCTL, NVM_DEV_VIO_USER_CMD, \
|
||||
struct nvm_passthru_vio)
|
||||
#define NVME_NVM_IOCTL_ADMIN_VIO _IOWR(NVM_IOCTL, NVM_DEV_VIO_ADMIN_CMD,\
|
||||
struct nvm_passthru_vio)
|
||||
#define NVME_NVM_IOCTL_SUBMIT_VIO _IOWR(NVM_IOCTL, NVM_DEV_VIO_CMD,\
|
||||
struct nvm_user_vio)
|
||||
|
||||
#define NVM_VERSION_MAJOR 1
|
||||
#define NVM_VERSION_MINOR 0
|
||||
#define NVM_VERSION_PATCHLEVEL 0
|
||||
|
||||
#endif
|
||||
@@ -14,6 +14,7 @@ enum lwtunnel_encap_types {
|
||||
LWTUNNEL_ENCAP_BPF,
|
||||
LWTUNNEL_ENCAP_SEG6_LOCAL,
|
||||
LWTUNNEL_ENCAP_RPL,
|
||||
LWTUNNEL_ENCAP_IOAM6,
|
||||
__LWTUNNEL_ENCAP_MAX,
|
||||
};
|
||||
|
||||
|
||||
39
include/uapi/linux/mctp.h
Normal file
39
include/uapi/linux/mctp.h
Normal file
@@ -0,0 +1,39 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
/*
|
||||
* Management Component Transport Protocol (MCTP)
|
||||
*
|
||||
* Copyright (c) 2021 Code Construct
|
||||
* Copyright (c) 2021 Google
|
||||
*/
|
||||
|
||||
#ifndef __UAPI_MCTP_H
|
||||
#define __UAPI_MCTP_H
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
|
||||
typedef __u8 mctp_eid_t;
|
||||
|
||||
struct mctp_addr {
|
||||
mctp_eid_t s_addr;
|
||||
};
|
||||
|
||||
struct sockaddr_mctp {
|
||||
__kernel_sa_family_t smctp_family;
|
||||
__u16 __smctp_pad0;
|
||||
unsigned int smctp_network;
|
||||
struct mctp_addr smctp_addr;
|
||||
__u8 smctp_type;
|
||||
__u8 smctp_tag;
|
||||
__u8 __smctp_pad1;
|
||||
};
|
||||
|
||||
#define MCTP_NET_ANY 0x0
|
||||
|
||||
#define MCTP_ADDR_NULL 0x00
|
||||
#define MCTP_ADDR_ANY 0xff
|
||||
|
||||
#define MCTP_TAG_MASK 0x07
|
||||
#define MCTP_TAG_OWNER 0x08
|
||||
|
||||
#endif /* __UAPI_MCTP_H */
|
||||
@@ -22,6 +22,7 @@ enum {
|
||||
MPOL_BIND,
|
||||
MPOL_INTERLEAVE,
|
||||
MPOL_LOCAL,
|
||||
MPOL_PREFERRED_MANY,
|
||||
MPOL_MAX, /* always last member of enum */
|
||||
};
|
||||
|
||||
|
||||
@@ -73,7 +73,8 @@
|
||||
#define MOVE_MOUNT_T_SYMLINKS 0x00000010 /* Follow symlinks on to path */
|
||||
#define MOVE_MOUNT_T_AUTOMOUNTS 0x00000020 /* Follow automounts on to path */
|
||||
#define MOVE_MOUNT_T_EMPTY_PATH 0x00000040 /* Empty to path permitted */
|
||||
#define MOVE_MOUNT__MASK 0x00000077
|
||||
#define MOVE_MOUNT_SET_GROUP 0x00000100 /* Set sharing group instead */
|
||||
#define MOVE_MOUNT__MASK 0x00000177
|
||||
|
||||
/*
|
||||
* fsopen() flags.
|
||||
|
||||
@@ -73,6 +73,7 @@ enum {
|
||||
#define MPTCP_PM_ADDR_FLAG_SIGNAL (1 << 0)
|
||||
#define MPTCP_PM_ADDR_FLAG_SUBFLOW (1 << 1)
|
||||
#define MPTCP_PM_ADDR_FLAG_BACKUP (1 << 2)
|
||||
#define MPTCP_PM_ADDR_FLAG_FULLMESH (1 << 3)
|
||||
|
||||
enum {
|
||||
MPTCP_PM_CMD_UNSPEC,
|
||||
|
||||
@@ -56,6 +56,7 @@ enum ctattr_type {
|
||||
CTA_LABELS_MASK,
|
||||
CTA_SYNPROXY,
|
||||
CTA_FILTER,
|
||||
CTA_STATUS_MASK,
|
||||
__CTA_MAX
|
||||
};
|
||||
#define CTA_MAX (__CTA_MAX - 1)
|
||||
@@ -257,6 +258,7 @@ enum ctattr_stats_cpu {
|
||||
CTA_STATS_ERROR,
|
||||
CTA_STATS_SEARCH_RESTART,
|
||||
CTA_STATS_CLASH_RESOLVE,
|
||||
CTA_STATS_CHAIN_TOOLONG,
|
||||
__CTA_STATS_MAX,
|
||||
};
|
||||
#define CTA_STATS_MAX (__CTA_STATS_MAX - 1)
|
||||
|
||||
@@ -33,7 +33,6 @@ struct nfs_fhbase_old {
|
||||
|
||||
/*
|
||||
* This is the new flexible, extensible style NFSv2/v3/v4 file handle.
|
||||
* by Neil Brown <neilb@cse.unsw.edu.au> - March 2000
|
||||
*
|
||||
* The file handle starts with a sequence of four-byte words.
|
||||
* The first word contains a version number (1) and three descriptor bytes
|
||||
|
||||
77
include/uapi/linux/nl80211-vnd-intel.h
Normal file
77
include/uapi/linux/nl80211-vnd-intel.h
Normal file
@@ -0,0 +1,77 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
/*
|
||||
* Copyright (C) 2012-2014, 2018-2021 Intel Corporation
|
||||
* Copyright (C) 2013-2015 Intel Mobile Communications GmbH
|
||||
* Copyright (C) 2016-2017 Intel Deutschland GmbH
|
||||
*/
|
||||
#ifndef __VENDOR_CMD_INTEL_H__
|
||||
#define __VENDOR_CMD_INTEL_H__
|
||||
|
||||
#define INTEL_OUI 0x001735
|
||||
|
||||
/**
|
||||
* enum iwl_mvm_vendor_cmd - supported vendor commands
|
||||
* @IWL_MVM_VENDOR_CMD_GET_CSME_CONN_INFO: reports CSME connection info.
|
||||
* @IWL_MVM_VENDOR_CMD_HOST_GET_OWNERSHIP: asks for ownership on the device.
|
||||
* @IWL_MVM_VENDOR_CMD_ROAMING_FORBIDDEN_EVENT: notifies if roaming is allowed.
|
||||
* It contains a &IWL_MVM_VENDOR_ATTR_ROAMING_FORBIDDEN and a
|
||||
* &IWL_MVM_VENDOR_ATTR_VIF_ADDR attributes.
|
||||
*/
|
||||
|
||||
enum iwl_mvm_vendor_cmd {
|
||||
IWL_MVM_VENDOR_CMD_GET_CSME_CONN_INFO = 0x2d,
|
||||
IWL_MVM_VENDOR_CMD_HOST_GET_OWNERSHIP = 0x30,
|
||||
IWL_MVM_VENDOR_CMD_ROAMING_FORBIDDEN_EVENT = 0x32,
|
||||
};
|
||||
|
||||
enum iwl_vendor_auth_akm_mode {
|
||||
IWL_VENDOR_AUTH_OPEN,
|
||||
IWL_VENDOR_AUTH_RSNA = 0x6,
|
||||
IWL_VENDOR_AUTH_RSNA_PSK,
|
||||
IWL_VENDOR_AUTH_SAE = 0x9,
|
||||
IWL_VENDOR_AUTH_MAX,
|
||||
};
|
||||
|
||||
/**
|
||||
* enum iwl_mvm_vendor_attr - attributes used in vendor commands
|
||||
* @__IWL_MVM_VENDOR_ATTR_INVALID: attribute 0 is invalid
|
||||
* @IWL_MVM_VENDOR_ATTR_VIF_ADDR: interface MAC address
|
||||
* @IWL_MVM_VENDOR_ATTR_ADDR: MAC address
|
||||
* @IWL_MVM_VENDOR_ATTR_SSID: SSID (binary attribute, 0..32 octets)
|
||||
* @IWL_MVM_VENDOR_ATTR_STA_CIPHER: the cipher to use for the station with the
|
||||
* mac address specified in &IWL_MVM_VENDOR_ATTR_ADDR.
|
||||
* @IWL_MVM_VENDOR_ATTR_ROAMING_FORBIDDEN: u8 attribute. Indicates whether
|
||||
* roaming is forbidden or not. Value 1 means roaming is forbidden,
|
||||
* 0 mean roaming is allowed.
|
||||
* @IWL_MVM_VENDOR_ATTR_AUTH_MODE: u32 attribute. Authentication mode type
|
||||
* as specified in &enum iwl_vendor_auth_akm_mode.
|
||||
* @IWL_MVM_VENDOR_ATTR_CHANNEL_NUM: u8 attribute. Contains channel number.
|
||||
* @IWL_MVM_VENDOR_ATTR_BAND: u8 attribute.
|
||||
* 0 for 2.4 GHz band, 1 for 5.2GHz band and 2 for 6GHz band.
|
||||
* @IWL_MVM_VENDOR_ATTR_COLLOC_CHANNEL: u32 attribute. Channel number of
|
||||
* collocated AP. Relevant for 6GHz AP info.
|
||||
* @IWL_MVM_VENDOR_ATTR_COLLOC_ADDR: MAC address of a collocated AP.
|
||||
* Relevant for 6GHz AP info.
|
||||
*
|
||||
* @NUM_IWL_MVM_VENDOR_ATTR: number of vendor attributes
|
||||
* @MAX_IWL_MVM_VENDOR_ATTR: highest vendor attribute number
|
||||
|
||||
*/
|
||||
enum iwl_mvm_vendor_attr {
|
||||
__IWL_MVM_VENDOR_ATTR_INVALID = 0x00,
|
||||
IWL_MVM_VENDOR_ATTR_VIF_ADDR = 0x02,
|
||||
IWL_MVM_VENDOR_ATTR_ADDR = 0x0a,
|
||||
IWL_MVM_VENDOR_ATTR_SSID = 0x3d,
|
||||
IWL_MVM_VENDOR_ATTR_STA_CIPHER = 0x51,
|
||||
IWL_MVM_VENDOR_ATTR_ROAMING_FORBIDDEN = 0x64,
|
||||
IWL_MVM_VENDOR_ATTR_AUTH_MODE = 0x65,
|
||||
IWL_MVM_VENDOR_ATTR_CHANNEL_NUM = 0x66,
|
||||
IWL_MVM_VENDOR_ATTR_BAND = 0x69,
|
||||
IWL_MVM_VENDOR_ATTR_COLLOC_CHANNEL = 0x70,
|
||||
IWL_MVM_VENDOR_ATTR_COLLOC_ADDR = 0x71,
|
||||
|
||||
NUM_IWL_MVM_VENDOR_ATTR,
|
||||
MAX_IWL_MVM_VENDOR_ATTR = NUM_IWL_MVM_VENDOR_ATTR - 1,
|
||||
};
|
||||
|
||||
#endif /* __VENDOR_CMD_INTEL_H__ */
|
||||
@@ -1185,6 +1185,21 @@
|
||||
* passed using %NL80211_ATTR_SAR_SPEC. %NL80211_ATTR_WIPHY is used to
|
||||
* specify the wiphy index to be applied to.
|
||||
*
|
||||
* @NL80211_CMD_OBSS_COLOR_COLLISION: This notification is sent out whenever
|
||||
* mac80211/drv detects a bss color collision.
|
||||
*
|
||||
* @NL80211_CMD_COLOR_CHANGE_REQUEST: This command is used to indicate that
|
||||
* userspace wants to change the BSS color.
|
||||
*
|
||||
* @NL80211_CMD_COLOR_CHANGE_STARTED: Notify userland, that a color change has
|
||||
* started
|
||||
*
|
||||
* @NL80211_CMD_COLOR_CHANGE_ABORTED: Notify userland, that the color change has
|
||||
* been aborted
|
||||
*
|
||||
* @NL80211_CMD_COLOR_CHANGE_COMPLETED: Notify userland that the color change
|
||||
* has completed
|
||||
*
|
||||
* @NL80211_CMD_MAX: highest used command number
|
||||
* @__NL80211_CMD_AFTER_LAST: internal use
|
||||
*/
|
||||
@@ -1417,6 +1432,14 @@ enum nl80211_commands {
|
||||
|
||||
NL80211_CMD_SET_SAR_SPECS,
|
||||
|
||||
NL80211_CMD_OBSS_COLOR_COLLISION,
|
||||
|
||||
NL80211_CMD_COLOR_CHANGE_REQUEST,
|
||||
|
||||
NL80211_CMD_COLOR_CHANGE_STARTED,
|
||||
NL80211_CMD_COLOR_CHANGE_ABORTED,
|
||||
NL80211_CMD_COLOR_CHANGE_COMPLETED,
|
||||
|
||||
/* add new commands above here */
|
||||
|
||||
/* used to define NL80211_CMD_MAX below */
|
||||
@@ -2560,6 +2583,16 @@ enum nl80211_commands {
|
||||
* disassoc events to indicate that an immediate reconnect to the AP
|
||||
* is desired.
|
||||
*
|
||||
* @NL80211_ATTR_OBSS_COLOR_BITMAP: bitmap of the u64 BSS colors for the
|
||||
* %NL80211_CMD_OBSS_COLOR_COLLISION event.
|
||||
*
|
||||
* @NL80211_ATTR_COLOR_CHANGE_COUNT: u8 attribute specifying the number of TBTT's
|
||||
* until the color switch event.
|
||||
* @NL80211_ATTR_COLOR_CHANGE_COLOR: u8 attribute specifying the color that we are
|
||||
* switching to
|
||||
* @NL80211_ATTR_COLOR_CHANGE_ELEMS: Nested set of attributes containing the IE
|
||||
* information for the time while performing a color switch.
|
||||
*
|
||||
* @NUM_NL80211_ATTR: total number of nl80211_attrs available
|
||||
* @NL80211_ATTR_MAX: highest attribute number currently defined
|
||||
* @__NL80211_ATTR_AFTER_LAST: internal use
|
||||
@@ -3057,6 +3090,12 @@ enum nl80211_attrs {
|
||||
|
||||
NL80211_ATTR_DISABLE_HE,
|
||||
|
||||
NL80211_ATTR_OBSS_COLOR_BITMAP,
|
||||
|
||||
NL80211_ATTR_COLOR_CHANGE_COUNT,
|
||||
NL80211_ATTR_COLOR_CHANGE_COLOR,
|
||||
NL80211_ATTR_COLOR_CHANGE_ELEMS,
|
||||
|
||||
/* add attributes here, update the policy in nl80211.c */
|
||||
|
||||
__NL80211_ATTR_AFTER_LAST,
|
||||
@@ -5953,6 +5992,9 @@ enum nl80211_feature_flags {
|
||||
* frame protection for all management frames exchanged during the
|
||||
* negotiation and range measurement procedure.
|
||||
*
|
||||
* @NL80211_EXT_FEATURE_BSS_COLOR: The driver supports BSS color collision
|
||||
* detection and change announcemnts.
|
||||
*
|
||||
* @NUM_NL80211_EXT_FEATURES: number of extended features.
|
||||
* @MAX_NL80211_EXT_FEATURES: highest extended feature index.
|
||||
*/
|
||||
@@ -6017,6 +6059,7 @@ enum nl80211_ext_feature_index {
|
||||
NL80211_EXT_FEATURE_SECURE_LTF,
|
||||
NL80211_EXT_FEATURE_SECURE_RTT,
|
||||
NL80211_EXT_FEATURE_PROT_RANGE_NEGO_AND_MEASURE,
|
||||
NL80211_EXT_FEATURE_BSS_COLOR,
|
||||
|
||||
/* add new features before the definition below */
|
||||
NUM_NL80211_EXT_FEATURES,
|
||||
|
||||
@@ -70,6 +70,8 @@ enum ovs_datapath_cmd {
|
||||
* set on the datapath port (for OVS_ACTION_ATTR_MISS). Only valid on
|
||||
* %OVS_DP_CMD_NEW requests. A value of zero indicates that upcalls should
|
||||
* not be sent.
|
||||
* @OVS_DP_ATTR_PER_CPU_PIDS: Per-cpu array of PIDs for upcalls when
|
||||
* OVS_DP_F_DISPATCH_UPCALL_PER_CPU feature is set.
|
||||
* @OVS_DP_ATTR_STATS: Statistics about packets that have passed through the
|
||||
* datapath. Always present in notifications.
|
||||
* @OVS_DP_ATTR_MEGAFLOW_STATS: Statistics about mega flow masks usage for the
|
||||
@@ -87,6 +89,9 @@ enum ovs_datapath_attr {
|
||||
OVS_DP_ATTR_USER_FEATURES, /* OVS_DP_F_* */
|
||||
OVS_DP_ATTR_PAD,
|
||||
OVS_DP_ATTR_MASKS_CACHE_SIZE,
|
||||
OVS_DP_ATTR_PER_CPU_PIDS, /* Netlink PIDS to receive upcalls in
|
||||
* per-cpu dispatch mode
|
||||
*/
|
||||
__OVS_DP_ATTR_MAX
|
||||
};
|
||||
|
||||
@@ -127,6 +132,9 @@ struct ovs_vport_stats {
|
||||
/* Allow tc offload recirc sharing */
|
||||
#define OVS_DP_F_TC_RECIRC_SHARING (1 << 2)
|
||||
|
||||
/* Allow per-cpu dispatch of upcalls */
|
||||
#define OVS_DP_F_DISPATCH_UPCALL_PER_CPU (1 << 3)
|
||||
|
||||
/* Fixed logical ports. */
|
||||
#define OVSP_LOCAL ((__u32)0)
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ enum {
|
||||
__TCA_ACT_MAX
|
||||
};
|
||||
|
||||
/* See other TCA_ACT_FLAGS_ * flags in include/net/act_api.h. */
|
||||
#define TCA_ACT_FLAGS_NO_PERCPU_STATS 1 /* Don't use percpu allocator for
|
||||
* actions stats.
|
||||
*/
|
||||
|
||||
@@ -827,6 +827,8 @@ struct tc_codel_xstats {
|
||||
|
||||
/* FQ_CODEL */
|
||||
|
||||
#define FQ_CODEL_QUANTUM_MAX (1 << 20)
|
||||
|
||||
enum {
|
||||
TCA_FQ_CODEL_UNSPEC,
|
||||
TCA_FQ_CODEL_TARGET,
|
||||
|
||||
@@ -213,6 +213,7 @@ struct prctl_mm_map {
|
||||
/* Speculation control variants */
|
||||
# define PR_SPEC_STORE_BYPASS 0
|
||||
# define PR_SPEC_INDIRECT_BRANCH 1
|
||||
# define PR_SPEC_L1D_FLUSH 2
|
||||
/* Return and control values for PR_SET/GET_SPECULATION_CTRL */
|
||||
# define PR_SPEC_NOT_AFFECTED 0
|
||||
# define PR_SPEC_PRCTL (1UL << 0)
|
||||
@@ -234,14 +235,15 @@ struct prctl_mm_map {
|
||||
#define PR_GET_TAGGED_ADDR_CTRL 56
|
||||
# define PR_TAGGED_ADDR_ENABLE (1UL << 0)
|
||||
/* MTE tag check fault modes */
|
||||
# define PR_MTE_TCF_SHIFT 1
|
||||
# define PR_MTE_TCF_NONE (0UL << PR_MTE_TCF_SHIFT)
|
||||
# define PR_MTE_TCF_SYNC (1UL << PR_MTE_TCF_SHIFT)
|
||||
# define PR_MTE_TCF_ASYNC (2UL << PR_MTE_TCF_SHIFT)
|
||||
# define PR_MTE_TCF_MASK (3UL << PR_MTE_TCF_SHIFT)
|
||||
# define PR_MTE_TCF_NONE 0
|
||||
# define PR_MTE_TCF_SYNC (1UL << 1)
|
||||
# define PR_MTE_TCF_ASYNC (1UL << 2)
|
||||
# define PR_MTE_TCF_MASK (PR_MTE_TCF_SYNC | PR_MTE_TCF_ASYNC)
|
||||
/* MTE tag inclusion mask */
|
||||
# define PR_MTE_TAG_SHIFT 3
|
||||
# define PR_MTE_TAG_MASK (0xffffUL << PR_MTE_TAG_SHIFT)
|
||||
/* Unused; kept only for source compatibility */
|
||||
# define PR_MTE_TCF_SHIFT 1
|
||||
|
||||
/* Control reclaim behavior when allocating memory */
|
||||
#define PR_SET_IO_FLUSHER 57
|
||||
|
||||
@@ -62,6 +62,7 @@
|
||||
* ST16C654: 8 16 56 60 8 16 32 56 PORT_16654
|
||||
* TI16C750: 1 16 32 56 xx xx xx xx PORT_16750
|
||||
* TI16C752: 8 16 56 60 8 16 32 56
|
||||
* OX16C950: 16 32 112 120 16 32 64 112 PORT_16C950
|
||||
* Tegra: 1 4 8 14 16 8 4 1 PORT_TEGRA
|
||||
*/
|
||||
#define UART_FCR_R_TRIG_00 0x00
|
||||
|
||||
@@ -26,4 +26,9 @@ struct __kernel_sockaddr_storage {
|
||||
};
|
||||
};
|
||||
|
||||
#define SOCK_SNDBUF_LOCK 1
|
||||
#define SOCK_RCVBUF_LOCK 2
|
||||
|
||||
#define SOCK_BUF_LOCK_MASK (SOCK_SNDBUF_LOCK | SOCK_RCVBUF_LOCK)
|
||||
|
||||
#endif /* _UAPI_LINUX_SOCKET_H */
|
||||
|
||||
@@ -46,6 +46,7 @@
|
||||
#define TCMU_MAILBOX_FLAG_CAP_OOOC (1 << 0) /* Out-of-order completions */
|
||||
#define TCMU_MAILBOX_FLAG_CAP_READ_LEN (1 << 1) /* Read data length */
|
||||
#define TCMU_MAILBOX_FLAG_CAP_TMR (1 << 2) /* TMR notifications */
|
||||
#define TCMU_MAILBOX_FLAG_CAP_KEEP_BUF (1<<3) /* Keep buf after cmd completion */
|
||||
|
||||
struct tcmu_mailbox {
|
||||
__u16 version;
|
||||
@@ -75,6 +76,7 @@ struct tcmu_cmd_entry_hdr {
|
||||
__u8 kflags;
|
||||
#define TCMU_UFLAG_UNKNOWN_OP 0x1
|
||||
#define TCMU_UFLAG_READ_LEN 0x2
|
||||
#define TCMU_UFLAG_KEEP_BUF 0x4
|
||||
__u8 uflags;
|
||||
|
||||
} __packed;
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
#define SKBMOD_F_SMAC 0x2
|
||||
#define SKBMOD_F_ETYPE 0x4
|
||||
#define SKBMOD_F_SWAPMAC 0x8
|
||||
#define SKBMOD_F_ECN 0x10
|
||||
|
||||
struct tc_skbmod {
|
||||
tc_gen;
|
||||
|
||||
@@ -435,6 +435,7 @@ enum v4l2_mpeg_video_multi_slice_mode {
|
||||
#define V4L2_CID_MPEG_VIDEO_FRAME_LTR_INDEX (V4L2_CID_CODEC_BASE+233)
|
||||
#define V4L2_CID_MPEG_VIDEO_USE_LTR_FRAMES (V4L2_CID_CODEC_BASE+234)
|
||||
#define V4L2_CID_MPEG_VIDEO_DEC_CONCEAL_COLOR (V4L2_CID_CODEC_BASE+235)
|
||||
#define V4L2_CID_MPEG_VIDEO_INTRA_REFRESH_PERIOD (V4L2_CID_CODEC_BASE+236)
|
||||
|
||||
/* CIDs for the MPEG-2 Part 2 (H.262) codec */
|
||||
#define V4L2_CID_MPEG_VIDEO_MPEG2_LEVEL (V4L2_CID_CODEC_BASE+270)
|
||||
|
||||
306
include/uapi/linux/vduse.h
Normal file
306
include/uapi/linux/vduse.h
Normal file
@@ -0,0 +1,306 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
#ifndef _UAPI_VDUSE_H_
|
||||
#define _UAPI_VDUSE_H_
|
||||
|
||||
#include <linux/types.h>
|
||||
|
||||
#define VDUSE_BASE 0x81
|
||||
|
||||
/* The ioctls for control device (/dev/vduse/control) */
|
||||
|
||||
#define VDUSE_API_VERSION 0
|
||||
|
||||
/*
|
||||
* Get the version of VDUSE API that kernel supported (VDUSE_API_VERSION).
|
||||
* This is used for future extension.
|
||||
*/
|
||||
#define VDUSE_GET_API_VERSION _IOR(VDUSE_BASE, 0x00, __u64)
|
||||
|
||||
/* Set the version of VDUSE API that userspace supported. */
|
||||
#define VDUSE_SET_API_VERSION _IOW(VDUSE_BASE, 0x01, __u64)
|
||||
|
||||
/**
|
||||
* struct vduse_dev_config - basic configuration of a VDUSE device
|
||||
* @name: VDUSE device name, needs to be NUL terminated
|
||||
* @vendor_id: virtio vendor id
|
||||
* @device_id: virtio device id
|
||||
* @features: virtio features
|
||||
* @vq_num: the number of virtqueues
|
||||
* @vq_align: the allocation alignment of virtqueue's metadata
|
||||
* @reserved: for future use, needs to be initialized to zero
|
||||
* @config_size: the size of the configuration space
|
||||
* @config: the buffer of the configuration space
|
||||
*
|
||||
* Structure used by VDUSE_CREATE_DEV ioctl to create VDUSE device.
|
||||
*/
|
||||
struct vduse_dev_config {
|
||||
#define VDUSE_NAME_MAX 256
|
||||
char name[VDUSE_NAME_MAX];
|
||||
__u32 vendor_id;
|
||||
__u32 device_id;
|
||||
__u64 features;
|
||||
__u32 vq_num;
|
||||
__u32 vq_align;
|
||||
__u32 reserved[13];
|
||||
__u32 config_size;
|
||||
__u8 config[];
|
||||
};
|
||||
|
||||
/* Create a VDUSE device which is represented by a char device (/dev/vduse/$NAME) */
|
||||
#define VDUSE_CREATE_DEV _IOW(VDUSE_BASE, 0x02, struct vduse_dev_config)
|
||||
|
||||
/*
|
||||
* Destroy a VDUSE device. Make sure there are no more references
|
||||
* to the char device (/dev/vduse/$NAME).
|
||||
*/
|
||||
#define VDUSE_DESTROY_DEV _IOW(VDUSE_BASE, 0x03, char[VDUSE_NAME_MAX])
|
||||
|
||||
/* The ioctls for VDUSE device (/dev/vduse/$NAME) */
|
||||
|
||||
/**
|
||||
* struct vduse_iotlb_entry - entry of IOTLB to describe one IOVA region [start, last]
|
||||
* @offset: the mmap offset on returned file descriptor
|
||||
* @start: start of the IOVA region
|
||||
* @last: last of the IOVA region
|
||||
* @perm: access permission of the IOVA region
|
||||
*
|
||||
* Structure used by VDUSE_IOTLB_GET_FD ioctl to find an overlapped IOVA region.
|
||||
*/
|
||||
struct vduse_iotlb_entry {
|
||||
__u64 offset;
|
||||
__u64 start;
|
||||
__u64 last;
|
||||
#define VDUSE_ACCESS_RO 0x1
|
||||
#define VDUSE_ACCESS_WO 0x2
|
||||
#define VDUSE_ACCESS_RW 0x3
|
||||
__u8 perm;
|
||||
};
|
||||
|
||||
/*
|
||||
* Find the first IOVA region that overlaps with the range [start, last]
|
||||
* and return the corresponding file descriptor. Return -EINVAL means the
|
||||
* IOVA region doesn't exist. Caller should set start and last fields.
|
||||
*/
|
||||
#define VDUSE_IOTLB_GET_FD _IOWR(VDUSE_BASE, 0x10, struct vduse_iotlb_entry)
|
||||
|
||||
/*
|
||||
* Get the negotiated virtio features. It's a subset of the features in
|
||||
* struct vduse_dev_config which can be accepted by virtio driver. It's
|
||||
* only valid after FEATURES_OK status bit is set.
|
||||
*/
|
||||
#define VDUSE_DEV_GET_FEATURES _IOR(VDUSE_BASE, 0x11, __u64)
|
||||
|
||||
/**
|
||||
* struct vduse_config_data - data used to update configuration space
|
||||
* @offset: the offset from the beginning of configuration space
|
||||
* @length: the length to write to configuration space
|
||||
* @buffer: the buffer used to write from
|
||||
*
|
||||
* Structure used by VDUSE_DEV_SET_CONFIG ioctl to update device
|
||||
* configuration space.
|
||||
*/
|
||||
struct vduse_config_data {
|
||||
__u32 offset;
|
||||
__u32 length;
|
||||
__u8 buffer[];
|
||||
};
|
||||
|
||||
/* Set device configuration space */
|
||||
#define VDUSE_DEV_SET_CONFIG _IOW(VDUSE_BASE, 0x12, struct vduse_config_data)
|
||||
|
||||
/*
|
||||
* Inject a config interrupt. It's usually used to notify virtio driver
|
||||
* that device configuration space has changed.
|
||||
*/
|
||||
#define VDUSE_DEV_INJECT_CONFIG_IRQ _IO(VDUSE_BASE, 0x13)
|
||||
|
||||
/**
|
||||
* struct vduse_vq_config - basic configuration of a virtqueue
|
||||
* @index: virtqueue index
|
||||
* @max_size: the max size of virtqueue
|
||||
* @reserved: for future use, needs to be initialized to zero
|
||||
*
|
||||
* Structure used by VDUSE_VQ_SETUP ioctl to setup a virtqueue.
|
||||
*/
|
||||
struct vduse_vq_config {
|
||||
__u32 index;
|
||||
__u16 max_size;
|
||||
__u16 reserved[13];
|
||||
};
|
||||
|
||||
/*
|
||||
* Setup the specified virtqueue. Make sure all virtqueues have been
|
||||
* configured before the device is attached to vDPA bus.
|
||||
*/
|
||||
#define VDUSE_VQ_SETUP _IOW(VDUSE_BASE, 0x14, struct vduse_vq_config)
|
||||
|
||||
/**
|
||||
* struct vduse_vq_state_split - split virtqueue state
|
||||
* @avail_index: available index
|
||||
*/
|
||||
struct vduse_vq_state_split {
|
||||
__u16 avail_index;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_vq_state_packed - packed virtqueue state
|
||||
* @last_avail_counter: last driver ring wrap counter observed by device
|
||||
* @last_avail_idx: device available index
|
||||
* @last_used_counter: device ring wrap counter
|
||||
* @last_used_idx: used index
|
||||
*/
|
||||
struct vduse_vq_state_packed {
|
||||
__u16 last_avail_counter;
|
||||
__u16 last_avail_idx;
|
||||
__u16 last_used_counter;
|
||||
__u16 last_used_idx;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_vq_info - information of a virtqueue
|
||||
* @index: virtqueue index
|
||||
* @num: the size of virtqueue
|
||||
* @desc_addr: address of desc area
|
||||
* @driver_addr: address of driver area
|
||||
* @device_addr: address of device area
|
||||
* @split: split virtqueue state
|
||||
* @packed: packed virtqueue state
|
||||
* @ready: ready status of virtqueue
|
||||
*
|
||||
* Structure used by VDUSE_VQ_GET_INFO ioctl to get virtqueue's information.
|
||||
*/
|
||||
struct vduse_vq_info {
|
||||
__u32 index;
|
||||
__u32 num;
|
||||
__u64 desc_addr;
|
||||
__u64 driver_addr;
|
||||
__u64 device_addr;
|
||||
union {
|
||||
struct vduse_vq_state_split split;
|
||||
struct vduse_vq_state_packed packed;
|
||||
};
|
||||
__u8 ready;
|
||||
};
|
||||
|
||||
/* Get the specified virtqueue's information. Caller should set index field. */
|
||||
#define VDUSE_VQ_GET_INFO _IOWR(VDUSE_BASE, 0x15, struct vduse_vq_info)
|
||||
|
||||
/**
|
||||
* struct vduse_vq_eventfd - eventfd configuration for a virtqueue
|
||||
* @index: virtqueue index
|
||||
* @fd: eventfd, -1 means de-assigning the eventfd
|
||||
*
|
||||
* Structure used by VDUSE_VQ_SETUP_KICKFD ioctl to setup kick eventfd.
|
||||
*/
|
||||
struct vduse_vq_eventfd {
|
||||
__u32 index;
|
||||
#define VDUSE_EVENTFD_DEASSIGN -1
|
||||
int fd;
|
||||
};
|
||||
|
||||
/*
|
||||
* Setup kick eventfd for specified virtqueue. The kick eventfd is used
|
||||
* by VDUSE kernel module to notify userspace to consume the avail vring.
|
||||
*/
|
||||
#define VDUSE_VQ_SETUP_KICKFD _IOW(VDUSE_BASE, 0x16, struct vduse_vq_eventfd)
|
||||
|
||||
/*
|
||||
* Inject an interrupt for specific virtqueue. It's used to notify virtio driver
|
||||
* to consume the used vring.
|
||||
*/
|
||||
#define VDUSE_VQ_INJECT_IRQ _IOW(VDUSE_BASE, 0x17, __u32)
|
||||
|
||||
/* The control messages definition for read(2)/write(2) on /dev/vduse/$NAME */
|
||||
|
||||
/**
|
||||
* enum vduse_req_type - request type
|
||||
* @VDUSE_GET_VQ_STATE: get the state for specified virtqueue from userspace
|
||||
* @VDUSE_SET_STATUS: set the device status
|
||||
* @VDUSE_UPDATE_IOTLB: Notify userspace to update the memory mapping for
|
||||
* specified IOVA range via VDUSE_IOTLB_GET_FD ioctl
|
||||
*/
|
||||
enum vduse_req_type {
|
||||
VDUSE_GET_VQ_STATE,
|
||||
VDUSE_SET_STATUS,
|
||||
VDUSE_UPDATE_IOTLB,
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_vq_state - virtqueue state
|
||||
* @index: virtqueue index
|
||||
* @split: split virtqueue state
|
||||
* @packed: packed virtqueue state
|
||||
*/
|
||||
struct vduse_vq_state {
|
||||
__u32 index;
|
||||
union {
|
||||
struct vduse_vq_state_split split;
|
||||
struct vduse_vq_state_packed packed;
|
||||
};
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_dev_status - device status
|
||||
* @status: device status
|
||||
*/
|
||||
struct vduse_dev_status {
|
||||
__u8 status;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_iova_range - IOVA range [start, last]
|
||||
* @start: start of the IOVA range
|
||||
* @last: last of the IOVA range
|
||||
*/
|
||||
struct vduse_iova_range {
|
||||
__u64 start;
|
||||
__u64 last;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_dev_request - control request
|
||||
* @type: request type
|
||||
* @request_id: request id
|
||||
* @reserved: for future use
|
||||
* @vq_state: virtqueue state, only index field is available
|
||||
* @s: device status
|
||||
* @iova: IOVA range for updating
|
||||
* @padding: padding
|
||||
*
|
||||
* Structure used by read(2) on /dev/vduse/$NAME.
|
||||
*/
|
||||
struct vduse_dev_request {
|
||||
__u32 type;
|
||||
__u32 request_id;
|
||||
__u32 reserved[4];
|
||||
union {
|
||||
struct vduse_vq_state vq_state;
|
||||
struct vduse_dev_status s;
|
||||
struct vduse_iova_range iova;
|
||||
__u32 padding[32];
|
||||
};
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vduse_dev_response - response to control request
|
||||
* @request_id: corresponding request id
|
||||
* @result: the result of request
|
||||
* @reserved: for future use, needs to be initialized to zero
|
||||
* @vq_state: virtqueue state
|
||||
* @padding: padding
|
||||
*
|
||||
* Structure used by write(2) on /dev/vduse/$NAME.
|
||||
*/
|
||||
struct vduse_dev_response {
|
||||
__u32 request_id;
|
||||
#define VDUSE_REQ_RESULT_OK 0x00
|
||||
#define VDUSE_REQ_RESULT_FAILED 0x01
|
||||
__u32 result;
|
||||
__u32 reserved[4];
|
||||
union {
|
||||
struct vduse_vq_state vq_state;
|
||||
__u32 padding[32];
|
||||
};
|
||||
};
|
||||
|
||||
#endif /* _UAPI_VDUSE_H_ */
|
||||
47
include/uapi/linux/virtio_gpio.h
Normal file
47
include/uapi/linux/virtio_gpio.h
Normal file
@@ -0,0 +1,47 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
|
||||
|
||||
#ifndef _LINUX_VIRTIO_GPIO_H
|
||||
#define _LINUX_VIRTIO_GPIO_H
|
||||
|
||||
#include <linux/types.h>
|
||||
|
||||
/* Virtio GPIO request types */
|
||||
#define VIRTIO_GPIO_MSG_GET_NAMES 0x0001
|
||||
#define VIRTIO_GPIO_MSG_GET_DIRECTION 0x0002
|
||||
#define VIRTIO_GPIO_MSG_SET_DIRECTION 0x0003
|
||||
#define VIRTIO_GPIO_MSG_GET_VALUE 0x0004
|
||||
#define VIRTIO_GPIO_MSG_SET_VALUE 0x0005
|
||||
|
||||
/* Possible values of the status field */
|
||||
#define VIRTIO_GPIO_STATUS_OK 0x0
|
||||
#define VIRTIO_GPIO_STATUS_ERR 0x1
|
||||
|
||||
/* Direction types */
|
||||
#define VIRTIO_GPIO_DIRECTION_NONE 0x00
|
||||
#define VIRTIO_GPIO_DIRECTION_OUT 0x01
|
||||
#define VIRTIO_GPIO_DIRECTION_IN 0x02
|
||||
|
||||
struct virtio_gpio_config {
|
||||
__le16 ngpio;
|
||||
__u8 padding[2];
|
||||
__le32 gpio_names_size;
|
||||
} __packed;
|
||||
|
||||
/* Virtio GPIO Request / Response */
|
||||
struct virtio_gpio_request {
|
||||
__le16 type;
|
||||
__le16 gpio;
|
||||
__le32 value;
|
||||
};
|
||||
|
||||
struct virtio_gpio_response {
|
||||
__u8 status;
|
||||
__u8 value;
|
||||
};
|
||||
|
||||
struct virtio_gpio_response_get_names {
|
||||
__u8 status;
|
||||
__u8 value[];
|
||||
};
|
||||
|
||||
#endif /* _LINUX_VIRTIO_GPIO_H */
|
||||
41
include/uapi/linux/virtio_i2c.h
Normal file
41
include/uapi/linux/virtio_i2c.h
Normal file
@@ -0,0 +1,41 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0-or-later WITH Linux-syscall-note */
|
||||
/*
|
||||
* Definitions for virtio I2C Adpter
|
||||
*
|
||||
* Copyright (c) 2021 Intel Corporation. All rights reserved.
|
||||
*/
|
||||
|
||||
#ifndef _UAPI_LINUX_VIRTIO_I2C_H
|
||||
#define _UAPI_LINUX_VIRTIO_I2C_H
|
||||
|
||||
#include <linux/const.h>
|
||||
#include <linux/types.h>
|
||||
|
||||
/* The bit 0 of the @virtio_i2c_out_hdr.@flags, used to group the requests */
|
||||
#define VIRTIO_I2C_FLAGS_FAIL_NEXT _BITUL(0)
|
||||
|
||||
/**
|
||||
* struct virtio_i2c_out_hdr - the virtio I2C message OUT header
|
||||
* @addr: the controlled device address
|
||||
* @padding: used to pad to full dword
|
||||
* @flags: used for feature extensibility
|
||||
*/
|
||||
struct virtio_i2c_out_hdr {
|
||||
__le16 addr;
|
||||
__le16 padding;
|
||||
__le32 flags;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct virtio_i2c_in_hdr - the virtio I2C message IN header
|
||||
* @status: the processing result from the backend
|
||||
*/
|
||||
struct virtio_i2c_in_hdr {
|
||||
__u8 status;
|
||||
};
|
||||
|
||||
/* The final status written by the device */
|
||||
#define VIRTIO_I2C_MSG_OK 0
|
||||
#define VIRTIO_I2C_MSG_ERR 1
|
||||
|
||||
#endif /* _UAPI_LINUX_VIRTIO_I2C_H */
|
||||
@@ -54,8 +54,20 @@
|
||||
#define VIRTIO_ID_SOUND 25 /* virtio sound */
|
||||
#define VIRTIO_ID_FS 26 /* virtio filesystem */
|
||||
#define VIRTIO_ID_PMEM 27 /* virtio pmem */
|
||||
#define VIRTIO_ID_RPMB 28 /* virtio rpmb */
|
||||
#define VIRTIO_ID_MAC80211_HWSIM 29 /* virtio mac80211-hwsim */
|
||||
#define VIRTIO_ID_VIDEO_ENCODER 30 /* virtio video encoder */
|
||||
#define VIRTIO_ID_VIDEO_DECODER 31 /* virtio video decoder */
|
||||
#define VIRTIO_ID_SCMI 32 /* virtio SCMI */
|
||||
#define VIRTIO_ID_NITRO_SEC_MOD 33 /* virtio nitro secure module*/
|
||||
#define VIRTIO_ID_I2C_ADAPTER 34 /* virtio i2c adapter */
|
||||
#define VIRTIO_ID_WATCHDOG 35 /* virtio watchdog */
|
||||
#define VIRTIO_ID_CAN 36 /* virtio can */
|
||||
#define VIRTIO_ID_DMABUF 37 /* virtio dmabuf */
|
||||
#define VIRTIO_ID_PARAM_SERV 38 /* virtio parameter server */
|
||||
#define VIRTIO_ID_AUDIO_POLICY 39 /* virtio audio policy */
|
||||
#define VIRTIO_ID_BT 40 /* virtio bluetooth */
|
||||
#define VIRTIO_ID_GPIO 41 /* virtio gpio */
|
||||
|
||||
/*
|
||||
* Virtio Transitional IDs
|
||||
|
||||
@@ -9,13 +9,14 @@
|
||||
|
||||
/**
|
||||
* enum virtio_pcidev_ops - virtual PCI device operations
|
||||
* @VIRTIO_PCIDEV_OP_RESERVED: reserved to catch errors
|
||||
* @VIRTIO_PCIDEV_OP_CFG_READ: read config space, size is 1, 2, 4 or 8;
|
||||
* the @data field should be filled in by the device (in little endian).
|
||||
* @VIRTIO_PCIDEV_OP_CFG_WRITE: write config space, size is 1, 2, 4 or 8;
|
||||
* the @data field contains the data to write (in little endian).
|
||||
* @VIRTIO_PCIDEV_OP_BAR_READ: read BAR mem/pio, size can be variable;
|
||||
* @VIRTIO_PCIDEV_OP_MMIO_READ: read BAR mem/pio, size can be variable;
|
||||
* the @data field should be filled in by the device (in little endian).
|
||||
* @VIRTIO_PCIDEV_OP_BAR_WRITE: write BAR mem/pio, size can be variable;
|
||||
* @VIRTIO_PCIDEV_OP_MMIO_WRITE: write BAR mem/pio, size can be variable;
|
||||
* the @data field contains the data to write (in little endian).
|
||||
* @VIRTIO_PCIDEV_OP_MMIO_MEMSET: memset MMIO, size is variable but
|
||||
* the @data field only has one byte (unlike @VIRTIO_PCIDEV_OP_MMIO_WRITE)
|
||||
|
||||
24
include/uapi/linux/virtio_scmi.h
Normal file
24
include/uapi/linux/virtio_scmi.h
Normal file
@@ -0,0 +1,24 @@
|
||||
/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
|
||||
/*
|
||||
* Copyright (C) 2020-2021 OpenSynergy GmbH
|
||||
* Copyright (C) 2021 ARM Ltd.
|
||||
*/
|
||||
|
||||
#ifndef _UAPI_LINUX_VIRTIO_SCMI_H
|
||||
#define _UAPI_LINUX_VIRTIO_SCMI_H
|
||||
|
||||
#include <linux/virtio_types.h>
|
||||
|
||||
/* Device implements some SCMI notifications, or delayed responses. */
|
||||
#define VIRTIO_SCMI_F_P2A_CHANNELS 0
|
||||
|
||||
/* Device implements any SCMI statistics shared memory region */
|
||||
#define VIRTIO_SCMI_F_SHARED_MEMORY 1
|
||||
|
||||
/* Virtqueues */
|
||||
|
||||
#define VIRTIO_SCMI_VQ_TX 0 /* cmdq */
|
||||
#define VIRTIO_SCMI_VQ_RX 1 /* eventq */
|
||||
#define VIRTIO_SCMI_VQ_MAX_CNT 2
|
||||
|
||||
#endif /* _UAPI_LINUX_VIRTIO_SCMI_H */
|
||||
@@ -97,7 +97,8 @@ enum virtio_vsock_shutdown {
|
||||
|
||||
/* VIRTIO_VSOCK_OP_RW flags values */
|
||||
enum virtio_vsock_rw {
|
||||
VIRTIO_VSOCK_SEQ_EOR = 1,
|
||||
VIRTIO_VSOCK_SEQ_EOM = 1,
|
||||
VIRTIO_VSOCK_SEQ_EOR = 2,
|
||||
};
|
||||
|
||||
#endif /* _UAPI_LINUX_VIRTIO_VSOCK_H */
|
||||
|
||||
@@ -215,6 +215,11 @@ enum {
|
||||
|
||||
XFRM_MSG_MAPPING,
|
||||
#define XFRM_MSG_MAPPING XFRM_MSG_MAPPING
|
||||
|
||||
XFRM_MSG_SETDEFAULT,
|
||||
#define XFRM_MSG_SETDEFAULT XFRM_MSG_SETDEFAULT
|
||||
XFRM_MSG_GETDEFAULT,
|
||||
#define XFRM_MSG_GETDEFAULT XFRM_MSG_GETDEFAULT
|
||||
__XFRM_MSG_MAX
|
||||
};
|
||||
#define XFRM_MSG_MAX (__XFRM_MSG_MAX - 1)
|
||||
@@ -508,6 +513,15 @@ struct xfrm_user_offload {
|
||||
#define XFRM_OFFLOAD_IPV6 1
|
||||
#define XFRM_OFFLOAD_INBOUND 2
|
||||
|
||||
struct xfrm_userpolicy_default {
|
||||
#define XFRM_USERPOLICY_UNSPEC 0
|
||||
#define XFRM_USERPOLICY_BLOCK 1
|
||||
#define XFRM_USERPOLICY_ACCEPT 2
|
||||
__u8 in;
|
||||
__u8 fwd;
|
||||
__u8 out;
|
||||
};
|
||||
|
||||
#ifndef __KERNEL__
|
||||
/* backwards compatibility for userspace */
|
||||
#define XFRMGRP_ACQUIRE 1
|
||||
|
||||
Reference in New Issue
Block a user