Merge drm/drm-next into drm-intel-gt-next
Matt needed some buddy allocator changes for landing DG2 small BAR support patches. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
This commit is contained in:
commit
db927686e4
1576 changed files with 272456 additions and 25573 deletions
|
|
@ -206,6 +206,8 @@ union drm_amdgpu_bo_list {
|
|||
#define AMDGPU_CTX_OP_FREE_CTX 2
|
||||
#define AMDGPU_CTX_OP_QUERY_STATE 3
|
||||
#define AMDGPU_CTX_OP_QUERY_STATE2 4
|
||||
#define AMDGPU_CTX_OP_GET_STABLE_PSTATE 5
|
||||
#define AMDGPU_CTX_OP_SET_STABLE_PSTATE 6
|
||||
|
||||
/* GPU reset status */
|
||||
#define AMDGPU_CTX_NO_RESET 0
|
||||
|
|
@ -238,10 +240,18 @@ union drm_amdgpu_bo_list {
|
|||
#define AMDGPU_CTX_PRIORITY_HIGH 512
|
||||
#define AMDGPU_CTX_PRIORITY_VERY_HIGH 1023
|
||||
|
||||
/* select a stable profiling pstate for perfmon tools */
|
||||
#define AMDGPU_CTX_STABLE_PSTATE_FLAGS_MASK 0xf
|
||||
#define AMDGPU_CTX_STABLE_PSTATE_NONE 0
|
||||
#define AMDGPU_CTX_STABLE_PSTATE_STANDARD 1
|
||||
#define AMDGPU_CTX_STABLE_PSTATE_MIN_SCLK 2
|
||||
#define AMDGPU_CTX_STABLE_PSTATE_MIN_MCLK 3
|
||||
#define AMDGPU_CTX_STABLE_PSTATE_PEAK 4
|
||||
|
||||
struct drm_amdgpu_ctx_in {
|
||||
/** AMDGPU_CTX_OP_* */
|
||||
__u32 op;
|
||||
/** For future use, no flags defined so far */
|
||||
/** Flags */
|
||||
__u32 flags;
|
||||
__u32 ctx_id;
|
||||
/** AMDGPU_CTX_PRIORITY_* */
|
||||
|
|
@ -262,6 +272,11 @@ union drm_amdgpu_ctx_out {
|
|||
/** Reset status since the last call of the ioctl. */
|
||||
__u32 reset_status;
|
||||
} state;
|
||||
|
||||
struct {
|
||||
__u32 flags;
|
||||
__u32 _pad;
|
||||
} pstate;
|
||||
};
|
||||
|
||||
union drm_amdgpu_ctx {
|
||||
|
|
@ -728,6 +743,8 @@ struct drm_amdgpu_cs_chunk_data {
|
|||
#define AMDGPU_INFO_FW_DMCUB 0x14
|
||||
/* Subquery id: Query TOC firmware version */
|
||||
#define AMDGPU_INFO_FW_TOC 0x15
|
||||
/* Subquery id: Query CAP firmware version */
|
||||
#define AMDGPU_INFO_FW_CAP 0x16
|
||||
|
||||
/* number of bytes moved for TTM migration */
|
||||
#define AMDGPU_INFO_NUM_BYTES_MOVED 0x0f
|
||||
|
|
@ -1134,6 +1151,8 @@ struct drm_amdgpu_info_video_caps {
|
|||
#define AMDGPU_FAMILY_NV 143 /* Navi10 */
|
||||
#define AMDGPU_FAMILY_VGH 144 /* Van Gogh */
|
||||
#define AMDGPU_FAMILY_YC 146 /* Yellow Carp */
|
||||
#define AMDGPU_FAMILY_GC_10_3_6 149 /* GC 10.3.6 */
|
||||
#define AMDGPU_FAMILY_GC_10_3_7 151 /* GC 10.3.7 */
|
||||
|
||||
#if defined(__cplusplus)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -663,41 +663,73 @@ struct drm_mode_fb_cmd {
|
|||
#define DRM_MODE_FB_INTERLACED (1<<0) /* for interlaced framebuffers */
|
||||
#define DRM_MODE_FB_MODIFIERS (1<<1) /* enables ->modifer[] */
|
||||
|
||||
/**
|
||||
* struct drm_mode_fb_cmd2 - Frame-buffer metadata.
|
||||
*
|
||||
* This struct holds frame-buffer metadata. There are two ways to use it:
|
||||
*
|
||||
* - User-space can fill this struct and perform a &DRM_IOCTL_MODE_ADDFB2
|
||||
* ioctl to register a new frame-buffer. The new frame-buffer object ID will
|
||||
* be set by the kernel in @fb_id.
|
||||
* - User-space can set @fb_id and perform a &DRM_IOCTL_MODE_GETFB2 ioctl to
|
||||
* fetch metadata about an existing frame-buffer.
|
||||
*
|
||||
* In case of planar formats, this struct allows up to 4 buffer objects with
|
||||
* offsets and pitches per plane. The pitch and offset order is dictated by the
|
||||
* format FourCC as defined by ``drm_fourcc.h``, e.g. NV12 is described as:
|
||||
*
|
||||
* YUV 4:2:0 image with a plane of 8 bit Y samples followed by an
|
||||
* interleaved U/V plane containing 8 bit 2x2 subsampled colour difference
|
||||
* samples.
|
||||
*
|
||||
* So it would consist of a Y plane at ``offsets[0]`` and a UV plane at
|
||||
* ``offsets[1]``.
|
||||
*
|
||||
* To accommodate tiled, compressed, etc formats, a modifier can be specified.
|
||||
* For more information see the "Format Modifiers" section. Note that even
|
||||
* though it looks like we have a modifier per-plane, we in fact do not. The
|
||||
* modifier for each plane must be identical. Thus all combinations of
|
||||
* different data layouts for multi-plane formats must be enumerated as
|
||||
* separate modifiers.
|
||||
*
|
||||
* All of the entries in @handles, @pitches, @offsets and @modifier must be
|
||||
* zero when unused. Warning, for @offsets and @modifier zero can't be used to
|
||||
* figure out whether the entry is used or not since it's a valid value (a zero
|
||||
* offset is common, and a zero modifier is &DRM_FORMAT_MOD_LINEAR).
|
||||
*/
|
||||
struct drm_mode_fb_cmd2 {
|
||||
/** @fb_id: Object ID of the frame-buffer. */
|
||||
__u32 fb_id;
|
||||
/** @width: Width of the frame-buffer. */
|
||||
__u32 width;
|
||||
/** @height: Height of the frame-buffer. */
|
||||
__u32 height;
|
||||
__u32 pixel_format; /* fourcc code from drm_fourcc.h */
|
||||
__u32 flags; /* see above flags */
|
||||
/**
|
||||
* @pixel_format: FourCC format code, see ``DRM_FORMAT_*`` constants in
|
||||
* ``drm_fourcc.h``.
|
||||
*/
|
||||
__u32 pixel_format;
|
||||
/**
|
||||
* @flags: Frame-buffer flags (see &DRM_MODE_FB_INTERLACED and
|
||||
* &DRM_MODE_FB_MODIFIERS).
|
||||
*/
|
||||
__u32 flags;
|
||||
|
||||
/*
|
||||
* In case of planar formats, this ioctl allows up to 4
|
||||
* buffer objects with offsets and pitches per plane.
|
||||
* The pitch and offset order is dictated by the fourcc,
|
||||
* e.g. NV12 (https://fourcc.org/yuv.php#NV12) is described as:
|
||||
*
|
||||
* YUV 4:2:0 image with a plane of 8 bit Y samples
|
||||
* followed by an interleaved U/V plane containing
|
||||
* 8 bit 2x2 subsampled colour difference samples.
|
||||
*
|
||||
* So it would consist of Y as offsets[0] and UV as
|
||||
* offsets[1]. Note that offsets[0] will generally
|
||||
* be 0 (but this is not required).
|
||||
*
|
||||
* To accommodate tiled, compressed, etc formats, a
|
||||
* modifier can be specified. The default value of zero
|
||||
* indicates "native" format as specified by the fourcc.
|
||||
* Vendor specific modifier token. Note that even though
|
||||
* it looks like we have a modifier per-plane, we in fact
|
||||
* do not. The modifier for each plane must be identical.
|
||||
* Thus all combinations of different data layouts for
|
||||
* multi plane formats must be enumerated as separate
|
||||
* modifiers.
|
||||
/**
|
||||
* @handles: GEM buffer handle, one per plane. Set to 0 if the plane is
|
||||
* unused. The same handle can be used for multiple planes.
|
||||
*/
|
||||
__u32 handles[4];
|
||||
__u32 pitches[4]; /* pitch for each plane */
|
||||
__u32 offsets[4]; /* offset of each plane */
|
||||
__u64 modifier[4]; /* ie, tiling, compress */
|
||||
/** @pitches: Pitch (aka. stride) in bytes, one per plane. */
|
||||
__u32 pitches[4];
|
||||
/** @offsets: Offset into the buffer in bytes, one per plane. */
|
||||
__u32 offsets[4];
|
||||
/**
|
||||
* @modifier: Format modifier, one per plane. See ``DRM_FORMAT_MOD_*``
|
||||
* constants in ``drm_fourcc.h``. All planes must use the same
|
||||
* modifier. Ignored unless &DRM_MODE_FB_MODIFIERS is set in @flags.
|
||||
*/
|
||||
__u64 modifier[4];
|
||||
};
|
||||
|
||||
#define DRM_MODE_FB_DIRTY_ANNOTATE_COPY 0x01
|
||||
|
|
|
|||
|
|
@ -32,9 +32,10 @@
|
|||
* - 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
|
||||
* - 1.7 - Checkpoint Restore (CRIU) API
|
||||
*/
|
||||
#define KFD_IOCTL_MAJOR_VERSION 1
|
||||
#define KFD_IOCTL_MINOR_VERSION 6
|
||||
#define KFD_IOCTL_MINOR_VERSION 7
|
||||
|
||||
struct kfd_ioctl_get_version_args {
|
||||
__u32 major_version; /* from KFD */
|
||||
|
|
@ -468,6 +469,82 @@ struct kfd_ioctl_smi_events_args {
|
|||
__u32 anon_fd; /* from KFD */
|
||||
};
|
||||
|
||||
/**************************************************************************************************
|
||||
* CRIU IOCTLs (Checkpoint Restore In Userspace)
|
||||
*
|
||||
* When checkpointing a process, the userspace application will perform:
|
||||
* 1. PROCESS_INFO op to determine current process information. This pauses execution and evicts
|
||||
* all the queues.
|
||||
* 2. CHECKPOINT op to checkpoint process contents (BOs, queues, events, svm-ranges)
|
||||
* 3. UNPAUSE op to un-evict all the queues
|
||||
*
|
||||
* When restoring a process, the CRIU userspace application will perform:
|
||||
*
|
||||
* 1. RESTORE op to restore process contents
|
||||
* 2. RESUME op to start the process
|
||||
*
|
||||
* Note: Queues are forced into an evicted state after a successful PROCESS_INFO. User
|
||||
* application needs to perform an UNPAUSE operation after calling PROCESS_INFO.
|
||||
*/
|
||||
|
||||
enum kfd_criu_op {
|
||||
KFD_CRIU_OP_PROCESS_INFO,
|
||||
KFD_CRIU_OP_CHECKPOINT,
|
||||
KFD_CRIU_OP_UNPAUSE,
|
||||
KFD_CRIU_OP_RESTORE,
|
||||
KFD_CRIU_OP_RESUME,
|
||||
};
|
||||
|
||||
/**
|
||||
* kfd_ioctl_criu_args - Arguments perform CRIU operation
|
||||
* @devices: [in/out] User pointer to memory location for devices information.
|
||||
* This is an array of type kfd_criu_device_bucket.
|
||||
* @bos: [in/out] User pointer to memory location for BOs information
|
||||
* This is an array of type kfd_criu_bo_bucket.
|
||||
* @priv_data: [in/out] User pointer to memory location for private data
|
||||
* @priv_data_size: [in/out] Size of priv_data in bytes
|
||||
* @num_devices: [in/out] Number of GPUs used by process. Size of @devices array.
|
||||
* @num_bos [in/out] Number of BOs used by process. Size of @bos array.
|
||||
* @num_objects: [in/out] Number of objects used by process. Objects are opaque to
|
||||
* user application.
|
||||
* @pid: [in/out] PID of the process being checkpointed
|
||||
* @op [in] Type of operation (kfd_criu_op)
|
||||
*
|
||||
* Return: 0 on success, -errno on failure
|
||||
*/
|
||||
struct kfd_ioctl_criu_args {
|
||||
__u64 devices; /* Used during ops: CHECKPOINT, RESTORE */
|
||||
__u64 bos; /* Used during ops: CHECKPOINT, RESTORE */
|
||||
__u64 priv_data; /* Used during ops: CHECKPOINT, RESTORE */
|
||||
__u64 priv_data_size; /* Used during ops: PROCESS_INFO, RESTORE */
|
||||
__u32 num_devices; /* Used during ops: PROCESS_INFO, RESTORE */
|
||||
__u32 num_bos; /* Used during ops: PROCESS_INFO, RESTORE */
|
||||
__u32 num_objects; /* Used during ops: PROCESS_INFO, RESTORE */
|
||||
__u32 pid; /* Used during ops: PROCESS_INFO, RESUME */
|
||||
__u32 op;
|
||||
};
|
||||
|
||||
struct kfd_criu_device_bucket {
|
||||
__u32 user_gpu_id;
|
||||
__u32 actual_gpu_id;
|
||||
__u32 drm_fd;
|
||||
__u32 pad;
|
||||
};
|
||||
|
||||
struct kfd_criu_bo_bucket {
|
||||
__u64 addr;
|
||||
__u64 size;
|
||||
__u64 offset;
|
||||
__u64 restored_offset; /* During restore, updated offset for BO */
|
||||
__u32 gpu_id; /* This is the user_gpu_id */
|
||||
__u32 alloc_flags;
|
||||
__u32 dmabuf_fd;
|
||||
__u32 pad;
|
||||
};
|
||||
|
||||
/* CRIU IOCTLs - END */
|
||||
/**************************************************************************************************/
|
||||
|
||||
/* Register offset inside the remapped mmio page
|
||||
*/
|
||||
enum kfd_mmio_remap {
|
||||
|
|
@ -596,7 +673,7 @@ struct kfd_ioctl_svm_args {
|
|||
__u32 op;
|
||||
__u32 nattr;
|
||||
/* Variable length array of attributes */
|
||||
struct kfd_ioctl_svm_attribute attrs[0];
|
||||
struct kfd_ioctl_svm_attribute attrs[];
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -679,16 +756,16 @@ struct kfd_ioctl_set_xnack_mode_args {
|
|||
#define AMDKFD_IOC_WAIT_EVENTS \
|
||||
AMDKFD_IOWR(0x0C, struct kfd_ioctl_wait_events_args)
|
||||
|
||||
#define AMDKFD_IOC_DBG_REGISTER \
|
||||
#define AMDKFD_IOC_DBG_REGISTER_DEPRECATED \
|
||||
AMDKFD_IOW(0x0D, struct kfd_ioctl_dbg_register_args)
|
||||
|
||||
#define AMDKFD_IOC_DBG_UNREGISTER \
|
||||
#define AMDKFD_IOC_DBG_UNREGISTER_DEPRECATED \
|
||||
AMDKFD_IOW(0x0E, struct kfd_ioctl_dbg_unregister_args)
|
||||
|
||||
#define AMDKFD_IOC_DBG_ADDRESS_WATCH \
|
||||
#define AMDKFD_IOC_DBG_ADDRESS_WATCH_DEPRECATED \
|
||||
AMDKFD_IOW(0x0F, struct kfd_ioctl_dbg_address_watch_args)
|
||||
|
||||
#define AMDKFD_IOC_DBG_WAVE_CONTROL \
|
||||
#define AMDKFD_IOC_DBG_WAVE_CONTROL_DEPRECATED \
|
||||
AMDKFD_IOW(0x10, struct kfd_ioctl_dbg_wave_control_args)
|
||||
|
||||
#define AMDKFD_IOC_SET_SCRATCH_BACKING_VA \
|
||||
|
|
@ -742,7 +819,10 @@ struct kfd_ioctl_set_xnack_mode_args {
|
|||
#define AMDKFD_IOC_SET_XNACK_MODE \
|
||||
AMDKFD_IOWR(0x21, struct kfd_ioctl_set_xnack_mode_args)
|
||||
|
||||
#define AMDKFD_IOC_CRIU_OP \
|
||||
AMDKFD_IOWR(0x22, struct kfd_ioctl_criu_args)
|
||||
|
||||
#define AMDKFD_COMMAND_START 0x01
|
||||
#define AMDKFD_COMMAND_END 0x22
|
||||
#define AMDKFD_COMMAND_END 0x23
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1624,9 +1624,6 @@ struct kvm_enc_region {
|
|||
#define KVM_S390_NORMAL_RESET _IO(KVMIO, 0xc3)
|
||||
#define KVM_S390_CLEAR_RESET _IO(KVMIO, 0xc4)
|
||||
|
||||
/* Available with KVM_CAP_XSAVE2 */
|
||||
#define KVM_GET_XSAVE2 _IOR(KVMIO, 0xcf, struct kvm_xsave)
|
||||
|
||||
struct kvm_s390_pv_sec_parm {
|
||||
__u64 origin;
|
||||
__u64 length;
|
||||
|
|
@ -2048,4 +2045,7 @@ struct kvm_stats_desc {
|
|||
|
||||
#define KVM_GET_STATS_FD _IO(KVMIO, 0xce)
|
||||
|
||||
/* Available with KVM_CAP_XSAVE2 */
|
||||
#define KVM_GET_XSAVE2 _IOR(KVMIO, 0xcf, struct kvm_xsave)
|
||||
|
||||
#endif /* __LINUX_KVM_H */
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ enum ip_conntrack_status {
|
|||
IPS_NAT_CLASH = IPS_UNTRACKED,
|
||||
#endif
|
||||
|
||||
/* Conntrack got a helper explicitly attached via CT target. */
|
||||
/* Conntrack got a helper explicitly attached (ruleset, ctnetlink). */
|
||||
IPS_HELPER_BIT = 13,
|
||||
IPS_HELPER = (1 << IPS_HELPER_BIT),
|
||||
|
||||
|
|
|
|||
|
|
@ -465,6 +465,8 @@ struct perf_event_attr {
|
|||
/*
|
||||
* User provided data if sigtrap=1, passed back to user via
|
||||
* siginfo_t::si_perf_data, e.g. to permit user to identify the event.
|
||||
* Note, siginfo_t::si_perf_data is long-sized, and sig_data will be
|
||||
* truncated accordingly on 32 bit architectures.
|
||||
*/
|
||||
__u64 sig_data;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -84,12 +84,11 @@ struct smc_diag_conninfo {
|
|||
/* SMC_DIAG_LINKINFO */
|
||||
|
||||
struct smc_diag_linkinfo {
|
||||
__u8 link_id; /* link identifier */
|
||||
__u8 ibname[IB_DEVICE_NAME_MAX]; /* name of the RDMA device */
|
||||
__u8 ibport; /* RDMA device port number */
|
||||
__u8 gid[40]; /* local GID */
|
||||
__u8 peer_gid[40]; /* peer GID */
|
||||
__aligned_u64 net_cookie; /* RDMA device net namespace */
|
||||
__u8 link_id; /* link identifier */
|
||||
__u8 ibname[IB_DEVICE_NAME_MAX]; /* name of the RDMA device */
|
||||
__u8 ibport; /* RDMA device port number */
|
||||
__u8 gid[40]; /* local GID */
|
||||
__u8 peer_gid[40]; /* peer GID */
|
||||
};
|
||||
|
||||
struct smc_diag_lgrinfo {
|
||||
|
|
|
|||
|
|
@ -56,8 +56,10 @@
|
|||
* *
|
||||
****************************************************************************/
|
||||
|
||||
#define AES_IEC958_STATUS_SIZE 24
|
||||
|
||||
struct snd_aes_iec958 {
|
||||
unsigned char status[24]; /* AES/IEC958 channel status bits */
|
||||
unsigned char status[AES_IEC958_STATUS_SIZE]; /* AES/IEC958 channel status bits */
|
||||
unsigned char subcode[147]; /* AES/IEC958 subcode bits */
|
||||
unsigned char pad; /* nothing */
|
||||
unsigned char dig_subframe[4]; /* AES/IEC958 subframe bits */
|
||||
|
|
|
|||
|
|
@ -47,7 +47,13 @@ struct ioctl_gntdev_grant_ref {
|
|||
/*
|
||||
* Inserts the grant references into the mapping table of an instance
|
||||
* of gntdev. N.B. This does not perform the mapping, which is deferred
|
||||
* until mmap() is called with @index as the offset.
|
||||
* until mmap() is called with @index as the offset. @index should be
|
||||
* considered opaque to userspace, with one exception: if no grant
|
||||
* references have ever been inserted into the mapping table of this
|
||||
* instance, @index will be set to 0. This is necessary to use gntdev
|
||||
* with userspace APIs that expect a file descriptor that can be
|
||||
* mmap()'d at offset 0, such as Wayland. If @count is set to 0, this
|
||||
* ioctl will fail.
|
||||
*/
|
||||
#define IOCTL_GNTDEV_MAP_GRANT_REF \
|
||||
_IOC(_IOC_NONE, 'G', 0, sizeof(struct ioctl_gntdev_map_grant_ref))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue