[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 0/4] mini-os: initial ARM support
Hi Thomas, all Thank you, it is very interesting for me since I am trying to port XEN stuff to embedded OS and using Mini-OS as example. I tried to run Mini-OS as domU and I got a hypervisor crash at an early initialization stage ( I took Mini-OS from github: https://github.com/talex5/xen ("proposed" branch) As I understand correctly this branch contains all necessary patches to build and verify Mini-OS on ARM (I so have thought because the last 4 commits from this branch correspond to patch series in current thread). Is it correct? My configuration: - hypervisor - XEN 4.4.0 - platform - ARM32 - dom0 - Linux Kernel 3.8 - domU - Mini-OS / # (d1) dtb_pointer : 87fff000 (XEN) Guest data abort: Translation fault at level 2 (XEN) gva=7002e65c (XEN) gpa=000000007002e65c (XEN) size=2 sign=0 write=0 reg=1 (XEN) eat=0 cm=0 s1ptw=0 dfsc=6 (XEN) dom1 IPA 0x000000007002e65c (XEN) P2M @ 02840080 mfn:0xc2004 (XEN) 1ST[0x1] = 0x00400000c200367f (XEN) 2ND[0x180] = 0x0000000000000000 (XEN) ----[ Xen-4.4.0 arm32 debug=y Not tainted ]---- (XEN) CPU: 0 (XEN) PC: 8000d14c (XEN) CPSR: 600001d3 MODE:32-bit Guest SVC (XEN) R0: 8001a22c R1: 8002b218 R2: 7002e65c R3: 7002e65c (XEN) R4: 87fff000 R5: 00000000 R6: 00000000 R7: 00000000 (XEN) R8: 00000000 R9: 00000000 R10:00000000 R11:8001ff74 R12:deadbeef (XEN) USR: SP: 00000000 LR: 00000000 (XEN) SVC: SP: 8001ff60 LR: 8000d468 SPSR:00000000 (XEN) ABT: SP: 00000000 LR: 00000000 SPSR:00000000 (XEN) UND: SP: 00000000 LR: 00000000 SPSR:00000000 (XEN) IRQ: SP: 00000000 LR: 00000000 SPSR:00000000 (XEN) FIQ: SP: 00000000 LR: c2c2c2c2 SPSR:00000000 (XEN) FIQ: R8: 00000000 R9: 00000000 R10:00000000 R11:00000000 R12:00000000 (XEN) (XEN) SCTLR: 00c50078 (XEN) TCR: 00000000 (XEN) TTBR0: 0000000080024000 (XEN) TTBR1: 0000000000000000 (XEN) IFAR: 00000000, IFSR: 00000000 (XEN) DFAR: 00000000, DFSR: 00000000 (XEN) (XEN) VTCR_EL2: 80002558 (XEN) VTTBR_EL2: 00020000c2004000 (XEN) (XEN) SCTLR_EL2: 30cd187f (XEN) HCR_EL2: 0000000000282835 (XEN) TTBR0_EL2: 00000000fecdf000 (XEN) (XEN) ESR_EL2: 93810006 (XEN) HPFAR_EL2: 00000000007002e0 (XEN) HDFAR: 7002e65c (XEN) HIFAR: 00000000 (XEN) (XEN) Guest stack trace from sp=8001ff60: (XEN) 8002b218 8001a22c 80019324 8002b218 c2c2c2c2 8001ff8c 8001ff38 00000000 (XEN) 80022230 000003ff 00000000 80022230 00000000 00000000 800175bc 00000001 (XEN) 00000001 00000000 00000003 000003ff 8001ffbc 80017604 8001ffcc 8000d728 (XEN) 8001fffc 8001792c 8001a22c 87fff000 ffffffff 8002820c 00000000 87fff000 (XEN) 00007ff0 00000000 00000000 00000000 00080022 00000000 00000000 80008038 (XEN) domain_crash_sync called from traps.c:1573 (XEN) Domain 1 (vcpu#0) crashed on cpu#0: (XEN) ----[ Xen-4.4.0 arm32 debug=y Not tainted ]---- (XEN) CPU: 0 (XEN) PC: 8000d14c (XEN) CPSR: 600001d3 MODE:32-bit Guest SVC (XEN) R0: 8001a22c R1: 8002b218 R2: 7002e65c R3: 7002e65c (XEN) R4: 87fff000 R5: 00000000 R6: 00000000 R7: 00000000 (XEN) R8: 00000000 R9: 00000000 R10:00000000 R11:8001ff74 R12:deadbeef (XEN) USR: SP: 00000000 LR: 00000000 (XEN) SVC: SP: 8001ff60 LR: 8000d468 SPSR:00000000 (XEN) ABT: SP: 00000000 LR: 00000000 SPSR:00000000 (XEN) UND: SP: 00000000 LR: 00000000 SPSR:00000000 (XEN) IRQ: SP: 00000000 LR: 00000000 SPSR:00000000 (XEN) FIQ: SP: 00000000 LR: c2c2c2c2 SPSR:00000000 (XEN) FIQ: R8: 00000000 R9: 00000000 R10:00000000 R11:00000000 R12:00000000 (XEN) (XEN) SCTLR: 00c50078 (XEN) TCR: 00000000 (XEN) TTBR0: 0000000080024000 (XEN) TTBR1: 0000000000000000 (XEN) IFAR: 00000000, IFSR: 00000000 (XEN) DFAR: 00000000, DFSR: 00000000 (XEN) (XEN) VTCR_EL2: 80002558 (XEN) VTTBR_EL2: 00020000c2004000 (XEN) (XEN) SCTLR_EL2: 30cd187f (XEN) HCR_EL2: 0000000000282835 (XEN) TTBR0_EL2: 00000000fecdf000 (XEN) (XEN) ESR_EL2: 93810006 (XEN) HPFAR_EL2: 00000000007002e0 (XEN) HDFAR: 7002e65c (XEN) HIFAR: 00000000 (XEN) (XEN) Guest stack trace from sp=8001ff60: (XEN) 8002b218 8001a22c 80019324 8002b218 c2c2c2c2 8001ff8c 8001ff38 00000000 (XEN) 80022230 000003ff 00000000 80022230 00000000 00000000 800175bc 00000001 (XEN) 00000001 00000000 00000003 000003ff 8001ffbc 80017604 8001ffcc 8000d728 (XEN) 8001fffc 8001792c 8001a22c 87fff000 ffffffff 8002820c 00000000 87fff000 (XEN) 00007ff0 00000000 00000000 00000000 00080022 00000000 00000000 80008038 (XEN) mm.c:1192:d0 gnttab_mark_dirty not implemented yet But the Mini-OS from "next" branch boots without crashes (I changed GIC addresses only): diff --git a/extras/mini-os/drivers/gic.c b/extras/mini-os/drivers/gic.c index 6b3fd93..ef567d2 100644 --- a/extras/mini-os/drivers/gic.c +++ b/extras/mini-os/drivers/gic.c @@ -184,6 +184,12 @@ void gic_init(void) {  }  gic.gicd_base = (char *) (long) fdt64_to_cpu(reg[0]);  gic.gicc_base = (char *) (long) fdt64_to_cpu(reg[2]); + unsigned cbar; + __asm__ __volatile__("mrc p15, 4, %0, c15, c0, 0" : "=r"(cbar)); + + gic.gicd_base = (char *) (cbar + 0x1000); + gic.gicc_base = (char *) (cbar + 0x2000); +  printk("Found GIC: gicd_base = %p, gicc_base = %p\n", gic.gicd_base, gic.gicc_base);  break;  } Also, could you, please, explain me some generic things about Mini-OS: 1. Is HAVE_LIBC a necessary config? I mean if I build Mini-OS without proper LIBC support will the Mini-OS to operate fully (are there any restrictions?) 2. If yes, what should I do to build Mini-OS with proper LIBC support? Unfortunately, it is not clear for me. On Mon, Jun 2, 2014 at 8:49 PM, Thomas Leonard <talex5@xxxxxxxxx> wrote: This series is Karim's initial ARM support, broken up into smaller patches. -- _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |