diff options
| author | Jerome Glisse <jglisse@redhat.com> | 2013-04-09 11:17:08 -0400 |
|---|---|---|
| committer | Alex Deucher <alexander.deucher@amd.com> | 2013-04-11 09:22:06 -0400 |
| commit | 64d7b8bed851f55a17d15ec6cc60233c85f84357 (patch) | |
| tree | 82cd8c562091e6fda2419fc49002398a0d094b1c /include/uapi | |
| parent | 902aaef6c698ce0f04a6acab2d5396519d5de330 (diff) | |
drm/radeon: add si tile mode array query v3
Allow userspace to query for the tile mode array so userspace can properly
compute surface pitch and alignment requirement depending on tiling.
v2: Make strict aliasing safer by casting to char when copying
v3: merge fix from Christian
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'include/uapi')
| -rw-r--r-- | include/uapi/drm/radeon_drm.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/include/uapi/drm/radeon_drm.h b/include/uapi/drm/radeon_drm.h index 05ed0107584d..321d4ac5c512 100644 --- a/include/uapi/drm/radeon_drm.h +++ b/include/uapi/drm/radeon_drm.h | |||
| @@ -977,6 +977,8 @@ struct drm_radeon_cs { | |||
| 977 | #define RADEON_INFO_FASTFB_WORKING 0x14 | 977 | #define RADEON_INFO_FASTFB_WORKING 0x14 |
| 978 | /* query if a RADEON_CS_RING_* submission is supported */ | 978 | /* query if a RADEON_CS_RING_* submission is supported */ |
| 979 | #define RADEON_INFO_RING_WORKING 0x15 | 979 | #define RADEON_INFO_RING_WORKING 0x15 |
| 980 | /* SI tile mode array */ | ||
| 981 | #define RADEON_INFO_SI_TILE_MODE_ARRAY 0x16 | ||
| 980 | 982 | ||
| 981 | 983 | ||
| 982 | struct drm_radeon_info { | 984 | struct drm_radeon_info { |
| @@ -985,4 +987,22 @@ struct drm_radeon_info { | |||
| 985 | uint64_t value; | 987 | uint64_t value; |
| 986 | }; | 988 | }; |
| 987 | 989 | ||
| 990 | /* Those correspond to the tile index to use, this is to explicitly state | ||
| 991 | * the API that is implicitly defined by the tile mode array. | ||
| 992 | */ | ||
| 993 | #define SI_TILE_MODE_COLOR_LINEAR_ALIGNED 8 | ||
| 994 | #define SI_TILE_MODE_COLOR_1D 13 | ||
| 995 | #define SI_TILE_MODE_COLOR_1D_SCANOUT 9 | ||
| 996 | #define SI_TILE_MODE_COLOR_2D_8BPP 14 | ||
| 997 | #define SI_TILE_MODE_COLOR_2D_16BPP 15 | ||
| 998 | #define SI_TILE_MODE_COLOR_2D_32BPP 16 | ||
| 999 | #define SI_TILE_MODE_COLOR_2D_64BPP 17 | ||
| 1000 | #define SI_TILE_MODE_COLOR_2D_SCANOUT_16BPP 11 | ||
| 1001 | #define SI_TILE_MODE_COLOR_2D_SCANOUT_32BPP 12 | ||
| 1002 | #define SI_TILE_MODE_DEPTH_STENCIL_1D 4 | ||
| 1003 | #define SI_TILE_MODE_DEPTH_STENCIL_2D 0 | ||
| 1004 | #define SI_TILE_MODE_DEPTH_STENCIL_2D_2AA 3 | ||
| 1005 | #define SI_TILE_MODE_DEPTH_STENCIL_2D_4AA 3 | ||
| 1006 | #define SI_TILE_MODE_DEPTH_STENCIL_2D_8AA 2 | ||
| 1007 | |||
| 988 | #endif | 1008 | #endif |
