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

Re: Xen Booting Problem on ARM Machine



On Wed, 13 Oct 2021, Sai Kiran Kumar Reddy Y wrote:
> On Fri, Oct 1, 2021 at 8:17 AM Stefano Stabellini <sstabellini@xxxxxxxxxx> 
> wrote:
>       Yes there are other ways but without serial is going to be difficult
>       because you are not going to see anything until everything works.
> 
>       How do you boot Xen and Dom0 exactly from EDK2? Are you using GRUB or
>       loading Xen directly from the EDK2 prompt? Please provide as many
>       details as possible so that I might be able to spot any errors.
> 
> I am using GRUB to load Xen. In the GRUB menu, I see two options. 
> Option 1: Debian 11 with latest Linux Kernel
> Option 2: Debian 11(with Xen hypervisor) with latest Kernel
>  
>       Can you provide the Device Tree you are using? If you are not passing
>       any Device Tree  binary explicitely, then it might be passed
>       automatically from EDK2 to Linux/Xen. In that case, just boot from Linux
>       then do the following to retrieve the Device Tree:
> 
>       dtc -I fs -O dts /proc/device-tree > host.dts
> 
>       Then please attach host.dts to this email thread.
> 
> Yeah, you are right. It looks like LInux is booting from ACPI. In the 
> bootloader menu, "Automatic ACPI configuration" is disabled. So, I
> thought that Linux may be booting from Device Tree. I have tried the "dtc" 
> command you mentioned. But it looks like there's no device-tree
> under "/proc". I also tried to get DT info, from 
> "/sys/firmware/devicetree/base" . But, there's no info. under devicetree 
> folder. I am not
> quite sure how to get the DT info, if the Linux is booting from ACPI. I am 
> attaching .dsl files, that contain the acpi info.

OK, so it is pretty clear that even if "Automatic ACPI configuration" is
disabled, it is still booting with ACPI.


>       Also for your information it looks like Linux actually booted from ACPI,
>       not from Device Tree, as you can see from all the "ACPI" messages in the
>       kernel logs.
> 
>       If you need to boot from ACPI, then you need to enable ACPI support in
>       Xen, which is disabled by default. You can do that using make
>       menuconfig.
> 
> In the make menuconfig of Xen, I do not see any option to enable ACPI.  

You definitely need to enable ACPI support in Xen, if you are booting
from ACPI, otherwise nothing is going to work.

On the latest staging (https://gitlab.com/xen-project/xen) you can
enable ACPI as follows:


# export CROSS_COMPILE=/path/to/cross-compiler
# export XEN_TARGET_ARCH=arm64
# cd xen.git/xen
# make menuconfig
#   --> Configure UNSUPPORTED features
#   --> Architecture Features --> ACPI
# make


Cheers,

Stefano


>       On Thu, 30 Sep 2021, Sai Kiran Kumar Reddy Y wrote:
>       > Hi,
>       > Sorry about the delay. We have been trying to access the serial of 
> the machine. Tried with couple of JTAG connectors. There's
>       still no
>       > debug messages on the serial. Is there any other way of figuring this 
> out?
>       >
>       > On Wed, Sep 15, 2021, 7:02 AM Stefano Stabellini 
> <sstabellini@xxxxxxxxxx> wrote:
>       >       Something is off. When you enabled earlyprintk in Xen, you 
> should see
>       >       something like this at boot time:
>       >       https://marc.info/?l=xen-devel&m=158829968025334
>       >
>       >       All the Xen logs starting with "(XEN)" on the serial. Do you 
> have access
>       >       to the serial of the machine? Without it, it is going to be 
> hard to
>       >       debug.
>       >
>       >
>       >       On Tue, 14 Sep 2021, Sai Kiran Kumar Reddy Y wrote:
>       >       > In the folder "/var/log", there's a file called "xen", which 
> is empty. As far as the boot logs are concerned, I don't
>       see any
>       >       debug
>       >       > messages related to xen. I am attaching the log files, 
> "kern.txt" and "boot.txt"
>       >       >
>       >       > On Tue, Sep 14, 2021 at 3:08 AM Stefano Stabellini 
> <sstabellini@xxxxxxxxxx> wrote:
>       >       >       On Mon, 13 Sep 2021, Sai Kiran Kumar Reddy Y wrote:
>       >       >       > On Fri, Sep 10, 2021 at 7:30 PM Julien Grall 
> <julien@xxxxxxx> wrote:
>       >       >       >
>       >       >       >
>       >       >       >       On 08/09/2021 11:43, Sai Kiran wrote:
>       >       >       >       > Hello,
>       >       >       >
>       >       >       >       Hi,
>       >       >       >
>       >       >       >       Thank you for the report. Moving the discussion 
> back to xen-devel
>       >       >       >       because this looks like a potential issue in 
> the UEFI stub in Xen.
>       >       >       >
>       >       >       >       > I have Xen-4.15.0 on an ARM Machine, with 
> Debian 11 installed on it.
>       >       >       >
>       >       >       >       Would you be able to give more details on the 
> Arm machine you are using?
>       >       >       >       Also, are you using ACPI or DT to boot?
>       >       >       >
>       >       >       >
>       >       >       >    Sai >> DT . ACPI configuration is disabled in Boot 
> settings    
>       >       >       >
>       >       >       >       >  I
>       >       >       >       > am able to do “make world” and “make 
> install”, after “./configure”, as
>       >       >       >       > specified in README file. When I reboot the 
> system, I get the following
>       >       >       >       > message:
>       >       >       >       >
>       >       >       >       > Warning: All 128 bootinfo mem banks exhausted.
>       >       >       >       >
>       >       >       >       > Warning: All 128 bootinfo mem banks exhausted.
>       >       >       >
>       >       >       >       Hmmm... This means that you have more than 128 
> memory regions described
>       >       >       >       in the EFI memory map. That's quite a lot.
>       >       >       >
>       >       >       >       Although, this should be harmless as it means 
> Xen will not use the extra
>       >       >       >       memory banks.
>       >       >       >
>       >       >       >       >
>       >       >       >       > Cannot exit boot services: ErrCode: 
> 0x8000000000000002
>       >       >       >
>       >       >       >       This means EFI_INVALID_PARAMETER. We have code 
> to retry because AFAICT
>       >       >       >       ExitBootServices() may sometime fails (I have 
> CCed Jan may have more
>       >       >       >       idea what's happening).
>       >       >       >
>       >       >       >       Would you be able to provide more details on 
> the UEFI firmware you are
>       >       >       >       using? Is it EDK2 or U-boot?
>       >       >       >
>       >       >       > Sai >>  EDK2 
>       >       >       >       Also, do you know if Linux is boot on the same 
> system?
>       >       >       >
>       >       >       > Sai >> Yes 
>       >       >       >       However, AFAICT, the error message would not 
> prevent Xen to continue
>       >       >       >       booting. So you may get stuck later in the boot 
> process.
>       >       >       >
>       >       >       >       My suggestion would be to enable earlyprintk 
> for your platform. You can
>       >       >       >       setup it up from the menuconfig in "Debugging 
> Options".
>       >       >       >
>       >       >       > Sai >> Yes, I have enabled earlyprintk.
>       >       >       > I tried changing NR_MEM_BANKS(in 
> xen/include/asm-arm/setup.h) value to 256, from 128. The error message is no
>       longer
>       >       seen,
>       >       >       but the device
>       >       >       > is stuck in the boot process.
>       >       >
>       >       >       Could you please post the boot logs now that you 
> enabled earlyprintk?
>       >       >       Ideally not a camera picture but a textual copy/paste 
> from the target
>       >       >       serial?
>       >       >
>       >       >       Earlyprintk is pretty verbose, we should be able to 
> figure out where it
>       >       >       gets stuck.
>       >       >
>       >       >
>       >       >
>       >
>       >
>       >
> 
> 
> 

 


Rackspace

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