[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Minios-devel] [UNIKRAFT/NEWLIB PATCH 1/1] Add patch to have newlib running on ARM64



Hi Julien,

We agree that it'd be good to understand why newlib has these arch-specific 
files, and why these fix the problem. In the interest of time however, I think 
the best is that we make a note of this and come back to the issue later. 
Ultimately all this patch does is mimic what newlib's native build system does, 
so in the end there's a good chance that the issue is a newlib one, rather than 
a Unikraft one. Still, we'll make a note and come back to this at a later point 
in time (I'm assuming of course you don't have time to look into this).

Thanks,

-- Felipe

On 19.12.19, 14:00, "Minios-devel on behalf of Julien Grall" 
<minios-devel-bounces@xxxxxxxxxxxxxxxxxxxx on behalf of julien@xxxxxxx> wrote:

    
    
    On 19/12/2019 12:35, Santiago Pagani wrote:
    > Hi Julien,
    > 
    > The problem is the same one encountered by Justin, quoted "some fdt nodes 
are parsed incorrectly, especially for those compatible strings with "\0"". 
This seems to be a newlib bug when compiling for ARM64.
    > 
    > Instead of using Justin's workaround that adds the 
-DPREFER_SIZE_OVER_SPEED flag, this patch attempts to solve it in a more robust 
way by using the machine specific source files, written and tested for ARM64.
    
    That's a matter of perspective, there is still nothing in the stack 
    trace below proving this is a newlib bug. Your changes may just make 
    harder to reproduce the bug.
    
    > 
    > Without the patch, the output we see is:
    > qemu-system-aarch64 -machine virt -cpu cortex-a53 -display none -serial 
stdio -m 32M -kernel ./build/helloworld_kvm-arm64
    > [    0.000000] Info: [libkvmplat] setup.cFound device tree on: %p
    >   @ 51   : Found device tree on: 0x40000000
    > [    0.000000] Info: [libkvmplat] pl011.clibkvmplat @ 119  : Serial 
initializing
    > [    0.000000] Info: [libkvmplat] pl011.clibkvmplat @ 139  : Found PL011 
UART on: 0x9000000
    > [    0.000000] Info: [libkvmplat] pl011.clibkvmplat @ 142  : PL011 UART 
initialized
    > [    0.000000] Info: [libkvmplat] setup.cFound device tree on: %p
    >   @ 213  : Entering from KVM (arm64)...
    > [    0.000000] Info: [libkvmplat] setup.cFound device tree on: %p
    >   @ 199  : No command line found
    > [    0.000000] Info: [libkvmplat] setup.cFound device tree on: %p
    >   @ 69   : No PSCI conduit found in DTB
    > [    0.000000] Info: [libkvmplat] setup.cFound device tree on: %p
    >   @ 93   : Support PSCI from PSCI-0.2
    > [    0.000000] Warn: [libkvmplat] setup.cFound device tree on: %p
    >   @ 140  : Currently, we support only one memory bank!
    > [    0.000000] Info: [libkvmgicv2] gic-v2.c @ 423  : Probing GICv2...
    > [    0.000000] dbg:  [libkvmofw] fdt.clibkvmofw @ 173  : reached root node
    > [    0.000000] dbg:  [libkvmofw] fdt.clibkvmofw @ 173  : reached root node
    > [    0.000000] Info: [libkvmgicv2] gic-v2.c @ 442  : Found GICv2 on:
    >   Distributor  : 0x8000000 - 0x7ffffff
    > [    0.000000] Info: [libkvmgicv2] gic-v2.c @ 446  :      CPU interface: 
0x1000000000000 - 0x100000800ffff
    > [    0.000000] Info: [libkvmgicv2] gic-v2.c @ 354  : GICv2 Max CPU 
interface:1
    > [    0.000000] Info: [libkvmgicv2] gic-v2.c @ 360  : GICv2 Max interrupt 
lines:32
    > [    0.000000] CRIT: [libkvmplat] traps.c  SP       : 0x%016lx
    >    ESR_EL1  : 0x%016lx
    >    ELR_EL1  : 0x%016lx
    >    LR (x30) : 0x%016lx
    >    PSTATE   : 0x%016lx
    >    FAR_EL1  : 0x%016lx
    >    x%02d ~ x%02d: 0x%016lx 0x%016lx 0x%016lx 0x%016lx
    >    x28 ~ x29: 0x%016lx 0x%016lx
    > Unikraft: EL%d invalid %s trap caught
    > Unikraft: EL1 sync trap caught
    
    This does not give much clue as no values are printed. Could you update 
    Unikraft to print?
    
    I am particularly interested to undersand the first one as the others 
    are probably just a consequence of it.
    
    Cheers,
    
    -- 
    Julien Grall
    
    _______________________________________________
    Minios-devel mailing list
    Minios-devel@xxxxxxxxxxxxxxxxxxxx
    https://lists.xenproject.org/mailman/listinfo/minios-devel

_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.