Hello Julien and everyone.
It seems to me that using u-boot as a bootloader makes things more
complicated,so leave it out of the equation for the moment. So,I want
to take a step back,trying to boot FreeBSD using its kernel (that I
have patched with your old patch,so that it can boot as an zImage
file,without using u-boot). So,this is what I did :
on FreeBSD 13.2 :
$ cd /usr
$ git clone https://gitlab.com/ehem/freebsd-src.git
$ cd freebsd-src/sys/arm/arm/
$ nano locore-v6.S
$ applied this patch to the Elliott Mitchell's code :
https://xenbits.xen.org/gitweb/?p=people/julieng/freebsd.git;a=commit;h=12a7cb346b88c6d3f52a20b98f361dc62797fbcd
(as suggested by Chuck,because he says that xen supports only the
zImage files,not elf's ones)
Elliott Mitchell's original code of the file locore-v6.S (called by
file /usr/freebsd-src/sys/arm/arm/locore.S) :
.globl btext
btext:
ASENTRY_NP(_start)
STOP_UNWINDING
cpsid ifa
mov r8, r0
mov r9, r1
mov r10, r2
mov r11, r3
changed with the Julien Grall code :
.globl btext
btext:
ASENTRY_NP(_start)
STOP_UNWINDING
cpsid ifa
mov r9, r0
mov r8, r1
mov ip, r2
$ cd /usr/freebsd-src
$ make KERNCONF=GENERIC TARGET=arm TARGET_ARCH=armv7 buildkernel
$ make KERNCONF=GENERIC TARGET=arm TARGET_ARCH=armv7
DESTDIR=/build-xen installkernel
Anymore,from the compilation of the Elliott's code has generated the
kernel file,but not the kernel.bin file,that's what I need.
I want to ask if someone wants to give a look at the old Julien Grall
patch, because it is based on the idea of trying to have support for
Xen interrupt handling on both x86 and arm in a generic way that does
not depend on x86 specific code. Unfortunately, it is clear that
Julien's approach to make the Xen interrupt handlers independent of
x86 code has not been implemented in FreeBSD. It is probably necessary
to try something different for the Xen interrupt handlers on arm in
place of what Julien tried nine years ago.
In addition the compilation of the Elliotts code does not produce any
kernel.bin file.
Julien said that I could try to revert the commiting removing the step
to create kernel.bin,but I don't know what it means,I don't know how
to do that and I haven't found anyone who wants to explain to me how
to do it. And I'm not sure that it will be enough.
Thanks.
--
Mario.
It seems to me that using u-boot as a bootloader makes things more
complicated,so leave it out of the equation for the moment. So,I want
to take a step back,trying to boot FreeBSD using its kernel (that I
have patched with your old patch,so that it can boot as an zImage
file,without using u-boot). So,this is what I did :
on FreeBSD 13.2 :
$ cd /usr
$ git clone https://gitlab.com/ehem/freebsd-src.git
$ cd freebsd-src/sys/arm/arm/
$ nano locore-v6.S
$ applied this patch to the Elliott Mitchell's code :
https://xenbits.xen.org/gitweb/?p=people/julieng/freebsd.git;a=commit;h=12a7cb346b88c6d3f52a20b98f361dc62797fbcd
(as suggested by Chuck,because he says that xen supports only the
zImage files,not elf's ones)
Elliott Mitchell's original code of the file locore-v6.S (called by
file /usr/freebsd-src/sys/arm/arm/locore.S) :
.globl btext
btext:
ASENTRY_NP(_start)
STOP_UNWINDING
cpsid ifa
mov r8, r0
mov r9, r1
mov r10, r2
mov r11, r3
changed with the Julien Grall code :
.globl btext
btext:
ASENTRY_NP(_start)
STOP_UNWINDING
cpsid ifa
mov r9, r0
mov r8, r1
mov ip, r2
$ cd /usr/freebsd-src
$ make KERNCONF=GENERIC TARGET=arm TARGET_ARCH=armv7 buildkernel
$ make KERNCONF=GENERIC TARGET=arm TARGET_ARCH=armv7
DESTDIR=/build-xen installkernel
Anymore,from the compilation of the Elliott's code has generated the
kernel file,but not the kernel.bin file,that's what I need.
I want to ask if someone wants to give a look at the old Julien Grall
patch, because it is based on the idea of trying to have support for
Xen interrupt handling on both x86 and arm in a generic way that does
not depend on x86 specific code. Unfortunately, it is clear that
Julien's approach to make the Xen interrupt handlers independent of
x86 code has not been implemented in FreeBSD. It is probably necessary
to try something different for the Xen interrupt handlers on arm in
place of what Julien tried nine years ago.
In addition the compilation of the Elliotts code does not produce any
kernel.bin file.
Julien said that I could try to revert the commiting removing the step
to create kernel.bin,but I don't know what it means,I don't know how
to do that and I haven't found anyone who wants to explain to me how
to do it. And I'm not sure that it will be enough.
Thanks.
--
Mario.