aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dos/dpmi.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2003-02-20 15:43:52 +0000
committerBrian Paul <[email protected]>2003-02-20 15:43:52 +0000
commit60f84fcc91c5fb86843c528416399303da113a2f (patch)
tree698d04b625c6efac205d76ae7d68b074102090f2 /src/mesa/drivers/dos/dpmi.c
parent449e47f06a46c42fb9895d13f37b599600225e56 (diff)
latest DOS updates (Daniel Borca)
Diffstat (limited to 'src/mesa/drivers/dos/dpmi.c')
-rw-r--r--src/mesa/drivers/dos/dpmi.c23
1 files changed, 21 insertions, 2 deletions
diff --git a/src/mesa/drivers/dos/dpmi.c b/src/mesa/drivers/dos/dpmi.c
index 882cda390a4..db6a3063390 100644
--- a/src/mesa/drivers/dos/dpmi.c
+++ b/src/mesa/drivers/dos/dpmi.c
@@ -46,7 +46,7 @@
/* _create_linear_mapping:
* Maps a physical address range into linear memory.
*/
-static int _create_linear_mapping (unsigned long *linear, unsigned long physaddr, int size)
+int _create_linear_mapping (unsigned long *linear, unsigned long physaddr, int size)
{
__dpmi_meminfo meminfo;
@@ -71,7 +71,7 @@ static int _create_linear_mapping (unsigned long *linear, unsigned long physaddr
/* _remove_linear_mapping:
* Frees the DPMI resources being used to map a linear address range.
*/
-static void _remove_linear_mapping (unsigned long *linear)
+void _remove_linear_mapping (unsigned long *linear)
{
__dpmi_meminfo meminfo;
@@ -127,3 +127,22 @@ void _remove_selector (int *segment)
*segment = 0;
}
}
+
+
+
+/* Desc: retrieve CPU MMX capability
+ *
+ * In : -
+ * Out : FALSE if CPU cannot do MMX
+ *
+ * Note: -
+ */
+int _can_mmx (void)
+{
+#ifdef USE_MMX_ASM
+ extern int _mesa_identify_x86_cpu_features (void);
+ return (_mesa_identify_x86_cpu_features() & 0x00800000);
+#else
+ return 0;
+#endif
+}