libdrm: headers: Sync with drm-next
Subsystems (3)
PATCH v3 1/1 libdrm: headers: Sync with drm-next
Generated using make headers_install from the drm-next tree - git://anongit.freedesktop.org/drm/drm
branch - drm-next
commit - 2dc7bad71cd310dc94d1c9907909324dd2b0618f
The changes were as follows :-
core: (drm.h, drm_fourcc.h, drm_mode.h)
- Added client capabilities for ASPECT_RATIO and WRITEBACK_CONNECTORS
- Added Arm AFBC modifiers
- Added BROADCOM's SAND and UIF modifiers
- Added Qualcomm's modifiers
- Added some picture aspect ratio and content type options
- Added some drm mode flags
- Added writeback connector id
amdgpu:
- Added GEM domain mask
- Added some GEM flags
- Added some hardware ip flags
- Added chunk id and IB fence.
- Added some query ids
i915:
-Added an IOCTL (I915_PARAM_MMAP_GTT_COHERENT)
qxl:
- Minor changes
tegra:
- Added some comments about struct drm_tegra* members
- Modified DRM_IOCTL_TEGRA_CLOSE_CHANNEL
vc4:
- Added some members for 'struct drm_vc4_submit_cl'
vmwgfx:
- Added some DRM_VMW_* macros
- Renamed some structures like 'drm_vmw_dmabuf_rep' to 'drm_vmw_bo_rep', etc
- Added some new DRM_VMW_GB_SURFACE related structures and unions
Changes in v2:
- Mentioned 'libdrm' in the commit header.
Changes in v3:
- Removed the changes to radeon_drm.h, sis_drm.h and via_drm.h as suggested by Emil Velikov <[email protected]>
--- include/drm/amdgpu_drm.h | 47 ++++- include/drm/drm.h | 16 ++ include/drm/drm_fourcc.h | 215 +++++++++++++++++++++ include/drm/drm_mode.h | 35 +++- include/drm/i915_drm.h | 22 +++ include/drm/qxl_drm.h | 2 - include/drm/tegra_drm.h | 492 ++++++++++++++++++++++++++++++++++++++++++++++- include/drm/vc4_drm.h | 13 +- include/drm/vmwgfx_drm.h | 166 ++++++++++++---- 9 files changed, 953 insertions(+), 55 deletions(-)
include/drm/amdgpu_drm.h +46 -1
@@ -72,12 +72,41 @@ extern "C" {#define DRM_IOCTL_AMDGPU_FENCE_TO_HANDLE DRM_IOWR(DRM_COMMAND_BASE + DRM_AMDGPU_FENCE_TO_HANDLE, union drm_amdgpu_fence_to_handle)#define DRM_IOCTL_AMDGPU_SCHED DRM_IOW(DRM_COMMAND_BASE + DRM_AMDGPU_SCHED, union drm_amdgpu_sched) +/** +* DOC: memory domains +* +* %AMDGPU_GEM_DOMAIN_CPU System memory that is not GPU accessible. +* Memory in this pool could be swapped out to disk if there is pressure. +* +* %AMDGPU_GEM_DOMAIN_GTT GPU accessible system memory, mapped into the +* GPU's virtual address space via gart. Gart memory linearizes non-contiguous +* pages of system memory, allows GPU access system memory in a linezrized +* fashion. +* +* %AMDGPU_GEM_DOMAIN_VRAM Local video memory. For APUs, it is memory +* carved out by the BIOS. +* +* %AMDGPU_GEM_DOMAIN_GDS Global on-chip data storage used to share data +* across shader threads. +* +* %AMDGPU_GEM_DOMAIN_GWS Global wave sync, used to synchronize the +* execution of all the waves on a device. +* +* %AMDGPU_GEM_DOMAIN_OA Ordered append, used by 3D or Compute engines +* for appending data. +*/ #define AMDGPU_GEM_DOMAIN_CPU 0x1#define AMDGPU_GEM_DOMAIN_GTT 0x2#define AMDGPU_GEM_DOMAIN_VRAM 0x4#define AMDGPU_GEM_DOMAIN_GDS 0x8#define AMDGPU_GEM_DOMAIN_GWS 0x10#define AMDGPU_GEM_DOMAIN_OA 0x20 +#define AMDGPU_GEM_DOMAIN_MASK (AMDGPU_GEM_DOMAIN_CPU | \ + AMDGPU_GEM_DOMAIN_GTT | \ + AMDGPU_GEM_DOMAIN_VRAM | \ + AMDGPU_GEM_DOMAIN_GDS | \ + AMDGPU_GEM_DOMAIN_GWS | \ + AMDGPU_GEM_DOMAIN_OA)/* Flag that CPU access will be required for the case of VRAM domain */ #define AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED (1 << 0)
@@ -95,6 +124,10 @@ extern "C" {#define AMDGPU_GEM_CREATE_VM_ALWAYS_VALID (1 << 6)/* Flag that BO sharing will be explicitly synchronized */ #define AMDGPU_GEM_CREATE_EXPLICIT_SYNC (1 << 7) +/* Flag that indicates allocating MQD gart on GFX9, where the mtype +* for the second page onward should be set to NC. +*/ +#define AMDGPU_GEM_CREATE_MQD_GFX9 (1 << 8)struct drm_amdgpu_gem_create_in {/** the requested memory size */
@@ -473,7 +506,8 @@ struct drm_amdgpu_gem_va {#define AMDGPU_HW_IP_UVD_ENC 5#define AMDGPU_HW_IP_VCN_DEC 6#define AMDGPU_HW_IP_VCN_ENC 7 -#define AMDGPU_HW_IP_NUM 8 +#define AMDGPU_HW_IP_VCN_JPEG 8 +#define AMDGPU_HW_IP_NUM 9#define AMDGPU_HW_IP_INSTANCE_MAX_COUNT 1
@@ -482,6 +516,7 @@ struct drm_amdgpu_gem_va {#define AMDGPU_CHUNK_ID_DEPENDENCIES 0x03#define AMDGPU_CHUNK_ID_SYNCOBJ_IN 0x04#define AMDGPU_CHUNK_ID_SYNCOBJ_OUT 0x05 +#define AMDGPU_CHUNK_ID_BO_HANDLES 0x06struct drm_amdgpu_cs_chunk {__u32 chunk_id;
@@ -520,6 +555,10 @@ union drm_amdgpu_cs {/* Preempt flag, IB should set Pre_enb bit if PREEMPT flag detected */ #define AMDGPU_IB_FLAG_PREEMPT (1<<2) +/* The IB fence should do the L2 writeback but not invalidate any shader +* caches (L2/vL1/sL1/I$). */ +#define AMDGPU_IB_FLAG_TC_WB_NOT_INVALIDATE (1 << 3) +struct drm_amdgpu_cs_chunk_ib {__u32 _pad;/** AMDGPU_IB_FLAG_* */
@@ -620,6 +659,12 @@ struct drm_amdgpu_cs_chunk_data {#define AMDGPU_INFO_FW_ASD 0x0d/* Subquery id: Query VCN firmware version */ #define AMDGPU_INFO_FW_VCN 0x0e +/* Subquery id: Query GFX RLC SRLC firmware version */ +#define AMDGPU_INFO_FW_GFX_RLC_RESTORE_LIST_CNTL 0x0f +/* Subquery id: Query GFX RLC SRLG firmware version */ +#define AMDGPU_INFO_FW_GFX_RLC_RESTORE_LIST_GPM_MEM 0x10 +/* Subquery id: Query GFX RLC SRLS firmware version */ +#define AMDGPU_INFO_FW_GFX_RLC_RESTORE_LIST_SRM_MEM 0x11/* number of bytes moved for TTM migration */ #define AMDGPU_INFO_NUM_BYTES_MOVED 0x0f/* the used VRAM size */
include/drm/drm.h +16 -0
@@ -674,6 +674,22 @@ struct drm_get_cap {*/ #define DRM_CLIENT_CAP_ATOMIC 3 +/** +* DRM_CLIENT_CAP_ASPECT_RATIO +* +* If set to 1, the DRM core will provide aspect ratio information in modes. +*/ +#define DRM_CLIENT_CAP_ASPECT_RATIO 4 + +/** +* DRM_CLIENT_CAP_WRITEBACK_CONNECTORS +* +* If set to 1, the DRM core will expose special connectors to be used for +* writing back to memory the scene setup in the commit. Depends on client +* also supporting DRM_CLIENT_CAP_ATOMIC +*/ +#define DRM_CLIENT_CAP_WRITEBACK_CONNECTORS 5 +/** DRM_IOCTL_SET_CLIENT_CAP ioctl argument type */ struct drm_set_client_cap {__u64 capability;
include/drm/drm_fourcc.h +215 -0
250 lines not on this page · raw message
include/drm/drm_mode.h +34 -1
@@ -46,6 +46,10 @@ extern "C" {#define DRM_MODE_TYPE_USERDEF (1<<5)#define DRM_MODE_TYPE_DRIVER (1<<6) +#define DRM_MODE_TYPE_ALL (DRM_MODE_TYPE_PREFERRED | \ + DRM_MODE_TYPE_USERDEF | \ + DRM_MODE_TYPE_DRIVER) +/* Video mode flags */ /* bit compatible with the xrandr RR_ definitions (bits 0-13) *
@@ -89,6 +93,15 @@ extern "C" {#define DRM_MODE_PICTURE_ASPECT_NONE 0#define DRM_MODE_PICTURE_ASPECT_4_3 1#define DRM_MODE_PICTURE_ASPECT_16_9 2 +#define DRM_MODE_PICTURE_ASPECT_64_27 3 +#define DRM_MODE_PICTURE_ASPECT_256_135 4 + +/* Content type options */ +#define DRM_MODE_CONTENT_TYPE_NO_DATA 0 +#define DRM_MODE_CONTENT_TYPE_GRAPHICS 1 +#define DRM_MODE_CONTENT_TYPE_PHOTO 2 +#define DRM_MODE_CONTENT_TYPE_CINEMA 3 +#define DRM_MODE_CONTENT_TYPE_GAME 4/* Aspect ratio flag bitmask (4 bits 22:19) */ #define DRM_MODE_FLAG_PIC_AR_MASK (0x0F<<19)
@@ -98,6 +111,24 @@ extern "C" { (DRM_MODE_PICTURE_ASPECT_4_3<<19)#define DRM_MODE_FLAG_PIC_AR_16_9 \ (DRM_MODE_PICTURE_ASPECT_16_9<<19) +#define DRM_MODE_FLAG_PIC_AR_64_27 \ + (DRM_MODE_PICTURE_ASPECT_64_27<<19) +#define DRM_MODE_FLAG_PIC_AR_256_135 \ + (DRM_MODE_PICTURE_ASPECT_256_135<<19) + +#define DRM_MODE_FLAG_ALL (DRM_MODE_FLAG_PHSYNC | \ + DRM_MODE_FLAG_NHSYNC | \ + DRM_MODE_FLAG_PVSYNC | \ + DRM_MODE_FLAG_NVSYNC | \ + DRM_MODE_FLAG_INTERLACE | \ + DRM_MODE_FLAG_DBLSCAN | \ + DRM_MODE_FLAG_CSYNC | \ + DRM_MODE_FLAG_PCSYNC | \ + DRM_MODE_FLAG_NCSYNC | \ + DRM_MODE_FLAG_HSKEW | \ + DRM_MODE_FLAG_DBLCLK | \ + DRM_MODE_FLAG_CLKDIV2 | \ + DRM_MODE_FLAG_3D_MASK)/* DPMS flags */ /* bit compatible with the xorg definitions. */
@@ -155,8 +186,9 @@ extern "C" {/* * DRM_MODE_REFLECT_<axis> * -* Signals that the contents of a drm plane is reflected in the <axis> axis, +* Signals that the contents of a drm plane is reflected along the <axis> axis, * in the same way as mirroring. +* See kerneldoc chapter "Plane Composition Properties" for more details. * * This define is provided as a convenience, looking up the property id * using the name->prop id lookup is the preferred method.
@@ -320,6 +352,7 @@ enum drm_mode_subconnector {#define DRM_MODE_CONNECTOR_VIRTUAL 15#define DRM_MODE_CONNECTOR_DSI 16#define DRM_MODE_CONNECTOR_DPI 17 +#define DRM_MODE_CONNECTOR_WRITEBACK 18struct drm_mode_get_connector {
include/drm/i915_drm.h +22 -0
@@ -529,6 +529,28 @@ typedef struct drm_i915_irq_wait {*/ #define I915_PARAM_CS_TIMESTAMP_FREQUENCY 51 +/* +* Once upon a time we supposed that writes through the GGTT would be +* immediately in physical memory (once flushed out of the CPU path). However, +* on a few different processors and chipsets, this is not necessarily the case +* as the writes appear to be buffered internally. Thus a read of the backing +* storage (physical memory) via a different path (with different physical tags +* to the indirect write via the GGTT) will see stale values from before +* the GGTT write. Inside the kernel, we can for the most part keep track of +* the different read/write domains in use (e.g. set-domain), but the assumption +* of coherency is baked into the ABI, hence reporting its true state in this +* parameter. +* +* Reports true when writes via mmap_gtt are immediately visible following an +* lfence to flush the WCB. +* +* Reports false when writes via mmap_gtt are indeterminately delayed in an in +* internal buffer and are _not_ immediately visible to third parties accessing +* directly via mmap_cpu/mmap_wc. Use of mmap_gtt as part of an IPC +* communications channel when reporting false is strongly disadvised. +*/ +#define I915_PARAM_MMAP_GTT_COHERENT 52 + typedef struct drm_i915_getparam { __s32 param; /*
include/drm/qxl_drm.h +0 -2
@@ -24,7 +24,6 @@#ifndef QXL_DRM_H #define QXL_DRM_H -#include <stddef.h> #include "drm.h" #if defined(__cplusplus)
@@ -89,7 +88,6 @@ struct drm_qxl_command {__u32 pad; }; -/* XXX: call it drm_qxl_commands? */ struct drm_qxl_execbuffer {__u32 flags;/* for future use */ __u32 commands_num;
include/drm/tegra_drm.h +482 -10
632 lines not on this page · raw message
include/drm/vc4_drm.h +10 -3
@@ -183,10 +183,17 @@ struct drm_vc4_submit_cl {/* ID of the perfmon to attach to this job. 0 means no perfmon. */ __u32 perfmonid; -/* Unused field to align this struct on 64 bits. Must be set to 0. -* If one ever needs to add an u32 field to this struct, this field -* can be used. +/* Syncobj handle to wait on. If set, processing of this render job +* will not start until the syncobj is signaled. 0 means ignore. */ +__u32 in_sync; + +/* Syncobj handle to export fence to. If set, the fence in the syncobj +* will be replaced with a fence that signals upon completion of this +* render job. 0 means ignore. +*/ +__u32 out_sync; +__u32 pad2; };
include/drm/vmwgfx_drm.h +128 -38
254 lines not on this page · raw message
Signature · 6 lines
2.7.4 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 41 lines · Ayan Halder
Generated using make
headers_installfrom the drm-next tree -git://anongit.freedesktop.org/drm/drm
branch - drm-next
commit -2dc7bad71cd310dc94d1c9907909324dd2b0618fThe changes were as follows :-
core: (
drm.h,drm_fourcc.h,drm_mode.h)
- Added client capabilities forASPECT_RATIOandWRITEBACK_CONNECTORS
- Added Arm AFBC modifiers
- Added BROADCOM's SAND and UIF modifiers
- Added Qualcomm's modifiers
- Added some picture aspect ratio and content type options
- Added some drm mode flags
- Added writeback connector idamdgpu:
- Added GEM domain mask
- Added some GEM flags
- Added some hardware ip flags
- Added chunk id and IB fence.
- Added some query idsi915:
-Added an IOCTL (I915_PARAM_MMAP_GTT_COHERENT)qxl:
- Minor changestegra:
- Added some comments about struct drm_tegra* members
- ModifiedDRM_IOCTL_TEGRA_CLOSE_CHANNELvc4:
- Added some members for 'structdrm_vc4_submit_cl'vmwgfx:
- Added some DRM_VMW_* macros
- Renamed some structures like 'drm_vmw_dmabuf_rep' to 'drm_vmw_bo_rep', etc
- Added some newDRM_VMW_GB_SURFACErelated structures and unions
Quoted 7 lines
Changes in v2:
- Mentioned 'libdrm' in the commit header.Changes in v3:
- Removed the changes toradeon_drm.h,sis_drm.handvia_drm.has suggested by Emil Velikov <[email protected]>
Seems like there's another breakage: SVGA3dMSPattern and SVGA3dMSQualityLevel are typedefs from some random header. One solution is to use the explicit fixed-size int equivalent.
Just like the earlier suggestions - things should go into the kernel first or we can drop that file for now.
Sorry for missing that one :-\
Thanks
Emil
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel