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-changelog

[Xen-changelog] [IA64] cleanup of tlb.c

# HG changeset patch
# User awilliam@xxxxxxxxxxx
# Node ID 212eb6a2d8cd3c9bad9026b07f4ff6f387658164
# Parent  d18f8fd07fa2bd3856147b446b567064b130e742
[IA64] cleanup of tlb.c

#if 0 unused code for tlb management.

Signed-off-by: Tristan Gingold <tristan.gingold@xxxxxxxx>

diff -r d18f8fd07fa2 -r 212eb6a2d8cd xen/arch/ia64/linux-xen/setup.c
--- a/xen/arch/ia64/linux-xen/setup.c   Tue Mar 21 16:18:28 2006
+++ b/xen/arch/ia64/linux-xen/setup.c   Tue Mar 21 16:55:04 2006
@@ -765,8 +765,10 @@
 {
        extern void __devinit ia64_mmu_init (void *);
        unsigned long num_phys_stacked;
+#ifndef XEN
        pal_vm_info_2_u_t vmi;
        unsigned int max_ctx;
+#endif
        struct cpuinfo_ia64 *cpu_info;
        void *cpu_data;
 
@@ -874,6 +876,7 @@
        normal_xtp();
 #endif
 
+#ifndef XEN
        /* set ia64_ctx.max_rid to the maximum RID that is supported by all 
CPUs: */
        if (ia64_pal_vm_summary(NULL, &vmi) == 0)
                max_ctx = (1U << (vmi.pal_vm_info_2_s.rid_size - 3)) - 1;
@@ -886,6 +889,7 @@
                if (cmpxchg(&ia64_ctx.max_ctx, old, max_ctx) == old)
                        break;
        }
+#endif
 
        if (ia64_pal_rse_info(&num_phys_stacked, NULL) != 0) {
                printk(KERN_WARNING "cpu_init: PAL RSE info failed; assuming 96 
physical "
diff -r d18f8fd07fa2 -r 212eb6a2d8cd xen/arch/ia64/linux-xen/smp.c
--- a/xen/arch/ia64/linux-xen/smp.c     Tue Mar 21 16:18:28 2006
+++ b/xen/arch/ia64/linux-xen/smp.c     Tue Mar 21 16:55:04 2006
@@ -291,17 +291,13 @@
        on_each_cpu((void (*)(void *))local_flush_tlb_all, NULL, 1, 1);
 }
 
+#ifndef XEN
 void
 smp_flush_tlb_mm (struct mm_struct *mm)
 {
        preempt_disable();
        /* this happens for the common case of a single-threaded fork():  */
-#ifdef XEN
-       if (likely(mm == current->domain->arch.mm
-                  && atomic_read(&mm->mm_users) == 1))
-#else
        if (likely(mm == current->active_mm && atomic_read(&mm->mm_users) == 1))
-#endif
        {
                local_finish_flush_tlb_mm(mm);
                preempt_enable();
@@ -318,6 +314,7 @@
         */
        on_each_cpu((void (*)(void *))local_finish_flush_tlb_mm, mm, 1, 1);
 }
+#endif
 
 /*
  * Run a function on another CPU
diff -r d18f8fd07fa2 -r 212eb6a2d8cd xen/arch/ia64/linux-xen/tlb.c
--- a/xen/arch/ia64/linux-xen/tlb.c     Tue Mar 21 16:18:28 2006
+++ b/xen/arch/ia64/linux-xen/tlb.c     Tue Mar 21 16:55:04 2006
@@ -28,6 +28,7 @@
        unsigned long max_bits; /* log2() of largest supported purge page-size 
*/
 } purge;
 
+#ifndef XEN
 struct ia64_ctx ia64_ctx = {
        .lock =         SPIN_LOCK_UNLOCKED,
        .next =         1,
@@ -43,9 +44,6 @@
 void
 wrap_mmu_context (struct mm_struct *mm)
 {
-#ifdef XEN
-printf("wrap_mmu_context: called, not implemented\n");
-#else
        unsigned long tsk_context, max_ctx = ia64_ctx.max_ctx;
        struct task_struct *tsk;
        int i;
@@ -86,8 +84,8 @@
                put_cpu();
        }
        local_flush_tlb_all();
-#endif
 }
+#endif /* XEN */
 
 void
 ia64_global_tlb_purge (unsigned long start, unsigned long end, unsigned long 
nbits)
@@ -133,12 +131,10 @@
 }
 EXPORT_SYMBOL(local_flush_tlb_all);
 
+#ifndef XEN
 void
 flush_tlb_range (struct vm_area_struct *vma, unsigned long start, unsigned 
long end)
 {
-#ifdef XEN
-printf("flush_tlb_range: called, not implemented\n");
-#else
        struct mm_struct *mm = vma->vm_mm;
        unsigned long size = end - start;
        unsigned long nbits;
@@ -170,9 +166,9 @@
 # endif
 
        ia64_srlz_i();                  /* srlz.i implies srlz.d */
-#endif
 }
 EXPORT_SYMBOL(flush_tlb_range);
+#endif
 
 void __devinit
 ia64_tlb_init (void)
diff -r d18f8fd07fa2 -r 212eb6a2d8cd 
xen/include/asm-ia64/linux-xen/asm/tlbflush.h
--- a/xen/include/asm-ia64/linux-xen/asm/tlbflush.h     Tue Mar 21 16:18:28 2006
+++ b/xen/include/asm-ia64/linux-xen/asm/tlbflush.h     Tue Mar 21 16:55:04 2006
@@ -33,6 +33,7 @@
 # define flush_tlb_all()       local_flush_tlb_all()
 #endif
 
+#ifndef XEN
 static inline void
 local_finish_flush_tlb_mm (struct mm_struct *mm)
 {
@@ -109,6 +110,8 @@
 
 
 #define flush_tlb_kernel_range(start, end)     flush_tlb_all() /* XXX fix me */
+#endif /* XEN */
+
 #ifdef XEN
 extern void flush_tlb_mask(cpumask_t mask);
 #endif

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [IA64] cleanup of tlb.c, Xen patchbot -unstable <=