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

[Xen-devel] [PATCH][5/5] x86-64-irq-cpustat.patch



   Use fixed size data types in irq_cpustat and check it properly for 
   softirqs before vmresume.
   
   Signed-off-by: Arun Sharma <arun.sharma@xxxxxxxxx>
diff -Nru a/xen/arch/x86/x86_64/entry.S b/xen/arch/x86/x86_64/entry.S
--- a/xen/arch/x86/x86_64/entry.S       2005-04-18 16:49:38 -07:00
+++ b/xen/arch/x86/x86_64/entry.S       2005-04-18 16:49:38 -07:00
@@ -242,10 +242,10 @@
         cli                             # tests must not race interrupts
 /*test_softirqs:*/  
         movq EDOMAIN_processor(%rbx),%rax
-#if 0
         shl  $6,%rax                    # sizeof(irq_cpustat) == 64
-        test %rcx,SYMBOL_NAME(irq_stat)(%rax,1)
-#endif
+        leaq SYMBOL_NAME(irq_stat)(%rip), %rdx
+        addq %rdx,%rax
+        testl %ecx,(%rax)
         jnz  vmx_process_softirqs
 
 vmx_restore_all_guest:
diff -Nru a/xen/include/asm-x86/hardirq.h b/xen/include/asm-x86/hardirq.h
--- a/xen/include/asm-x86/hardirq.h     2005-04-18 16:49:38 -07:00
+++ b/xen/include/asm-x86/hardirq.h     2005-04-18 16:49:38 -07:00
@@ -5,10 +5,10 @@
 #include <xen/cache.h>
 
 typedef struct {
-       unsigned int __softirq_pending;
-       unsigned int __local_irq_count;
-       unsigned int __nmi_count;
-       unsigned long idle_timestamp;
+       u32     __softirq_pending;
+       u32     __local_irq_count;
+       u32     __nmi_count;
+       u64     idle_timestamp;
 } __cacheline_aligned irq_cpustat_t;
 
 #include <xen/irq_cpustat.h>   /* Standard mappings for irq_cpustat_t above */

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


 


Rackspace

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