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.


added full device support
[palacios.git] / palacios / src / geekos / vm.c
index aa3d7a1..a8ef613 100644 (file)
@@ -4,6 +4,8 @@
 #include <geekos/serial.h>
 #include <geekos/vm.h>
 #include <geekos/screen.h>
+#include <palacios/vmm_dev_mgr.h>
+#include <devices/nvram.h>
 
 #define SPEAKER_PORT 0x61
 
@@ -172,7 +174,7 @@ int RunVMM(struct Boot_Info * bootInfo) {
     os_hooks.vaddr_to_paddr = &Identity;
     os_hooks.paddr_to_vaddr = &Identity;
 
-
     //   DumpGDT();
     Init_VMM(&os_hooks, &vmm_ops);
   
@@ -284,6 +286,14 @@ int RunVMM(struct Boot_Info * bootInfo) {
       hook_io_port(&(vm_info.io_map), 0x402, &IO_Read, &IO_BOCHS_debug, NULL);
       hook_io_port(&(vm_info.io_map), 0x403, &IO_Read, &IO_Write_to_Serial, NULL);
 
+      {
+       struct vm_device * nvram = nvram_create();
+       attach_device(&(vm_info), nvram);
+       
+       PrintDebugDevMgr(&(vm_info.dev_mgr));
+       
+      }
+
       vm_info.rip = 0xfff0;
       vm_info.vm_regs.rsp = 0x0;
     }