diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2011-04-26 13:27:43 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2011-04-27 03:03:56 -0400 |
commit | 6565945b60922211c299968ba66a66617af32c9f (patch) | |
tree | fca477c8c1d8da6f918898fa6f1b75888779f47f /drivers/gpu/drm/radeon/radeon_kms.c | |
parent | 834f0c353ae430c1a6ce023c9b77bbd3ff9241a7 (diff) |
drm/radeon/kms: add info query for tile pipes
needed by mesa for htile setup.
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_kms.c')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_kms.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c index bf7d4c061451..871df0376b1c 100644 --- a/drivers/gpu/drm/radeon/radeon_kms.c +++ b/drivers/gpu/drm/radeon/radeon_kms.c | |||
@@ -221,6 +221,19 @@ int radeon_info_ioctl(struct drm_device *dev, void *data, struct drm_file *filp) | |||
221 | return -EINVAL; | 221 | return -EINVAL; |
222 | } | 222 | } |
223 | break; | 223 | break; |
224 | case RADEON_INFO_NUM_TILE_PIPES: | ||
225 | if (rdev->family >= CHIP_CAYMAN) | ||
226 | value = rdev->config.cayman.max_tile_pipes; | ||
227 | else if (rdev->family >= CHIP_CEDAR) | ||
228 | value = rdev->config.evergreen.max_tile_pipes; | ||
229 | else if (rdev->family >= CHIP_RV770) | ||
230 | value = rdev->config.rv770.max_tile_pipes; | ||
231 | else if (rdev->family >= CHIP_R600) | ||
232 | value = rdev->config.r600.max_tile_pipes; | ||
233 | else { | ||
234 | return -EINVAL; | ||
235 | } | ||
236 | break; | ||
224 | default: | 237 | default: |
225 | DRM_DEBUG_KMS("Invalid request %d\n", info->request); | 238 | DRM_DEBUG_KMS("Invalid request %d\n", info->request); |
226 | return -EINVAL; | 239 | return -EINVAL; |