Initial DX support. Co-authored with Sinclair Yeh, Charmaine Lee and Jakob Bornecrantz.
Showing the changes to include/uapi (1 of 22 files). Show all
Unified · Split
| @@ -64,6 +64,7 @@ · 63 unmodified lines | ||
| 64 | 64 | #define DRM_VMW_GB_SURFACE_CREATE 23 |
| 65 | 65 | #define DRM_VMW_GB_SURFACE_REF 24 |
| 66 | 66 | #define DRM_VMW_SYNCCPU 25 |
| 67 | +#define DRM_VMW_CREATE_EXTENDED_CONTEXT 26 | |
| 67 | 68 | |
| 68 | 69 | /*************************************************************************/ |
| 69 | 70 | /** |
| @@ -89,6 +90,7 @@ · 19 unmodified lines | ||
| 89 | 90 | #define DRM_VMW_PARAM_MAX_MOB_MEMORY 9 |
| 90 | 91 | #define DRM_VMW_PARAM_MAX_MOB_SIZE 10 |
| 91 | 92 | #define DRM_VMW_PARAM_SCREEN_TARGET 11 |
| 93 | +#define DRM_VMW_PARAM_DX 12 | |
| 92 | 94 | |
| 93 | 95 | /** |
| 94 | 96 | * enum drm_vmw_handle_type - handle type for ref ioctls |
| @@ -297,7 +299,7 @@ union drm_vmw_surface_reference_arg { · 202 unmodified lines | ||
| 297 | 299 | * Argument to the DRM_VMW_EXECBUF Ioctl. |
| 298 | 300 | */ |
| 299 | 301 | |
| 300 | −#define DRM_VMW_EXECBUF_VERSION 1 | |
| 302 | +#define DRM_VMW_EXECBUF_VERSION 2 | |
| 301 | 303 | |
| 302 | 304 | struct drm_vmw_execbuf_arg { |
| 303 | 305 | uint64_t commands; |
| @@ -306,6 +308,8 @@ struct drm_vmw_execbuf_arg { · 2 unmodified lines | ||
| 306 | 308 | uint64_t fence_rep; |
| 307 | 309 | uint32_t version; |
| 308 | 310 | uint32_t flags; |
| 311 | + uint32_t context_handle; | |
| 312 | + uint32_t pad64; | |
| 309 | 313 | }; |
| 310 | 314 | |
| 311 | 315 | /** |
| @@ -826,7 +830,6 @@ struct drm_vmw_update_layout_arg { · 514 unmodified lines | ||
| 826 | 830 | enum drm_vmw_shader_type { |
| 827 | 831 | drm_vmw_shader_type_vs = 0, |
| 828 | 832 | drm_vmw_shader_type_ps, |
| 829 | − drm_vmw_shader_type_gs | |
| 830 | 833 | }; |
| 831 | 834 | |
| 832 | 835 | |
| @@ -908,6 +911,8 @@ enum drm_vmw_surface_flags { · 75 unmodified lines | ||
| 908 | 911 | * @buffer_handle Buffer handle of backup buffer. SVGA3D_INVALID_ID |
| 909 | 912 | * if none. |
| 910 | 913 | * @base_size Size of the base mip level for all faces. |
| 914 | + * @array_size Must be zero for non-DX hardware, and if non-zero | |
| 915 | + * svga3d_flags must have proper bind flags setup. | |
| 911 | 916 | * |
| 912 | 917 | * Input argument to the DRM_VMW_GB_SURFACE_CREATE Ioctl. |
| 913 | 918 | * Part of output argument for the DRM_VMW_GB_SURFACE_REF Ioctl. |
| @@ -920,7 +925,7 @@ struct drm_vmw_gb_surface_create_req { · 6 unmodified lines | ||
| 920 | 925 | uint32_t multisample_count; |
| 921 | 926 | uint32_t autogen_filter; |
| 922 | 927 | uint32_t buffer_handle; |
| 923 | − uint32_t pad64; | |
| 928 | + uint32_t array_size; | |
| 924 | 929 | struct drm_vmw_size base_size; |
| 925 | 930 | }; |
| 926 | 931 | |
| @@ -1060,4 +1065,28 @@ struct drm_vmw_synccpu_arg { · 133 unmodified lines | ||
| 1060 | 1065 | uint32_t pad64; |
| 1061 | 1066 | }; |
| 1062 | 1067 | |
| 1068 | +/*************************************************************************/ | |
| 1069 | +/** | |
| 1070 | + * DRM_VMW_CREATE_EXTENDED_CONTEXT - Create a host context. | |
| 1071 | + * | |
| 1072 | + * Allocates a device unique context id, and queues a create context command | |
| 1073 | + * for the host. Does not wait for host completion. | |
| 1074 | + */ | |
| 1075 | +enum drm_vmw_extended_context { | |
| 1076 | + drm_vmw_context_legacy, | |
| 1077 | + drm_vmw_context_dx | |
| 1078 | +}; | |
| 1079 | + | |
| 1080 | +/** | |
| 1081 | + * union drm_vmw_extended_context_arg | |
| 1082 | + * | |
| 1083 | + * @req: Context type. | |
| 1084 | + * @rep: Context identifier. | |
| 1085 | + * | |
| 1086 | + * Argument to the DRM_VMW_CREATE_EXTENDED_CONTEXT Ioctl. | |
| 1087 | + */ | |
| 1088 | +union drm_vmw_extended_context_arg { | |
| 1089 | + enum drm_vmw_extended_context req; | |
| 1090 | + struct drm_vmw_context_arg rep; | |
| 1091 | +}; | |
| 1063 | 1092 | #endif |