|  |  | 
  
    |  |  | 
 
  |   |  | 
  
    |  |  | 
  
    |  |  | 
  
    |   xen-changelog
[Xen-changelog] [xen-unstable] x86 vpt: Small performance fixes. 
| # HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1251967846 -3600
# Node ID 372feb56b6daea5163edb9bda63627d6841dde81
# Parent  b951df6d6c8f9755c61a34cdebeca0c961e3cb71
x86 vpt: Small performance fixes.
1. once one-shot timer is fired, IRQ is raised repeatedly forever.
2. Test pending_intr_nr before pt_irq_masked(), as it is cheaper.
Signed-off-by: Kouya Shimura <kouya@xxxxxxxxxxxxxx>
---
 xen/arch/x86/hvm/vpt.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletion(-)
diff -r b951df6d6c8f -r 372feb56b6da xen/arch/x86/hvm/vpt.c
--- a/xen/arch/x86/hvm/vpt.c    Thu Sep 03 09:49:41 2009 +0100
+++ b/xen/arch/x86/hvm/vpt.c    Thu Sep 03 09:50:46 2009 +0100
@@ -229,7 +229,7 @@ void pt_update_irq(struct vcpu *v)
 
     list_for_each_entry ( pt, head, list )
     {
-        if ( !pt_irq_masked(pt) && pt->pending_intr_nr &&
+        if ( pt->pending_intr_nr && !pt_irq_masked(pt) &&
              ((pt->last_plt_gtime + pt->period) < max_lag) )
         {
             max_lag = pt->last_plt_gtime + pt->period;
@@ -298,6 +298,7 @@ void pt_intr_post(struct vcpu *v, struct
         if ( pt->on_list )
             list_del(&pt->list);
         pt->on_list = 0;
+        pt->pending_intr_nr = 0;
     }
     else
     {
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
 | 
 
| <Prev in Thread] | Current Thread | [Next in Thread> |  | 
[Xen-changelog] [xen-unstable] x86 vpt: Small performance fixes.,
Xen patchbot-unstable <=
 |  |  | 
  
    |  |  |