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

[Xen-ia64-devel] Reserved Register/Field fault not correct handled in Xen?


  • To: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
  • From: Dietmar Hahn <dietmar.hahn@xxxxxxxxxxxxxxxxxxx>
  • Date: Tue, 12 Dec 2006 12:04:03 +0100
  • Delivery-date: Tue, 12 Dec 2006 03:03:58 -0800
  • Domainkey-signature: s=s768; d=fujitsu-siemens.com; c=nofws; q=dns; b=0Q2FnOxPcXQCAaoTaqsfcrBASw7XMVWTrVM1d1XO3P+/CiZcbELcfmueOTOkAneVcz3Tu1c31E3kWydd4UPMc5Utqi9SIRW57EgEXcmEs3n7dInveE0lidt3IZT16K1o;
  • List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>

Hi,

I had a closer look to my problem described on
http://lists.xensource.com/archives/html/xen-ia64-devel/2006-12/msg00120.html.
Now I can reproduce the panic in Xen with a dom0-user program.
The instructions
movl r16=0xff;;
mov ar.rsc=r16
lead to a general exception with function code 0x30 (Reserved Register/Field 
fault).
The trap handler in ivt.S checks only function code <=0x20.
The other exceptions call dispatch_to_fault_handler() and further 
ia64_fault().
In ia64_fault() there is only a check on function code 0x80 (Illegal 
dependency fault). The function codes 0x30 (Reserved Register/Field fault) 
and 0x40 lead to the xen-panic!
It seems the code was copied from the linux ia64_fault() routine. But there is 
a call of die_if_kernel(...) and if not kernel a call of 
force_sig(SIGILL, ...) to kill the user process.
I believe the solution is here to use FAULT_OR_REFLECT(24) in the trap handler 
if the function code is > 0x20 and to extend the ia64_handle_reflection() 
with handling the vector=24.
With this 2 fixes the user program gets a SIGILL like on native linux.
and my mini-os traphandler gets called from the hypervisor, so I can handle 
the trap on my own.
Do I see something complete wrong or should I send a patch?
Thanks.

Dietmar.

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel


 


Rackspace

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