ia64/xen-unstable

changeset 4094:1b23a3ae5792

bitkeeper revision 1.1159.258.48 (4230f9e1A3LEMmDHzcYXsKwP-EpzRg)

Fix fallout from Update to Linux 2.6.11.
Signed-off-by: Christian Limpach <chris@xensource.com>
author cl349@firebug.cl.cam.ac.uk
date Fri Mar 11 01:52:33 2005 +0000 (2005-03-11)
parents 41a2aa8951bc
children c7837f5059f1 fcd17066e110 db5a30a327e6
files linux-2.4.29-xen-sparse/include/asm-xen/pgtable-2level.h linux-2.6.11-xen-sparse/arch/xen/i386/kernel/pci-dma.c linux-2.6.11-xen-sparse/arch/xen/i386/mm/hypervisor.c linux-2.6.11-xen-sparse/drivers/xen/balloon/balloon.c linux-2.6.11-xen-sparse/include/asm-xen/hypervisor.h
line diff
     1.1 --- a/linux-2.4.29-xen-sparse/include/asm-xen/pgtable-2level.h	Fri Mar 11 01:23:38 2005 +0000
     1.2 +++ b/linux-2.4.29-xen-sparse/include/asm-xen/pgtable-2level.h	Fri Mar 11 01:52:33 2005 +0000
     1.3 @@ -36,7 +36,7 @@ static inline int pgd_present(pgd_t pgd)
     1.4  
     1.5  #define set_pte(pteptr, pteval) queue_l1_entry_update(pteptr, (pteval).pte_low)
     1.6  #define set_pte_atomic(pteptr, pteval) queue_l1_entry_update(pteptr, (pteval).pte_low)
     1.7 -#define set_pmd(pmdptr, pmdval) queue_l2_entry_update((pmdptr), (pmdval).pmd)
     1.8 +#define set_pmd(pmdptr, pmdval) queue_l2_entry_update((pmdptr), (pmdval))
     1.9  #define set_pgd(pgdptr, pgdval) ((void)0)
    1.10  
    1.11  #define pgd_page(pgd) \
     2.1 --- a/linux-2.6.11-xen-sparse/arch/xen/i386/kernel/pci-dma.c	Fri Mar 11 01:23:38 2005 +0000
     2.2 +++ b/linux-2.6.11-xen-sparse/arch/xen/i386/kernel/pci-dma.c	Fri Mar 11 01:52:33 2005 +0000
     2.3 @@ -17,6 +17,8 @@
     2.4  
     2.5  #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0)
     2.6  #define pte_offset_kernel pte_offset
     2.7 +#define pud_t pgd_t
     2.8 +#define pud_offset(d, va) d
     2.9  #endif
    2.10  
    2.11  struct dma_coherent_mem {
     3.1 --- a/linux-2.6.11-xen-sparse/arch/xen/i386/mm/hypervisor.c	Fri Mar 11 01:23:38 2005 +0000
     3.2 +++ b/linux-2.6.11-xen-sparse/arch/xen/i386/mm/hypervisor.c	Fri Mar 11 01:52:33 2005 +0000
     3.3 @@ -49,8 +49,12 @@ static spinlock_t update_lock = SPIN_LOC
     3.4  #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0)
     3.5  #define QUEUE_SIZE 2048
     3.6  #define pte_offset_kernel pte_offset
     3.7 +#define pmd_val_ma(v) (v).pmd;
     3.8 +#define pud_t pgd_t
     3.9 +#define pud_offset(d, va) d
    3.10  #else
    3.11  #define QUEUE_SIZE 128
    3.12 +#define pmd_val_ma(v) (v).pud.pgd.pgd;
    3.13  #endif
    3.14  
    3.15  static mmu_update_t update_queue[QUEUE_SIZE];
    3.16 @@ -125,7 +129,7 @@ void queue_l2_entry_update(pmd_t *ptr, p
    3.17      unsigned long flags;
    3.18      spin_lock_irqsave(&update_lock, flags);
    3.19      update_queue[idx].ptr = virt_to_machine(ptr);
    3.20 -    update_queue[idx].val = val.pud.pgd.pgd; /* XXX pmd_val_ma */
    3.21 +    update_queue[idx].val = pmd_val_ma(val);
    3.22      increment_index();
    3.23      spin_unlock_irqrestore(&update_lock, flags);
    3.24  }
    3.25 @@ -242,7 +246,7 @@ void xen_l2_entry_update(pmd_t *ptr, pmd
    3.26      unsigned long flags;
    3.27      spin_lock_irqsave(&update_lock, flags);
    3.28      update_queue[idx].ptr = virt_to_machine(ptr);
    3.29 -    update_queue[idx].val = val.pud.pgd.pgd; /* XXX pmd_val_ma */
    3.30 +    update_queue[idx].val = pmd_val_ma(val);
    3.31      increment_index_and_flush();
    3.32      spin_unlock_irqrestore(&update_lock, flags);
    3.33  }
     4.1 --- a/linux-2.6.11-xen-sparse/drivers/xen/balloon/balloon.c	Fri Mar 11 01:23:38 2005 +0000
     4.2 +++ b/linux-2.6.11-xen-sparse/drivers/xen/balloon/balloon.c	Fri Mar 11 01:52:33 2005 +0000
     4.3 @@ -91,6 +91,10 @@ static struct timer_list balloon_timer;
     4.4  #define LIST_TO_PAGE(l) ( list_entry(l, struct page, list) )
     4.5  #define UNLIST_PAGE(p)  ( list_del(&p->list) )
     4.6  #define pte_offset_kernel pte_offset
     4.7 +#define pud_t pgd_t
     4.8 +#define pud_offset(d, va) d
     4.9 +#define pud_none(d) 0
    4.10 +#define pud_bad(d) 0
    4.11  #define subsys_initcall(_fn) __initcall(_fn)
    4.12  #define pfn_to_page(_pfn) (mem_map + (_pfn))
    4.13  #endif
     5.1 --- a/linux-2.6.11-xen-sparse/include/asm-xen/hypervisor.h	Fri Mar 11 01:23:38 2005 +0000
     5.2 +++ b/linux-2.6.11-xen-sparse/include/asm-xen/hypervisor.h	Fri Mar 11 01:52:33 2005 +0000
     5.3 @@ -30,6 +30,7 @@
     5.4  #ifndef __HYPERVISOR_H__
     5.5  #define __HYPERVISOR_H__
     5.6  
     5.7 +#include <linux/config.h>
     5.8  #include <linux/types.h>
     5.9  #include <linux/kernel.h>
    5.10  #include <linux/version.h>
    5.11 @@ -38,7 +39,9 @@
    5.12  #include <asm-xen/xen-public/io/domain_controller.h>
    5.13  #include <asm/ptrace.h>
    5.14  #include <asm/page.h>
    5.15 +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)
    5.16  #include <asm-generic/pgtable-nopmd.h>
    5.17 +#endif
    5.18  
    5.19  /* arch/xen/i386/kernel/setup.c */
    5.20  union xen_start_info_union