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.


updated test_vm
[palacios.git] / misc / test_vm / src / geekos / idt.c
index 5e23989..1000996 100644 (file)
@@ -10,7 +10,7 @@
 #include <geekos/kassert.h>
 #include <geekos/defs.h>
 #include <geekos/idt.h>
-#include <geekos/serial.h>
+#include <geekos/debug.h>
 
 /* ----------------------------------------------------------------------
  * Private data and functions
@@ -42,37 +42,17 @@ Interrupt_Handler g_interruptTable[ NUM_IDT_ENTRIES ];
 
 
 
-void DumpIDT()
-{
-  int i;
-  Print("IDT Contents:\n");
 
-  for (i=0;i<NUM_IDT_ENTRIES/16;i++) { 
-    if (s_IDT[i].ig.present) { 
-      Print("%d: segmentselector=%u, offset=%u, offsetLow=%u, segmentSelector=%u, reserved=%u, signature=%u, dpl=%u, present=%u, offsetHigh=%u\n",
-           i,
-           s_IDT[i].ig.segmentSelector,
-           (s_IDT[i].ig.offsetHigh<<16) + s_IDT[i].ig.offsetLow,
-           s_IDT[i].ig.offsetLow,
-           s_IDT[i].ig.segmentSelector,
-           s_IDT[i].ig.reserved,
-           s_IDT[i].ig.signature,
-           s_IDT[i].ig.dpl,
-           s_IDT[i].ig.present,
-           s_IDT[i].ig.offsetHigh);
-    }
-  }
-}
 
 
-void SerialDumpIDT()
+void DumpIDT()
 {
   int i;
-  SerialPrint("IDT Contents:\n");
+  PrintBoth("IDT Contents:\n");
 
   for (i=0;i<NUM_IDT_ENTRIES;i++) { 
     if (s_IDT[i].ig.present) { 
-      SerialPrint("%d: segmentselector=%u, offset=%u, offsetLow=%u, segmentSelector=%u, reserved=%u, signature=%u, dpl=%u, present=%u, offsetHigh=%u\n",
+      PrintBoth("%d: segmentselector=%u, offset=%u, offsetLow=%u, segmentSelector=%u, reserved=%u, signature=%u, dpl=%u, present=%u, offsetHigh=%u\n",
            i,
            s_IDT[i].ig.segmentSelector,
            (s_IDT[i].ig.offsetHigh<<16) + s_IDT[i].ig.offsetLow,
@@ -83,7 +63,7 @@ void SerialDumpIDT()
            s_IDT[i].ig.dpl,
            s_IDT[i].ig.present,
            s_IDT[i].ig.offsetHigh);
-      SerialPrint("\n");
+      PrintBoth("\n");
     }
   }
 }