drm-misc-next for v5.16:
UAPI Changes: - Allow empty drm leases for creating separate GEM namespaces. Cross-subsystem Changes: - Slightly rework dma_buf_poll. - Add dma_resv_for_each_fence_unlocked to iterate, and use it inside the lockless dma-resv functions. Core Changes: - Allow devm_drm_of_get_bridge to build without CONFIG_OF for compile testing. - Add more DP2 headers. - fix CONFIG_FB dependency in fb_helper. - Add DRM_FORMAT_R8 to drm_format_info, and helpers for RGB332 and RGB888. - Fix crash on a 0 or invalid EDID. Driver Changes: - Apply and revert DRM_MODESET_LOCK_ALL_BEGIN. - Add mode_valid to ti-sn65dsi86 bridge. - Support multiple syncobjs in v3d. - Add R8, RGB332 and RGB888 pixel formats to GUD. - Use devm_add_action_or_reset in dw-hdmi-cec. -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEuXvWqAysSYEJGuVH/lWMcqZwE8MFAmFdfuwACgkQ/lWMcqZw E8OTgg/+Nmsqhj1tsbSCWF1yx81CXHVSOhExPaMl+GPs6+y+sZ+U2rN99dnbULvA U56eOmjc8FvgmK89BwhSYNt++QYIRRpzjBGlCYm4bwpgqFOmYsK+en35PYMwHdxM Ke8newhzqa6/detvjX52igddZzrBv1Cs8aXuV5rw7Dg0ivlSlQUV0MO8JYwCliWI arRT8bg7wzUzhyRZqwqOqKXjvRirqBlFjJmvfL0WgHevZbzYuXbn4eWCUgCVthMH pU9QgK6FMW912pBxVppDO2aTDmNvqwj1BsB3RFfRuqS/JJ4s/gf39JxsipnI+/qn kPxZVFzzonR8Nl6h9sPi1jZrcVDCBebFgyG8hSgIVb/09U7AVYomtP18VKeh8yCy Pp4iQINqOcyMPmXKF491LIL92dcXZAIRaRQFKc/ZSHcfIDA7ZB1+7zf1ixBjlxjP GqtjLbmPspI2DzBRlTFEdf58jvX70E5nFYdQyYcy3VprJHuqEgL5PKz2Xcnve6R0 dEkGA2vMrGtb23YyjbFTNfkdvg9WYXze9HbQLt7kc8mI77TugkG0/rCcwv5pEEu3 WSwqMeb+5H+7va4AI715MoXbxgnCba2zPTUm1s8kSqTK0Oighc/vWcnnJ4iVuEGE 8Xt8AIIYUtccufR6ujucVUh7nju2ZOnFE7S92LybnGnByAIADfM= =qxpr -----END PGP SIGNATURE----- Merge tag 'drm-misc-next-2021-10-06' of git://anongit.freedesktop.org/drm/drm-misc into drm-next drm-misc-next for v5.16: UAPI Changes: - Allow empty drm leases for creating separate GEM namespaces. Cross-subsystem Changes: - Slightly rework dma_buf_poll. - Add dma_resv_for_each_fence_unlocked to iterate, and use it inside the lockless dma-resv functions. Core Changes: - Allow devm_drm_of_get_bridge to build without CONFIG_OF for compile testing. - Add more DP2 headers. - fix CONFIG_FB dependency in fb_helper. - Add DRM_FORMAT_R8 to drm_format_info, and helpers for RGB332 and RGB888. - Fix crash on a 0 or invalid EDID. Driver Changes: - Apply and revert DRM_MODESET_LOCK_ALL_BEGIN. - Add mode_valid to ti-sn65dsi86 bridge. - Support multiple syncobjs in v3d. - Add R8, RGB332 and RGB888 pixel formats to GUD. - Use devm_add_action_or_reset in dw-hdmi-cec. Signed-off-by: Dave Airlie <airlied@redhat.com> # gpg: Signature made Wed 06 Oct 2021 20:48:12 AEST # gpg: using RSA key B97BD6A80CAC4981091AE547FE558C72A67013C3 # gpg: Good signature from "Maarten Lankhorst <maarten.lankhorst@linux.intel.com>" [expired] # gpg: aka "Maarten Lankhorst <maarten@debian.org>" [expired] # gpg: aka "Maarten Lankhorst <maarten.lankhorst@canonical.com>" [expired] # gpg: Note: This key has expired! # Primary key fingerprint: B97B D6A8 0CAC 4981 091A E547 FE55 8C72 A670 13C3 From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/2602f4e9-a8ac-83f8-6c2a-39fd9ca2e1ba@linux.intel.com
This commit is contained in:
commit
797d72ce8e
99 changed files with 3158 additions and 1141 deletions
|
|
@ -1112,7 +1112,8 @@ struct drm_mode_destroy_blob {
|
|||
* Lease mode resources, creating another drm_master.
|
||||
*
|
||||
* The @object_ids array must reference at least one CRTC, one connector and
|
||||
* one plane if &DRM_CLIENT_CAP_UNIVERSAL_PLANES is enabled.
|
||||
* one plane if &DRM_CLIENT_CAP_UNIVERSAL_PLANES is enabled. Alternatively,
|
||||
* the lease can be completely empty.
|
||||
*/
|
||||
struct drm_mode_create_lease {
|
||||
/** @object_ids: Pointer to array of object ids (__u32) */
|
||||
|
|
|
|||
|
|
@ -58,6 +58,67 @@ extern "C" {
|
|||
struct drm_v3d_perfmon_get_values)
|
||||
|
||||
#define DRM_V3D_SUBMIT_CL_FLUSH_CACHE 0x01
|
||||
#define DRM_V3D_SUBMIT_EXTENSION 0x02
|
||||
|
||||
/* struct drm_v3d_extension - ioctl extensions
|
||||
*
|
||||
* Linked-list of generic extensions where the id identify which struct is
|
||||
* pointed by ext_data. Therefore, DRM_V3D_EXT_ID_* is used on id to identify
|
||||
* the extension type.
|
||||
*/
|
||||
struct drm_v3d_extension {
|
||||
__u64 next;
|
||||
__u32 id;
|
||||
#define DRM_V3D_EXT_ID_MULTI_SYNC 0x01
|
||||
__u32 flags; /* mbz */
|
||||
};
|
||||
|
||||
/* struct drm_v3d_sem - wait/signal semaphore
|
||||
*
|
||||
* If binary semaphore, it only takes syncobj handle and ignores flags and
|
||||
* point fields. Point is defined for timeline syncobj feature.
|
||||
*/
|
||||
struct drm_v3d_sem {
|
||||
__u32 handle; /* syncobj */
|
||||
/* rsv below, for future uses */
|
||||
__u32 flags;
|
||||
__u64 point; /* for timeline sem support */
|
||||
__u64 mbz[2]; /* must be zero, rsv */
|
||||
};
|
||||
|
||||
/* Enum for each of the V3D queues. */
|
||||
enum v3d_queue {
|
||||
V3D_BIN,
|
||||
V3D_RENDER,
|
||||
V3D_TFU,
|
||||
V3D_CSD,
|
||||
V3D_CACHE_CLEAN,
|
||||
};
|
||||
|
||||
/**
|
||||
* struct drm_v3d_multi_sync - ioctl extension to add support multiples
|
||||
* syncobjs for commands submission.
|
||||
*
|
||||
* When an extension of DRM_V3D_EXT_ID_MULTI_SYNC id is defined, it points to
|
||||
* this extension to define wait and signal dependencies, instead of single
|
||||
* in/out sync entries on submitting commands. The field flags is used to
|
||||
* determine the stage to set wait dependencies.
|
||||
*/
|
||||
struct drm_v3d_multi_sync {
|
||||
struct drm_v3d_extension base;
|
||||
/* Array of wait and signal semaphores */
|
||||
__u64 in_syncs;
|
||||
__u64 out_syncs;
|
||||
|
||||
/* Number of entries */
|
||||
__u32 in_sync_count;
|
||||
__u32 out_sync_count;
|
||||
|
||||
/* set the stage (v3d_queue) to sync */
|
||||
__u32 wait_stage;
|
||||
|
||||
__u32 pad; /* mbz */
|
||||
};
|
||||
|
||||
/**
|
||||
* struct drm_v3d_submit_cl - ioctl argument for submitting commands to the 3D
|
||||
|
|
@ -135,12 +196,16 @@ struct drm_v3d_submit_cl {
|
|||
/* Number of BO handles passed in (size is that times 4). */
|
||||
__u32 bo_handle_count;
|
||||
|
||||
/* DRM_V3D_SUBMIT_* properties */
|
||||
__u32 flags;
|
||||
|
||||
/* ID of the perfmon to attach to this job. 0 means no perfmon. */
|
||||
__u32 perfmon_id;
|
||||
|
||||
__u32 pad;
|
||||
|
||||
/* Pointer to an array of ioctl extensions*/
|
||||
__u64 extensions;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -210,6 +275,7 @@ enum drm_v3d_param {
|
|||
DRM_V3D_PARAM_SUPPORTS_CSD,
|
||||
DRM_V3D_PARAM_SUPPORTS_CACHE_FLUSH,
|
||||
DRM_V3D_PARAM_SUPPORTS_PERFMON,
|
||||
DRM_V3D_PARAM_SUPPORTS_MULTISYNC_EXT,
|
||||
};
|
||||
|
||||
struct drm_v3d_get_param {
|
||||
|
|
@ -248,6 +314,11 @@ struct drm_v3d_submit_tfu {
|
|||
__u32 in_sync;
|
||||
/* Sync object to signal when the TFU job is done. */
|
||||
__u32 out_sync;
|
||||
|
||||
__u32 flags;
|
||||
|
||||
/* Pointer to an array of ioctl extensions*/
|
||||
__u64 extensions;
|
||||
};
|
||||
|
||||
/* Submits a compute shader for dispatch. This job will block on any
|
||||
|
|
@ -276,6 +347,13 @@ struct drm_v3d_submit_csd {
|
|||
|
||||
/* ID of the perfmon to attach to this job. 0 means no perfmon. */
|
||||
__u32 perfmon_id;
|
||||
|
||||
/* Pointer to an array of ioctl extensions*/
|
||||
__u64 extensions;
|
||||
|
||||
__u32 flags;
|
||||
|
||||
__u32 pad;
|
||||
};
|
||||
|
||||
enum {
|
||||
|
|
|
|||
|
|
@ -47,12 +47,15 @@ extern "C" {
|
|||
#define DRM_VIRTGPU_WAIT 0x08
|
||||
#define DRM_VIRTGPU_GET_CAPS 0x09
|
||||
#define DRM_VIRTGPU_RESOURCE_CREATE_BLOB 0x0a
|
||||
#define DRM_VIRTGPU_CONTEXT_INIT 0x0b
|
||||
|
||||
#define VIRTGPU_EXECBUF_FENCE_FD_IN 0x01
|
||||
#define VIRTGPU_EXECBUF_FENCE_FD_OUT 0x02
|
||||
#define VIRTGPU_EXECBUF_RING_IDX 0x04
|
||||
#define VIRTGPU_EXECBUF_FLAGS (\
|
||||
VIRTGPU_EXECBUF_FENCE_FD_IN |\
|
||||
VIRTGPU_EXECBUF_FENCE_FD_OUT |\
|
||||
VIRTGPU_EXECBUF_RING_IDX |\
|
||||
0)
|
||||
|
||||
struct drm_virtgpu_map {
|
||||
|
|
@ -68,6 +71,8 @@ struct drm_virtgpu_execbuffer {
|
|||
__u64 bo_handles;
|
||||
__u32 num_bo_handles;
|
||||
__s32 fence_fd; /* in/out fence fd (see VIRTGPU_EXECBUF_FENCE_FD_IN/OUT) */
|
||||
__u32 ring_idx; /* command ring index (see VIRTGPU_EXECBUF_RING_IDX) */
|
||||
__u32 pad;
|
||||
};
|
||||
|
||||
#define VIRTGPU_PARAM_3D_FEATURES 1 /* do we have 3D features in the hw */
|
||||
|
|
@ -75,6 +80,8 @@ struct drm_virtgpu_execbuffer {
|
|||
#define VIRTGPU_PARAM_RESOURCE_BLOB 3 /* DRM_VIRTGPU_RESOURCE_CREATE_BLOB */
|
||||
#define VIRTGPU_PARAM_HOST_VISIBLE 4 /* Host blob resources are mappable */
|
||||
#define VIRTGPU_PARAM_CROSS_DEVICE 5 /* Cross virtio-device resource sharing */
|
||||
#define VIRTGPU_PARAM_CONTEXT_INIT 6 /* DRM_VIRTGPU_CONTEXT_INIT */
|
||||
#define VIRTGPU_PARAM_SUPPORTED_CAPSET_IDs 7 /* Bitmask of supported capability set ids */
|
||||
|
||||
struct drm_virtgpu_getparam {
|
||||
__u64 param;
|
||||
|
|
@ -173,6 +180,22 @@ struct drm_virtgpu_resource_create_blob {
|
|||
__u64 blob_id;
|
||||
};
|
||||
|
||||
#define VIRTGPU_CONTEXT_PARAM_CAPSET_ID 0x0001
|
||||
#define VIRTGPU_CONTEXT_PARAM_NUM_RINGS 0x0002
|
||||
#define VIRTGPU_CONTEXT_PARAM_POLL_RINGS_MASK 0x0003
|
||||
struct drm_virtgpu_context_set_param {
|
||||
__u64 param;
|
||||
__u64 value;
|
||||
};
|
||||
|
||||
struct drm_virtgpu_context_init {
|
||||
__u32 num_params;
|
||||
__u32 pad;
|
||||
|
||||
/* pointer to drm_virtgpu_context_set_param array */
|
||||
__u64 ctx_set_params;
|
||||
};
|
||||
|
||||
#define DRM_IOCTL_VIRTGPU_MAP \
|
||||
DRM_IOWR(DRM_COMMAND_BASE + DRM_VIRTGPU_MAP, struct drm_virtgpu_map)
|
||||
|
||||
|
|
@ -212,6 +235,10 @@ struct drm_virtgpu_resource_create_blob {
|
|||
DRM_IOWR(DRM_COMMAND_BASE + DRM_VIRTGPU_RESOURCE_CREATE_BLOB, \
|
||||
struct drm_virtgpu_resource_create_blob)
|
||||
|
||||
#define DRM_IOCTL_VIRTGPU_CONTEXT_INIT \
|
||||
DRM_IOWR(DRM_COMMAND_BASE + DRM_VIRTGPU_CONTEXT_INIT, \
|
||||
struct drm_virtgpu_context_init)
|
||||
|
||||
#if defined(__cplusplus)
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -59,6 +59,11 @@
|
|||
* VIRTIO_GPU_CMD_RESOURCE_CREATE_BLOB
|
||||
*/
|
||||
#define VIRTIO_GPU_F_RESOURCE_BLOB 3
|
||||
/*
|
||||
* VIRTIO_GPU_CMD_CREATE_CONTEXT with
|
||||
* context_init and multiple timelines
|
||||
*/
|
||||
#define VIRTIO_GPU_F_CONTEXT_INIT 4
|
||||
|
||||
enum virtio_gpu_ctrl_type {
|
||||
VIRTIO_GPU_UNDEFINED = 0,
|
||||
|
|
@ -122,14 +127,20 @@ enum virtio_gpu_shm_id {
|
|||
VIRTIO_GPU_SHM_ID_HOST_VISIBLE = 1
|
||||
};
|
||||
|
||||
#define VIRTIO_GPU_FLAG_FENCE (1 << 0)
|
||||
#define VIRTIO_GPU_FLAG_FENCE (1 << 0)
|
||||
/*
|
||||
* If the following flag is set, then ring_idx contains the index
|
||||
* of the command ring that needs to used when creating the fence
|
||||
*/
|
||||
#define VIRTIO_GPU_FLAG_INFO_RING_IDX (1 << 1)
|
||||
|
||||
struct virtio_gpu_ctrl_hdr {
|
||||
__le32 type;
|
||||
__le32 flags;
|
||||
__le64 fence_id;
|
||||
__le32 ctx_id;
|
||||
__le32 padding;
|
||||
__u8 ring_idx;
|
||||
__u8 padding[3];
|
||||
};
|
||||
|
||||
/* data passed in the cursor vq */
|
||||
|
|
@ -269,10 +280,11 @@ struct virtio_gpu_resource_create_3d {
|
|||
};
|
||||
|
||||
/* VIRTIO_GPU_CMD_CTX_CREATE */
|
||||
#define VIRTIO_GPU_CONTEXT_INIT_CAPSET_ID_MASK 0x000000ff
|
||||
struct virtio_gpu_ctx_create {
|
||||
struct virtio_gpu_ctrl_hdr hdr;
|
||||
__le32 nlen;
|
||||
__le32 padding;
|
||||
__le32 context_init;
|
||||
char debug_name[64];
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue