summaryrefslogtreecommitdiff
path: root/include/VBox/VBoxVideoGuest.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/VBox/VBoxVideoGuest.h')
-rw-r--r--include/VBox/VBoxVideoGuest.h16
1 files changed, 15 insertions, 1 deletions
diff --git a/include/VBox/VBoxVideoGuest.h b/include/VBox/VBoxVideoGuest.h
index b0718231..e88afe6b 100644
--- a/include/VBox/VBoxVideoGuest.h
+++ b/include/VBox/VBoxVideoGuest.h
@@ -5,7 +5,7 @@
*/
/*
- * Copyright (C) 2006-2011 Oracle Corporation
+ * Copyright (C) 2006-2012 Oracle Corporation
*
* This file is part of VirtualBox Open Source Edition (OSE), as
* available from http://www.virtualbox.org. This file is free software;
@@ -38,6 +38,8 @@ RT_C_DECLS_BEGIN
# include "ntddvdeo.h"
# include <Video.h>
RT_C_DECLS_END
+#elif defined VBOX_GUESTR3XORGMOD
+# include <compiler.h>
#else
# include <iprt/asm-amd64-x86.h>
#endif
@@ -123,6 +125,8 @@ DECLINLINE(void) VBoxVideoCmnPortWriteUchar(RTIOPORT Port, uint8_t Value)
{
#ifdef VBOX_XPDM_MINIPORT
VideoPortWritePortUchar((PUCHAR)Port, Value);
+#elif defined VBOX_GUESTR3XORGMOD
+ outb(Port, Value);
#else /** @todo make these explicit */
ASMOutU8(Port, Value);
#endif
@@ -133,6 +137,8 @@ DECLINLINE(void) VBoxVideoCmnPortWriteUshort(RTIOPORT Port, uint16_t Value)
{
#ifdef VBOX_XPDM_MINIPORT
VideoPortWritePortUshort((PUSHORT)Port,Value);
+#elif defined VBOX_GUESTR3XORGMOD
+ outw(Port, Value);
#else
ASMOutU16(Port, Value);
#endif
@@ -143,6 +149,8 @@ DECLINLINE(void) VBoxVideoCmnPortWriteUlong(RTIOPORT Port, uint32_t Value)
{
#ifdef VBOX_XPDM_MINIPORT
VideoPortWritePortUlong((PULONG)Port,Value);
+#elif defined VBOX_GUESTR3XORGMOD
+ outl(Port, Value);
#else
ASMOutU32(Port, Value);
#endif
@@ -153,6 +161,8 @@ DECLINLINE(uint8_t) VBoxVideoCmnPortReadUchar(RTIOPORT Port)
{
#ifdef VBOX_XPDM_MINIPORT
return VideoPortReadPortUchar((PUCHAR)Port);
+#elif defined VBOX_GUESTR3XORGMOD
+ return inb(Port);
#else
return ASMInU8(Port);
#endif
@@ -163,6 +173,8 @@ DECLINLINE(uint16_t) VBoxVideoCmnPortReadUshort(RTIOPORT Port)
{
#ifdef VBOX_XPDM_MINIPORT
return VideoPortReadPortUshort((PUSHORT)Port);
+#elif defined VBOX_GUESTR3XORGMOD
+ return inw(Port);
#else
return ASMInU16(Port);
#endif
@@ -173,6 +185,8 @@ DECLINLINE(uint32_t) VBoxVideoCmnPortReadUlong(RTIOPORT Port)
{
#ifdef VBOX_XPDM_MINIPORT
return VideoPortReadPortUlong((PULONG)Port);
+#elif defined VBOX_GUESTR3XORGMOD
+ return inl(Port);
#else
return ASMInU32(Port);
#endif