summaryrefslogtreecommitdiff
path: root/bsd-core
diff options
context:
space:
mode:
authorEric Anholt <anholt@freebsd.org>2004-08-13 23:17:17 +0000
committerEric Anholt <anholt@freebsd.org>2004-08-13 23:17:17 +0000
commitd78db7c930c4652f45584098747efa8feb4cd280 (patch)
tree9e95ee86ac970a262313df7687e7e31c855e5f29 /bsd-core
parentfd62869a0f600f2fd477d5aa365f7732686f5542 (diff)
Enable MTRR usage on AMD64, and use DELAY() instead of rolling our own
udelay code. Submitted by: Jung-uk Kim <jkim@niksun.com>
Diffstat (limited to 'bsd-core')
-rw-r--r--bsd-core/drm_os_freebsd.h12
1 files changed, 3 insertions, 9 deletions
diff --git a/bsd-core/drm_os_freebsd.h b/bsd-core/drm_os_freebsd.h
index 7d750dba..dd95d9cb 100644
--- a/bsd-core/drm_os_freebsd.h
+++ b/bsd-core/drm_os_freebsd.h
@@ -84,6 +84,8 @@
#ifdef __i386__
#define __REALLY_HAVE_MTRR (__HAVE_MTRR) && (__FreeBSD_version >= 460000)
+#elif defined(__amd64__)
+#define __REALLY_HAVE_MTRR (__HAVE_MTRR)
#else
#define __REALLY_HAVE_MTRR 0
#endif
@@ -204,15 +206,7 @@ do { \
} \
} while (0)
-#define DRM_UDELAY( udelay ) \
-do { \
- struct timeval tv1, tv2; \
- microtime(&tv1); \
- do { \
- microtime(&tv2); \
- } \
- while (((tv2.tv_sec-tv1.tv_sec)*1000000 + tv2.tv_usec - tv1.tv_usec) < udelay ); \
-} while (0)
+#define DRM_UDELAY(udelay) DELAY(udelay)
#define DRM_GETSAREA() \
do { \