summaryrefslogtreecommitdiffstats
path: root/sys/dev/drm
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2005-12-04 12:37:19 +0000
committerru <ru@FreeBSD.org>2005-12-04 12:37:19 +0000
commit45281956926162fc9e81fccc847f9ec1f96fa2a8 (patch)
tree5387d5fb74a5a4ff16845965be63791e5070a92f /sys/dev/drm
parent11d5bb39af557b9abb12ccc23a2a6d8a16cfe211 (diff)
downloadFreeBSD-src-45281956926162fc9e81fccc847f9ec1f96fa2a8.zip
FreeBSD-src-45281956926162fc9e81fccc847f9ec1f96fa2a8.tar.gz
Use compile-time detection of 64-bit addressing.
Diffstat (limited to 'sys/dev/drm')
-rw-r--r--sys/dev/drm/radeon_state.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/drm/radeon_state.c b/sys/dev/drm/radeon_state.c
index d568862..1f69ead 100644
--- a/sys/dev/drm/radeon_state.c
+++ b/sys/dev/drm/radeon_state.c
@@ -2937,7 +2937,7 @@ static int radeon_cp_getparam(DRM_IOCTL_ARGS)
case RADEON_PARAM_STATUS_HANDLE:
value = dev_priv->ring_rptr_offset;
break;
- case RADEON_PARAM_SAREA_HANDLE:
+#ifndef __LP64__
/*
* This ioctl() doesn't work on 64-bit platforms because hw_lock is a
* pointer which can't fit into an int-sized variable. According to
@@ -2947,11 +2947,11 @@ static int radeon_cp_getparam(DRM_IOCTL_ARGS)
* so backwards-compatibility for the embedded platforms can be
* maintained. --davidm 4-Feb-2004.
*/
- if (sizeof(long) * 8 == 64)
- return DRM_ERR(EINVAL);
+ case RADEON_PARAM_SAREA_HANDLE:
/* The lock is the first dword in the sarea. */
value = (long)dev->lock.hw_lock;
break;
+#endif
case RADEON_PARAM_GART_TEX_HANDLE:
value = dev_priv->gart_textures_offset;
break;
OpenPOWER on IntegriCloud