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 device number in pci
Jack Lange [Mon, 16 Mar 2009 21:42:41 +0000 (16:42 -0500)]
palacios/src/devices/pci.c

index 19eb21d..e7927b7 100644 (file)
@@ -125,7 +125,7 @@ static int get_free_dev_num(struct pci_bus * bus) {
            // availability
            for (j = 0; j < 8; j++) {
                if (!(bus->dev_map[i] & (0x1 << j))) {
-                   return i * 8 + j;
+                   return ((i * 8) + j) * 8;
                }
            }
        }
@@ -135,7 +135,7 @@ static int get_free_dev_num(struct pci_bus * bus) {
 }
 
 static void allocate_dev_num(struct pci_bus * bus, int dev_num) {
-    int major = dev_num / 8;
+    int major = (dev_num / 8) / 8;
     int minor = dev_num % 8;
 
     bus->dev_map[major] |= (0x1 << minor);