]> rtime.felk.cvut.cz Git - jailhouse.git/blobdiff - configs/fiasco-demo.c
configs: update configs to achieve the compatibility with the new JH version
[jailhouse.git] / configs / fiasco-demo.c
index f87c91466188209801784d64464707e35485e453..bcd575c75b160d431d57ecaa21c59f180c334cdb 100755 (executable)
 
 #define ARRAY_SIZE(a) sizeof(a) / sizeof(a[0])
 
-struct {
-       struct jailhouse_cell_desc cell;
-       __u64 cpus[1];
-       struct jailhouse_memory mem_regions[1]; 
-       struct jailhouse_irqchip irqchips[0];
-       __u8 pio_bitmap[0x2000];
-       struct jailhouse_pci_device pci_devices[0];
-} __attribute__((packed)) config = {
-       .cell = {
-               .signature = JAILHOUSE_CELL_DESC_SIGNATURE,
-               .name = "fiasco-demo",
-               .flags = 0/*JAILHOUSE_CELL_PASSIVE_COMMREG*/,
+ struct {
+               struct jailhouse_cell_desc cell;
+               __u64 cpus[1];
+               struct jailhouse_memory mem_regions[1];
+               struct jailhouse_irqchip irqchips[0];
+               struct jailhouse_cache cache_regions[1];
+               __u8 pio_bitmap[0x2000];
+               struct jailhouse_pci_device pci_devices[0];
+        } __attribute__((packed)) config = {
+               .cell = {
+                       .signature = JAILHOUSE_CELL_DESC_SIGNATURE,
+                       .name = "fiasco-demo",
+                       .flags = 0/*JAILHOUSE_CELL_PASSIVE_COMMREG*/,
 
-               .cpu_set_size = sizeof(config.cpus),
-               .num_memory_regions = ARRAY_SIZE(config.mem_regions),
-               .num_irqchips = ARRAY_SIZE(config.irqchips),
-               .pio_bitmap_size = ARRAY_SIZE(config.pio_bitmap),
-               .num_pci_devices = ARRAY_SIZE(config.pci_devices),
-               .num_pci_caps = 0,
-       },
+                       .cpu_set_size = sizeof(config.cpus),
+                       .num_memory_regions = ARRAY_SIZE(config.mem_regions),
+                       .num_irqchips = ARRAY_SIZE(config.irqchips),
+                       .num_cache_regions = ARRAY_SIZE(config.cache_regions),
+                       .pio_bitmap_size = ARRAY_SIZE(config.pio_bitmap),
+                       .num_pci_devices = ARRAY_SIZE(config.pci_devices),
+                       .num_pci_caps = 0,
+               },
 
-       .cpus = {
-               0b000010,
-       },
+               .cpus = {
+                       0b000010,
+               },
+
+               .mem_regions = {
+                       /* low RAM */ {
+                               .phys_start = 0x3b600000,
+                               .virt_start = 0,
+                               .size = 0x3c00000,
+                               .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
+                               JAILHOUSE_MEM_EXECUTE | JAILHOUSE_MEM_DMA |
+                               JAILHOUSE_MEM_LOADABLE,
+                       },
+               },
 
-       .mem_regions = {
-               /* low RAM */ {
-                       .phys_start = 0x3b600000,
-                       .virt_start = 0,
-                       .size = 0x3c00000,
-                       .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
-                               JAILHOUSE_MEM_EXECUTE | JAILHOUSE_MEM_DMA |
-                               JAILHOUSE_MEM_LOADABLE,
+                .cache_regions = {
+               {
+                               .start = 0,
+                               .size = 2,
+                               .type = JAILHOUSE_CACHE_L3,
                },
-       },
+        },
+
+        .pio_bitmap = {
 
-       .pio_bitmap = {
-                       
-               [     0/8 ...   0x3f/8] = -1,
-               [  0x20/8 ...   0x28/8] = 0xfc, /* PIC Master 0x20 0x21 */
-               [  0x29/8 ...   0x3f/8] = -1,                   
+               [     0/8 ...   0x1f/8] = -1,
+               [  0x20/8 ...   0x27/8] = 0xfc, /* PIC Master 0x20 0x21 */
+               [  0x28/8 ...   0x3f/8] = -1,
                [  0x40/8 ...   0x47/8] = 0xf0, /* PIT */
-               [  0x48/8 ...   0x5f/8] = -1,
-               [  0x60/8 ...   0x67/8] = 0,
-               [  0x68/8 ...   0x7f/8] = -1,
-               [  0x80/8 ...   0x88/8] = 0xfe, //delay
-               [  0x89/8 ...   0x99/8] = -1,
-               [  0xA0/8 ...   0xA8/8] = 0xfc, /* PIC Slave 0xA0 0xA1 */
-               [ 0xA9/8  ...  0x3f7/8] = -1,
+               [  0x48/8 ...   0x5f/8] = -1,
+               [  0x60/8 ...   0x67/8] = 0,
+               [  0x68/8 ...   0x7f/8] = -1,
+               [  0x80/8 ...   0x87/8] = 0xfe, //delay
+               [  0x88/8 ...   0x99/8] = -1,
+               [  0xa0/8 ...   0xa7/8] = 0xfc, /* PIC Slave 0xA0 0xA1 */
+               [  0xa8/8 ...  0x3f7/8] = -1,
                [ 0x3f8/8 ...  0x3ff/8] = 0, /* serial0 */
                [ 0x400/8 ... 0xe00f/8] = -1,
                [0xe010/8 ... 0xe017/8] = -1, /* OXPCIe952 serial1 */