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.


reformatting of the source files
[palacios.git] / palacios / src / palacios / vm_dev.c
index 6257a98..ac034ca 100644 (file)
 
 static struct vm_device * v3_allocate_device() {
 
-  struct vm_device * dev = NULL;
-  dev = (struct vm_device*)V3_Malloc(sizeof(struct vm_device));
+    struct vm_device * dev = NULL;
+    dev = (struct vm_device*)V3_Malloc(sizeof(struct vm_device));
 
-  V3_ASSERT(dev != NULL);
+    V3_ASSERT(dev != NULL);
 
-  dev->ops = NULL;
-  memset(dev->name, 0, 32);
-  dev->vm = NULL;
-  dev->private_data = NULL;
+    dev->ops = NULL;
+    memset(dev->name, 0, 32);
+    dev->vm = NULL;
+    dev->private_data = NULL;
 
 
-  INIT_LIST_HEAD(&(dev->io_hooks));
-  dev->num_io_hooks = 0;
+    INIT_LIST_HEAD(&(dev->io_hooks));
+    dev->num_io_hooks = 0;
 
-  INIT_LIST_HEAD(&(dev->mem_hooks));
-  dev->num_mem_hooks = 0;
+    INIT_LIST_HEAD(&(dev->mem_hooks));
+    dev->num_mem_hooks = 0;
   
-  INIT_LIST_HEAD(&(dev->irq_hooks));
-  dev->num_irq_hooks = 0;
+    INIT_LIST_HEAD(&(dev->irq_hooks));
+    dev->num_irq_hooks = 0;
 
-  return dev;
+    return dev;
 }
 
 struct vm_device * v3_create_device(char * name, struct vm_device_ops * ops, void * private_data) {
-  struct vm_device * dev = v3_allocate_device();
+    struct vm_device * dev = v3_allocate_device();
 
-  strncpy(dev->name, name, 32);
-  dev->ops = ops;
-  dev->private_data = private_data;
+    strncpy(dev->name, name, 32);
+    dev->ops = ops;
+    dev->private_data = private_data;
 
-  return dev;
+    return dev;
 }
 
 void v3_free_device(struct vm_device * dev) {
-  V3_Free(dev);
+    V3_Free(dev);
 }