History

drm/vc4: Add get/set tiling ioctls.

This allows mesa to set the tiling format for a BO and have that tiling format be respected by mesa on the other side of an import/export (and by vc4 scanout in the kernel), without defining a protocol to pass the tiling through userspace.

Eric Anholt committed 9 years ago

Commit 83753111 parent 98830d95 files · +147 −1Browse files

Showing the changes to include/uapi (1 of 5 files). Show all

Unified · Split

include/uapi/drm/vc4_drm.h+16−0
@@ -38,6 +38,8 @@ extern "C" { · 37 unmodified lines
3838 #define DRM_VC4_CREATE_SHADER_BO 0x05
3939 #define DRM_VC4_GET_HANG_STATE 0x06
4040 #define DRM_VC4_GET_PARAM 0x07
41+#define DRM_VC4_SET_TILING 0x08
42+#define DRM_VC4_GET_TILING 0x09
4143
4244 #define DRM_IOCTL_VC4_SUBMIT_CL DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_SUBMIT_CL, struct drm_vc4_submit_cl)
4345 #define DRM_IOCTL_VC4_WAIT_SEQNO DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_WAIT_SEQNO, struct drm_vc4_wait_seqno)
@@ -47,6 +49,8 @@ extern "C" { · 3 unmodified lines
4749 #define DRM_IOCTL_VC4_CREATE_SHADER_BO DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_CREATE_SHADER_BO, struct drm_vc4_create_shader_bo)
4850 #define DRM_IOCTL_VC4_GET_HANG_STATE DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_GET_HANG_STATE, struct drm_vc4_get_hang_state)
4951 #define DRM_IOCTL_VC4_GET_PARAM DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_GET_PARAM, struct drm_vc4_get_param)
52+#define DRM_IOCTL_VC4_SET_TILING DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_SET_TILING, struct drm_vc4_set_tiling)
53+#define DRM_IOCTL_VC4_GET_TILING DRM_IOWR(DRM_COMMAND_BASE + DRM_VC4_GET_TILING, struct drm_vc4_get_tiling)
5054
5155 struct drm_vc4_submit_rcl_surface {
5256 __u32 hindex; /* Handle index, or ~0 if not present. */
@@ -295,6 +299,18 @@ struct drm_vc4_get_param { · 242 unmodified lines
295299 __u64 value;
296300 };
297301
302+struct drm_vc4_get_tiling {
303+ __u32 handle;
304+ __u32 flags;
305+ __u64 modifier;
306+};
307+
308+struct drm_vc4_set_tiling {
309+ __u32 handle;
310+ __u32 flags;
311+ __u64 modifier;
312+};
313+
298314 #if defined(__cplusplus)
299315 }
300316 #endif

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t