Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 07 Apr 2015 14:00:57 +0200
From:      =?UTF-8?B?Um9nZXIgUGF1IE1vbm7DqQ==?= <royger@FreeBSD.org>
To:        =?UTF-8?B?R3VzdGF1IFDDqXJleg==?= <gperez@entel.upc.edu>
Cc:        freebsd-xen@FreeBSD.org
Subject:   Re: Unable to boot with the dom0 xen kernel
Message-ID:  <5523C6F9.4000608@FreeBSD.org>
In-Reply-To: <5523BB57.1010607@entel.upc.edu>
References:  <551EFA82.9070007@entel.upc.edu> <CAPLaKK79kV6eqqOjuQUevJFnqHmFVrjQVVULcmR7Wg%2BY-=5Rbg@mail.gmail.com> <55223D08.4040007@entel.upc.edu> <5523872E.5030700@FreeBSD.org> <5523945E.2050405@entel.upc.edu> <5523A989.4010608@FreeBSD.org> <5523BB57.1010607@entel.upc.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
Hello,

El 07/04/15 a les 13.11, Gustau PĂ©rez ha escrit:
> 
>    Hi Roger,
>>>> If you don't have a serial console you
>>>> should use console=vga in your xen_cmdline. Additionally if you have a
>>>> usb debug port you could use that as console with console=dbgp [1].
>>>    Thank you. I did not have a console at $home (the laptop has no
>>> physical serial port) but at $work my laptop dockstation provides me
>>> with a physical serial port. I'll try to use it.
> 
>    Well, my current laptop (Dell latitude E6430) and the previous one
> (Fujitsu Lifebook) have that. I'd say that even an old D630 laptop had
> that option. It is quite useful.
>> I didn't know there were dock stations that provided serial ports even
>> when the laptop didn't have them, that's something worth a try. If not
>> just setting console=vga ought to provide some output. If that also
>> fails please write back and I will provide a patch for the bootloader in
>> order to try to figure out what's going on.
>>
>> Roger.
> 
>    I added a new test machine. I'll show my results with this one (I'll
> report my laptop results later).
> 
>    The new machine is
> 
>             Intel(R) Xeon(R) CPU           L5520  @ 2.27GHz
> 
>    EPT and IOMMU are there:
> 
>        [root@hast16 ~/xen]# dmesg|grep EPT
>         VT-x: PAT,HLT,MTF,PAUSE,EPT,VPID
>       [root@hast16 ~/xen]# acpidump -t | grep DMAR
>        DMAR: Length=432, Revision=1, Checksum=213,
> 
>    First I tried xen and xen-tools from ports (version 4.5, hoping those
> were enought). The boot failed, he error says iommu is not enabled. The
> complete log is here:
> 
>         http://dpaste.com/0KCGGW7

Yup, there's an errata with that specific chipset :(.

> 
>    so I switched to git version instead. The error was the same. I
> suspect this is the reason:
> 
>         (XEN) [VT-D]Disabling IOMMU due to Intel 5500/5520/X58 Chipset
> errata #47, #53
> 
>    According to the article [1] it is possible to prevent interruption
> remapping. I added iommu=no-intremap (it is listed in [2]), it appears
> the xen kernel is happy with that, but then the domain0 FreeBSD kernel
> panics:
> 
>         http://dpaste.com/3TJYYDQ

Could you add iommu=no-intremap,debug? That will make the IOMMU code a 
little bit more verbose. Also the full boot log and a backtrace of 
FreeBSD might be helpful.

I think I have an idea of what might cause this GP, can you apply the 
following patch to the Xen source tree and recompile the Xen kernel, 
(there's no need to recompile the tools):

diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c
index e1c55ce..fc3c45b 100644
--- a/xen/arch/x86/hvm/vmx/vmx.c
+++ b/xen/arch/x86/hvm/vmx/vmx.c
@@ -3102,8 +3102,7 @@ void vmx_vmexit_handler(struct cpu_user_regs *regs)
         if ( exit_qualification & 0x10 )
         {
             /* INS, OUTS */
-            if ( unlikely(is_pvh_vcpu(v)) /* PVH fixme */ ||
-                 !handle_mmio() )
+            if ( !handle_mmio() )
                 hvm_inject_hw_exception(TRAP_gp_fault, 0);
         }
         else


> 
>    Gustau
> 
>    [1] http://support.citrix.com/article/CTX136517
>    [2]
> http://xenbits.xenproject.org/docs/unstable/misc/xen-command-line.html
> 
>    PS: I'd like to talk about the behavior of the xen_cmdline reboot
> option. Setting it "no" causes the machine to stop (which is fine) but
> the machine remains there. Perhaps it'd be good to allow to reboot the
> machine by pressing a key when in panic. Otherwise you have physically
> reboot the machine.

Yes, this is possible from the serial console. Press Ctrl-A tree times 
(to switch to the Xen console), and then 'R' (note the caps).

Roger.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5523C6F9.4000608>