Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


removed references to GeekOS and added some namespace changes,
[palacios.git] / palacios / src / devices / generic.c
index d9bf3ea..549ba07 100644 (file)
@@ -5,7 +5,7 @@
 #include <devices/generic.h>
 #include <palacios/vmm.h>
 #include <palacios/vmm_types.h>
-#include <geekos/io.h>
+
 
 
 
@@ -76,17 +76,19 @@ int generic_write_port_passthrough(ushort_t port,
 
   switch (length) {
   case 1:
-    Out_Byte(port, ((uchar_t*)src)[0]);
+
+    v3_outb(port,((uchar_t*)src)[0]);
     break;
   case 2:
-    Out_Word(port, ((ushort_t*)src)[0]);
+    v3_outw(port,((ushort_t*)src)[0]);
     break;
   case 4:
-    Out_DWord(port, ((uint_t*)src)[0]);
+    v3_outdw(port,((uint_t*)src)[0]);
+
     break;
   default:
     for (i = 0; i < length; i++) { 
-      Out_Byte(port, ((uchar_t*)src)[i]);
+      v3_outb(port, ((uchar_t*)src)[i]);
     }
   } //switch length
 
@@ -108,17 +110,17 @@ int generic_read_port_passthrough(ushort_t port,
 
     switch (length) {
     case 1:
-      ((uchar_t*)src)[0] = In_Byte(port);
+      ((uchar_t*)src)[0] = v3_inb(port);
       break;
     case 2:
-      ((ushort_t*)src)[0] = In_Word(port);
+      ((ushort_t*)src)[0] = v3_inw(port);
       break;
     case 4:
-      ((uint_t*)src)[0] = In_DWord(port);
+      ((uint_t*)src)[0] = v3_indw(port);
       break;
     default:
       for (i = 0; i < length; i++) { 
-       ((uchar_t*)src)[i] = In_Byte(port);
+       ((uchar_t*)src)[i] = v3_inb(port);
       }
     }//switch length