[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v4 1/2] arch/riscv: initial RISC-V support to build/run minimal Xen
On Thu, 2023-01-05 at 18:10 +0200, Oleksii wrote: > On Thu, 2023-01-05 at 15:48 +0000, Andrew Cooper wrote: > > On 05/01/2023 1:40 pm, Jan Beulich wrote: > > > On 05.01.2023 13:01, Oleksii Kurochko wrote: > > > > To run in debug mode should be done the following instructions: > > > > $ qemu-system-riscv64 -M virt -smp 1 -nographic -m 2g \ > > > > -kernel xen/xen -s -S > > > > # In separate terminal: > > > > $ riscv64-buildroot-linux-gnu-gdb > > > > $ target remote :1234 > > > > $ add-symbol-file <xen_src>/xen/xen-syms 0x80200000 > > > > $ hb *0x80200000 > > > > $ c # it should stop at instruction j 0x80200000 <start> > > > This suggests to me that Xen is meant to run at VA 0x80200000, > > > whereas ... > > > > > > > --- a/xen/arch/riscv/include/asm/config.h > > > > +++ b/xen/arch/riscv/include/asm/config.h > > > > @@ -1,6 +1,9 @@ > > > > #ifndef __RISCV_CONFIG_H__ > > > > #define __RISCV_CONFIG_H__ > > > > > > > > +#include <xen/const.h> > > > > +#include <xen/page-size.h> > > > > + > > > > #if defined(CONFIG_RISCV_64) > > > > # define LONG_BYTEORDER 3 > > > > # define ELFSIZE 64 > > > > @@ -28,7 +31,7 @@ > > > > > > > > /* Linkage for RISCV */ > > > > #ifdef __ASSEMBLY__ > > > > -#define ALIGN .align 2 > > > > +#define ALIGN .align 4 > > > > > > > > #define ENTRY(name) \ > > > > .globl name; \ > > > > @@ -36,6 +39,10 @@ > > > > name: > > > > #endif > > > > > > > > +#define XEN_VIRT_START _AT(UL, 0x00200000) > > > ... here you specify a much lower address (and to be honest even > > > 0x80200000 > > > looks pretty low to me for 64-bit, and perhaps even for 32-bit). > > > Could you > > > clarify what the plans here are? Maybe this is merely a temporary > > > thing, > > > but not called out as such? > > > > It's stale from v1 which had: > > > > #define XEN_VIRT_START 0x80200000 Let's switch XEN_VIRT_START to 0x0000000080200000 while we don't have any MMU support as 0x80200000 is an address where OpenSBI will load binary (in our case Xen). > > > > > > But honestly, I don't think the qemu details in the commit message > > are > > useful. This series is just about making "make build" work. > > > > The next series (being worked on, but not posted yet) is only a few > > patches and gets a full Gitlab CI smoke test, at which point the > > smoke > > test shell script is the reference for how to invoke qemu. > > > > > > I'm happy to R-by this series and drop that part of the commit > > message > > on commit. > > > I'm happy with that. Thanks. > > ~Andrew > ~ Oleksii
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |