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.


General fixes and clean up
Jack Lange [Tue, 14 Oct 2008 19:22:04 +0000 (14:22 -0500)]
palacios/build/Makefile
palacios/include/geekos/socket.h [deleted file]
palacios/src/devices/8259a.c
palacios/src/palacios/vmm_config.c
palacios/src/palacios/vmm_intr.c

index 0cfd820..7a4c23d 100644 (file)
@@ -78,7 +78,7 @@ endif
 ifeq ($(DEBUG_INTERRUPTS),1)
 DEBUG_SECTIONS := $(DEBUG_SECTIONS) -DDEBUG_INTERRUPTS
 else 
-ifeq ($(DEBUG_DEBUG_INTERRUPTS),0) 
+ifeq ($(DEBUG_INTERRUPTS),0) 
 DEBUG_SECTIONS := $(DEBUG_SECTIONS) -UDEBUG_INTERRUPTS
 endif
 endif
@@ -147,6 +147,15 @@ DEBUG_SECTIONS := $(DEBUG_SECTIONS) -UDEBUG_RAMDISK
 endif
 endif
 
+ifeq ($(TRACE_RAMDISK),1)
+DEBUG_SECTIONS := $(DEBUG_SECTIONS -DTRACE_RAMDISK
+else
+ifeq ($(TRACE_RAMDSK),0)
+DEBUG_SECTIONS := $(DEBUG_SECTIONS) -UTRACE_RAMDISK
+endif
+endif
+
+
 
 #DEBUG_SECTIONS := $(DEBUG_SECTIONS) -DTEST_NE2K
 
@@ -330,7 +339,7 @@ FD_SECTORS_PER_TRACK := $(PERL) $(PROJECT_ROOT)/scripts/numsecs_per_track
 
 # Flags used for all C source files
 #GENERAL_OPTS := -O -Wall $(EXTRA_C_OPTS) $(VMM_FLAGS) -fPIC #-fvisibility=hidden
-GENERAL_OPTS :=  -Wall $(EXTRA_C_OPTS) $(VMM_FLAGS) -fPIC #-fvisibility=hidden
+GENERAL_OPTS :=  -O -Wall  $(EXTRA_C_OPTS) $(VMM_FLAGS) -fPIC #-fvisibility=hidden
 CC_GENERAL_OPTS := $(GENERAL_OPTS) -Werror 
 
 # Flags used for VMM C source files
diff --git a/palacios/include/geekos/socket.h b/palacios/include/geekos/socket.h
deleted file mode 100644 (file)
index fbc47ed..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/* (c) 2008, Jack Lange <jarusl@cs.northwestern.edu> */
-/* (c) 2008, The V3VEE Project <http://www.v3vee.org> */
-
-#ifndef GEEKOS_SOCKET_H
-#define GEEKOS_SOCKET_H
-
-#include <geekos/ring_buffer.h>
-#include <geekos/kthread.h>
-
-#ifdef UIP
-#include <uip/uip.h>
-
-
-typedef enum {WAITING, CLOSED, LISTEN, ESTABLISHED} sock_state_t;
-
-struct socket {
-  int in_use;
-  struct Thread_Queue recv_wait_queue;
-  struct ring_buffer *send_buf;
-  struct ring_buffer *recv_buf;
-  struct uip_conn *con;
-
-  sock_state_t state;
-
-};
-
-
-void init_socket_layer();
-
-int connect(const uchar_t ip_addr[4], ushort_t port);
-int close(const int sockfd);
-int recv(int sockfd, void * buf, uint_t len);
-int send(int sockfd, void * buf, uint_t len);
-
-void set_ip_addr(uchar_t addr[4]);
-
-#endif /* UIP */
-
-
-#endif
index b14bfe5..44c73d1 100644 (file)
@@ -203,22 +203,20 @@ static int pic_raise_intr(void * private_data, int irq) {
 }
 
 
-/*Zheng 07/30/2008*/
-
-static int pic_lower_intr(void *private_data, int irq_no) {
+static int pic_lower_intr(void *private_data, int irq) {
 
   struct pic_internal *state = (struct pic_internal*)private_data;
 
-  PrintDebug("[pic_lower_intr] IRQ line %d now low\n", (unsigned) irq_no);
-  if (irq_no <= 7) {
+  PrintDebug("[pic_lower_intr] IRQ line %d now low\n", irq);
+  if (irq <= 7) {
 
-    state->master_irr &= ~(1 << irq_no);
+    state->master_irr &= ~(1 << irq);
     if ((state->master_irr & ~(state->master_imr)) == 0) {
       PrintDebug("\t\tFIXME: Master maybe should do sth\n");
     }
-  } else if ((irq_no > 7) && (irq_no <= 15)) {
+  } else if ((irq > 7) && (irq < 16)) {
 
-    state->slave_irr &= ~(1 << (irq_no - 8));
+    state->slave_irr &= ~(1 << (irq - 8));
     if ((state->slave_irr & (~(state->slave_imr))) == 0) {
       PrintDebug("\t\tFIXME: Slave maybe should do sth\n");
     }
@@ -316,13 +314,13 @@ static int pic_end_irq(void * private_data, int irq) {
 */
 
 
-/*Zheng 07/30/2008*/
+
 static struct intr_ctrl_ops intr_ops = {
   .intr_pending = pic_intr_pending,
   .get_intr_number = pic_get_intr_number,
   .raise_intr = pic_raise_intr,
   .begin_irq = pic_begin_irq,
-  .lower_intr = pic_lower_intr, //Zheng added
+  .lower_intr = pic_lower_intr, 
 
 };
 
index fa4fe80..ba2529a 100644 (file)
@@ -364,6 +364,8 @@ int config_guest(struct guest_info * info, struct v3_vm_config * config_ptr) {
   
 
   if (!use_ramdisk) {
+    PrintDebug("Hooking IDE IRQs\n");
+
     //primary ide
     v3_hook_passthrough_irq(info, 14);
   
index 6bdca1a..84a645b 100644 (file)
@@ -183,7 +183,7 @@ int v3_lower_irq(struct guest_info * info, int irq) {
       (info->intr_state.controller->lower_intr)) {
     info->intr_state.controller->lower_intr(info->intr_state.controller_state, irq);
   } else {
-    PrintDebug("There is no registered Interrupt Controller... (NULL POINTER)\n");
+    PrintError("There is no registered Interrupt Controller... (NULL POINTER)\n");
     return -1;
   }
 
@@ -202,7 +202,7 @@ int v3_raise_irq(struct guest_info * info, int irq) {
       (info->intr_state.controller->raise_intr)) {
     info->intr_state.controller->raise_intr(info->intr_state.controller_state, irq);
   } else {
-    PrintDebug("There is no registered Interrupt Controller... (NULL POINTER)\n");
+    PrintError("There is no registered Interrupt Controller... (NULL POINTER)\n");
     return -1;
   }