WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

RE: [Xen-ia64-devel] PATCH [resend]: more case handled in mmio.c

To: "Tristan Gingold" <Tristan.Gingold@xxxxxxxx>, <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>, "Alex Williamson" <alex.williamson@xxxxxx>
Subject: RE: [Xen-ia64-devel] PATCH [resend]: more case handled in mmio.c
From: "Xu, Anthony" <anthony.xu@xxxxxxxxx>
Date: Thu, 20 Apr 2006 12:28:49 +0800
Delivery-date: Wed, 19 Apr 2006 21:30:37 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcZiw8MS4aO5NZ0rT4qlva3CEl2eAQBa9ENw
Thread-topic: [Xen-ia64-devel] PATCH [resend]: more case handled in mmio.c
>From: Tristan Gingold 
>Sent: 2006?4?18? 16:44
>Correct, but this doesn't happen in the mmio case, because fp_reg_disabled is
>tested before doing the memory access.

I didn't find where fp_reg_disabled is tested:-)

If we only emulate stf.spill and stf8, yes fp fault doesn't happen.
But if we need to emulate ldf, definitely fp fault will happen,
The sequence of emulating ldf maybe,
Mmio_access( , , , , ,IOREQ_READ)
Vcpu_set_fpreg( )
Mmio_access will cause domain_switch,
When switch back, psr.dfh is set,
Then when executing vcpu_set_fpreg, fp fault happens.

And I had found Xwindow use ldfp8 instruction to access frame buffer.
BTW, Where did you find stf.spill and stf8 are used to access mmio?

Can we address this issue like below?
#ifdef  XEN
#define ia64_fph_enable()       
#define ia64_fph_disable()      
#else
#define ia64_fph_enable()       do { ia64_rsm(IA64_PSR_DFH); ia64_srlz_d(); } 
while (0)
#define ia64_fph_disable()      do { ia64_ssm(IA64_PSR_DFH); ia64_srlz_d(); } 
while (0)
#endif //XEN

This makes sure there is no fp fault happening within xen.
Yes later on if we want to use lazy fp algorithm within xen,
we should revisit this.

Thanks,
Anthony

>Tristan.

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