--- /dev/null
+/*
+ * Jailhouse, a Linux-based partitioning hypervisor
+ *
+ * Minimal configuration for demo inmates, 1 CPU, 1 MB RAM, 1 serial port
+ *
+ * Copyright (c) Siemens AG, 2013
+ *
+ * Authors:
+ * Jan Kiszka <jan.kiszka@siemens.com>
+ *
+ * This work is licensed under the terms of the GNU GPL, version 2. See
+ * the COPYING file in the top-level directory.
+ */
+
+#include <linux/types.h>
+#include <jailhouse/cell-config.h>
+
+#define ARRAY_SIZE(a) sizeof(a) / sizeof(a[0])
+
+struct {
+ struct jailhouse_cell_desc cell;
+ __u64 cpus[1];
+ struct jailhouse_memory mem_regions[4];
+ __u8 pio_bitmap[0x2000];
+ struct jailhouse_pci_device pci_devices[1];
+ struct jailhouse_pci_capability pci_caps[0];
+} __attribute__((packed)) config = {
+ .cell = {
+ .signature = JAILHOUSE_CELL_DESC_SIGNATURE,
+ .name = "hpet-demo",
+
+ .cpu_set_size = sizeof(config.cpus),
+ .num_memory_regions = ARRAY_SIZE(config.mem_regions),
+ .num_irqchips = 0,
+ .pio_bitmap_size = ARRAY_SIZE(config.pio_bitmap),
+ .num_pci_devices = ARRAY_SIZE(config.pci_devices),
+ .num_pci_caps = ARRAY_SIZE(config.pci_caps),
+ },
+
+ .cpus = {
+ 0x8,
+ },
+
+ .mem_regions = {
+ /* low RAM */ {
+ .phys_start = 0x3b600000,
+ .virt_start = 0,
+ .size = 0x00100000,
+ .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
+ JAILHOUSE_MEM_EXECUTE | JAILHOUSE_MEM_DMA |
+ JAILHOUSE_MEM_LOADABLE,
+ },
+ /* communication region */ {
+ .virt_start = 0x00100000,
+ .size = 0x00001000,
+ .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
+ JAILHOUSE_MEM_COMM_REGION,
+ },
+ /* RAM */ {
+ .phys_start = 0x3f200000,
+ .virt_start = 0x3f200000,
+ .size = 0xddf000,
+ .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
+ JAILHOUSE_MEM_EXECUTE | JAILHOUSE_MEM_DMA,
+ },
+ // /* ACPI */ {
+ // .phys_start = 0x3ffdf000,
+ // .virt_start = 0x3ffdf000,
+ // .size = 0x30000,
+ // .flags = JAILHOUSE_MEM_READ |
+ // JAILHOUSE_MEM_ROOTSHARED,
+ // },
+ /* MemRegion: fed00000-fed003ff : PNP0103:00 */
+ {
+ .phys_start = 0xfed00000,
+ .virt_start = 0xfed00000,
+ .size = 0x1000,
+ .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
+ JAILHOUSE_MEM_ROOTSHARED,
+ },
+ },
+
+ .pio_bitmap = {
+ [ 0/8 ... 0x3f7/8] = -1,
+ [ 0x3f8/8 ... 0x3ff/8] = 0, /* serial1 */
+ [ 0x400/8 ... 0xe00f/8] = -1,
+ [0xe010/8 ... 0xe017/8] = 0, /* OXPCIe952 serial1 */
+ [0xe018/8 ... 0xffff/8] = -1,
+ },
+
+ .pci_devices = {
+ {
+ .type = JAILHOUSE_PCI_TYPE_IVSHMEM,
+ .domain = 0x0,
+ .bdf = (0x08<<3),
+ .bar_mask = {
+ 0xffffff00, 0xffffffff, 0x00000000,
+ 0x00000000, 0xffffffe0, 0xffffffff,
+ },
+ .shmem_region = 3,
+ .num_msix_vectors = 1,
+ },
+ },
+};
\ No newline at end of file
struct jailhouse_memory mem_regions[13];
struct jailhouse_irqchip irqchips[1];
__u8 pio_bitmap[0x2000];
- struct jailhouse_pci_device pci_devices[8];
+ struct jailhouse_pci_device pci_devices[9];
struct jailhouse_pci_capability pci_caps[5];
} __attribute__((packed)) config = {
.header = {
[ 0x3b0/8 ... 0x3df/8] = 0, /* VGA */
[ 0x3e0/8 ... 0x3ef/8] = -1,
[ 0x3f0/8 ... 0x3f7/8] = 0, /* floppy */
- [ 0x3f8/8 ... 0x3ff/8] = -1,
+ [ 0x3f8/8 ... 0x3ff/8] = -1/*0*/,
[ 0x400/8 ... 0x407/8] = 0xfb, /* invalid but accessed by X */
[ 0x408/8 ... 0x5657/8] = -1,
[0x5658/8 ... 0x565f/8] = 0xf0, /* vmport */
.msix_region_size = 0x1000,
.msix_address = 0xfebf6000,
},
+ //added by me ---------------------------------
+ {
+ .type = JAILHOUSE_PCI_TYPE_IVSHMEM,
+ .domain = 0x0,
+ .bdf = (0x08<<3),
+ .bar_mask = {
+ 0xffffff00, 0xffffffff, 0x00000000,
+ 0x00000000, 0xffffffe0, 0xffffffff,
+ },
+ .shmem_region = 11,
+ .num_msix_vectors = 1,
+ },
+ //--------------------------------------------------
{
.type = JAILHOUSE_PCI_TYPE_IVSHMEM,
.domain = 0x0,
.shmem_region = 12,
.num_msix_vectors = 1,
},
+
},
.pci_caps = {