vrend: Add definitions for the copy_transfer3d command

Add protocol definitions for the copy_transfer3d command and also
for the associated virgl capability.

Signed-off-by: Alexandros Frantzis <alexandros.frantzis@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
macos/master
Alexandros Frantzis 6 years ago committed by Gert Wollny
parent 69c52a8fb3
commit 1e2f540de5
  1. 1
      src/virgl_hw.h
  2. 8
      src/virgl_protocol.h
  3. 1
      src/vrend_debug.c

@ -247,6 +247,7 @@ enum virgl_formats {
#define VIRGL_CAP_TRANSFORM_FEEDBACK3 (1 << 23) #define VIRGL_CAP_TRANSFORM_FEEDBACK3 (1 << 23)
#define VIRGL_CAP_3D_ASTC (1 << 24) #define VIRGL_CAP_3D_ASTC (1 << 24)
#define VIRGL_CAP_INDIRECT_INPUT_ADDR (1 << 25) #define VIRGL_CAP_INDIRECT_INPUT_ADDR (1 << 25)
#define VIRGL_CAP_COPY_TRANSFER (1 << 26)
/* virgl bind flags - these are compatible with mesa 10.5 gallium. /* virgl bind flags - these are compatible with mesa 10.5 gallium.
* but are fixed, no other should be passed to virgl either. * but are fixed, no other should be passed to virgl either.

@ -100,6 +100,7 @@ enum virgl_context_cmd {
VIRGL_CCMD_GET_QUERY_RESULT_QBO, VIRGL_CCMD_GET_QUERY_RESULT_QBO,
VIRGL_CCMD_TRANSFER3D, VIRGL_CCMD_TRANSFER3D,
VIRGL_CCMD_END_TRANSFERS, VIRGL_CCMD_END_TRANSFERS,
VIRGL_CCMD_COPY_TRANSFER3D,
VIRGL_MAX_COMMANDS VIRGL_MAX_COMMANDS
}; };
@ -584,4 +585,11 @@ enum virgl_context_cmd {
#define VIRGL_TRANSFER3D_DATA_OFFSET 12 #define VIRGL_TRANSFER3D_DATA_OFFSET 12
#define VIRGL_TRANSFER3D_DIRECTION 13 #define VIRGL_TRANSFER3D_DIRECTION 13
/* Copy transfer */
#define VIRGL_COPY_TRANSFER3D_SIZE 14
/* The first 11 dwords are the same as VIRGL_RESOURCE_IW_* */
#define VIRGL_COPY_TRANSFER3D_SRC_RES_HANDLE 12
#define VIRGL_COPY_TRANSFER3D_SRC_RES_OFFSET 13
#define VIRGL_COPY_TRANSFER3D_SYNCHRONIZED 14
#endif #endif

@ -74,6 +74,7 @@ static const char *command_names[VIRGL_MAX_COMMANDS] = {
"GET_QBO_RESULT", "GET_QBO_RESULT",
"TRANSFER3D", "TRANSFER3D",
"END_TRANSFERS", "END_TRANSFERS",
"COPY_TRANSFER3D",
}; };
static const char *object_type_names[VIRGL_MAX_OBJECTS] = { static const char *object_type_names[VIRGL_MAX_OBJECTS] = {

Loading…
Cancel
Save