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 initial symbiotic swapping framework
Jack Lange [Fri, 14 Aug 2009 20:35:01 +0000 (15:35 -0500)]
palacios/include/palacios/vmm_sym_swap.h [new file with mode: 0644]
palacios/src/devices/Kconfig
palacios/src/palacios/Makefile
palacios/src/palacios/vmm_shadow_paging.c
palacios/src/palacios/vmm_shadow_paging_32.h
palacios/src/palacios/vmm_sym_swap.c [new file with mode: 0644]

diff --git a/palacios/include/palacios/vmm_sym_swap.h b/palacios/include/palacios/vmm_sym_swap.h
new file mode 100644 (file)
index 0000000..6931ea1
--- /dev/null
@@ -0,0 +1,54 @@
+/* 
+ * This file is part of the Palacios Virtual Machine Monitor developed
+ * by the V3VEE Project with funding from the United States National 
+ * Science Foundation and the Department of Energy.  
+ *
+ * The V3VEE Project is a joint project between Northwestern University
+ * and the University of New Mexico.  You can find out more at 
+ * http://www.v3vee.org
+ *
+ * Copyright (c) 2008, Jack Lange <jarusl@cs.northwestern.edu> 
+ * Copyright (c) 2008, The V3VEE Project <http://www.v3vee.org> 
+ * All rights reserved.
+ *
+ * Author: Jack Lange <jarusl@cs.northwestern.edu>
+ *
+ * This is free software.  You are permitted to use,
+ * redistribute, and modify it as specified in the file "V3VEE_LICENSE".
+ */
+
+#ifndef __VMM_SYM_SWAP_H__
+#define __VMM_SYM_SWAP_H__
+
+#ifdef __V3VEE__ 
+#ifdef CONFIG_SYMBIOTIC_SWAP
+
+#include <palacios/vmm.h>
+
+static inline int is_swapped_pte32(pte32_t * pte) {
+    return (*(uint32_t *)pte != 0);
+}
+
+
+struct v3_swap_dev {
+    addr_t (*get_page)(int index);
+
+};
+
+
+struct v3_sym_swap_state {
+    struct v3_swap_dev[256];
+
+};
+
+
+int v3_init_sym_swap(struct guest_info * info);
+
+addr_t v3_get_swapped_pg_addr(pte32_t * pte);
+
+
+
+#endif
+#endif
+
+#endif
index 38f8c9e..1452ee3 100644 (file)
@@ -254,7 +254,7 @@ config RAM_HD
 config SYM_SWAP
        bool "Symbiotic Swap disk"
        default y
-       depends on SYMBIOTIC && (LINUX_VIRTIO_BLOCK || IDE)
+       depends on SYMBIOTIC_SWAP && (LINUX_VIRTIO_BLOCK || IDE)
        help 
          Includes the symbiotic ram based swap disk
 
index c0b20f8..88f917a 100644 (file)
@@ -53,3 +53,5 @@ obj-$(CONFIG_VMX) +=          vmx.o \
 obj-$(CONFIG_INSTRUMENT_VMM) += vmm_instrument.o
 obj-$(CONFIG_PROFILE_VMM) += vmm_profiler.o 
 obj-$(CONFIG_SOCKET) +=  vmm_socket.o
+
+obj-$(CONFIG_SYMBIOTIC_SWAP) += vmm_sym_swap.o
\ No newline at end of file
index 4a4e719..e43a969 100644 (file)
 
 #include <palacios/vmm_direct_paging.h>
 
+#ifdef CONFIG_SYMBIOTIC_SWAP
+#include <palacios/vmm_sym_swap.h>
+#endif
+
 #ifndef CONFIG_DEBUG_SHADOW_PAGING
 #undef PrintDebug
 #define PrintDebug(fmt, args...)
index f96485e..4c8922b 100644 (file)
@@ -36,7 +36,7 @@ static inline int activate_shadow_pt_32(struct guest_info * info) {
     return 0;
 }
 
-#ifdef __V3_SYMBIOTIC__
+#ifdef CONFIG_SYMBIOTIC_SWAP
 static inline int is_swapped_pte32(pte32_t * pte) {
     return (*(uint32_t *)pte != 0);
 }
@@ -229,7 +229,7 @@ static int handle_pte_shadow_pagefault_32(struct guest_info * info, addr_t fault
 
        PrintDebug("Access error injecting pf to guest (guest access error=%d) (pf error code=%d)\n", 
                   guest_pte_access, *(uint_t*)&error_code);
-#ifdef __V3_SYMBIOTIC__
+#ifdef CONFIG_SYMBIOTIC_SWAP_
        if (is_swapped_pg(guest_pte)) {
            PrintError("Page fault on swapped out page\n");
 
diff --git a/palacios/src/palacios/vmm_sym_swap.c b/palacios/src/palacios/vmm_sym_swap.c
new file mode 100644 (file)
index 0000000..bb79343
--- /dev/null
@@ -0,0 +1,20 @@
+/* 
+ * This file is part of the Palacios Virtual Machine Monitor developed
+ * by the V3VEE Project with funding from the United States National 
+ * Science Foundation and the Department of Energy.  
+ *
+ * The V3VEE Project is a joint project between Northwestern University
+ * and the University of New Mexico.  You can find out more at 
+ * http://www.v3vee.org
+ *
+ * Copyright (c) 2008, Jack Lange <jarusl@cs.northwestern.edu> 
+ * Copyright (c) 2008, The V3VEE Project <http://www.v3vee.org> 
+ * All rights reserved.
+ *
+ * Author: Jack Lange <jarusl@cs.northwestern.edu>
+ *
+ * This is free software.  You are permitted to use,
+ * redistribute, and modify it as specified in the file "V3VEE_LICENSE".
+ */
+
+#include <palacios/vmm_sym_swap.h>