ia64/xen-unstable

changeset 12663:4fae646d60da

[IA64] move pgtable-nopud.h to modify from linux/ to linux-xen/.

Prep for p2m traversal race fix.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
author awilliam@xenbuild.aw
date Thu Nov 30 15:57:37 2006 -0700 (2006-11-30)
parents 251630d85510
children 439051df45f3
files xen/include/asm-ia64/linux-xen/asm-generic/README.origin xen/include/asm-ia64/linux-xen/asm-generic/pgtable-nopud.h xen/include/asm-ia64/linux/asm-generic/README.origin xen/include/asm-ia64/linux/asm-generic/pgtable-nopud.h
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/xen/include/asm-ia64/linux-xen/asm-generic/README.origin	Thu Nov 30 15:57:37 2006 -0700
     1.3 @@ -0,0 +1,8 @@
     1.4 +# Source files in this directory are near-identical copies of linux-2.6.13
     1.5 +# files:
     1.6 +
     1.7 +# NOTE: ALL changes to these files should be clearly marked
     1.8 +# (e.g. with #ifdef XEN or XEN in a comment) so that they can be
     1.9 +# easily updated to future versions of the corresponding Linux files.
    1.10 +
    1.11 +pgtable-nopud.h		-> linux/include/asm-generic/pgtable-nopud.h
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/xen/include/asm-ia64/linux-xen/asm-generic/pgtable-nopud.h	Thu Nov 30 15:57:37 2006 -0700
     2.3 @@ -0,0 +1,61 @@
     2.4 +#ifndef _PGTABLE_NOPUD_H
     2.5 +#define _PGTABLE_NOPUD_H
     2.6 +
     2.7 +#ifndef __ASSEMBLY__
     2.8 +
     2.9 +#define __PAGETABLE_PUD_FOLDED
    2.10 +
    2.11 +/*
    2.12 + * Having the pud type consist of a pgd gets the size right, and allows
    2.13 + * us to conceptually access the pgd entry that this pud is folded into
    2.14 + * without casting.
    2.15 + */
    2.16 +typedef struct { pgd_t pgd; } pud_t;
    2.17 +
    2.18 +#define PUD_SHIFT	PGDIR_SHIFT
    2.19 +#define PTRS_PER_PUD	1
    2.20 +#define PUD_SIZE  	(1UL << PUD_SHIFT)
    2.21 +#define PUD_MASK  	(~(PUD_SIZE-1))
    2.22 +
    2.23 +/*
    2.24 + * The "pgd_xxx()" functions here are trivial for a folded two-level
    2.25 + * setup: the pud is never bad, and a pud always exists (as it's folded
    2.26 + * into the pgd entry)
    2.27 + */
    2.28 +static inline int pgd_none(pgd_t pgd)		{ return 0; }
    2.29 +static inline int pgd_bad(pgd_t pgd)		{ return 0; }
    2.30 +static inline int pgd_present(pgd_t pgd)	{ return 1; }
    2.31 +static inline void pgd_clear(pgd_t *pgd)	{ }
    2.32 +#define pud_ERROR(pud)				(pgd_ERROR((pud).pgd))
    2.33 +
    2.34 +#define pgd_populate(mm, pgd, pud)		do { } while (0)
    2.35 +/*
    2.36 + * (puds are folded into pgds so this doesn't get actually called,
    2.37 + * but the define is needed for a generic inline function.)
    2.38 + */
    2.39 +#define set_pgd(pgdptr, pgdval)			set_pud((pud_t *)(pgdptr), (pud_t) { pgdval })
    2.40 +
    2.41 +static inline pud_t * pud_offset(pgd_t * pgd, unsigned long address)
    2.42 +{
    2.43 +	return (pud_t *)pgd;
    2.44 +}
    2.45 +
    2.46 +#define pud_val(x)				(pgd_val((x).pgd))
    2.47 +#define __pud(x)				((pud_t) { __pgd(x) } )
    2.48 +
    2.49 +#define pgd_page(pgd)				(pud_page((pud_t){ pgd }))
    2.50 +#define pgd_page_kernel(pgd)			(pud_page_kernel((pud_t){ pgd }))
    2.51 +
    2.52 +/*
    2.53 + * allocating and freeing a pud is trivial: the 1-entry pud is
    2.54 + * inside the pgd, so has no extra memory associated with it.
    2.55 + */
    2.56 +#define pud_alloc_one(mm, address)		NULL
    2.57 +#define pud_free(x)				do { } while (0)
    2.58 +#define __pud_free_tlb(tlb, x)			do { } while (0)
    2.59 +
    2.60 +#undef  pud_addr_end
    2.61 +#define pud_addr_end(addr, end)			(end)
    2.62 +
    2.63 +#endif /* __ASSEMBLY__ */
    2.64 +#endif /* _PGTABLE_NOPUD_H */
     3.1 --- a/xen/include/asm-ia64/linux/asm-generic/README.origin	Thu Nov 30 15:57:20 2006 -0700
     3.2 +++ b/xen/include/asm-ia64/linux/asm-generic/README.origin	Thu Nov 30 15:57:37 2006 -0700
     3.3 @@ -9,7 +9,6 @@ ide_iops.h		-> linux/include/asm-generic
     3.4  iomap.h			-> linux/include/asm-generic/iomap.h
     3.5  pci.h			-> linux/include/asm-generic/pci.h
     3.6  pgtable.h		-> linux/include/asm-generic/pgtable.h
     3.7 -pgtable-nopud.h		-> linux/include/asm-generic/pgtable-nopud.h
     3.8  sections.h		-> linux/include/asm-generic/sections.h
     3.9  topology.h		-> linux/include/asm-generic/topology.h
    3.10  unaligned.h		-> linux/include/asm-generic/unaligned.h
     4.1 --- a/xen/include/asm-ia64/linux/asm-generic/pgtable-nopud.h	Thu Nov 30 15:57:20 2006 -0700
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,61 +0,0 @@
     4.4 -#ifndef _PGTABLE_NOPUD_H
     4.5 -#define _PGTABLE_NOPUD_H
     4.6 -
     4.7 -#ifndef __ASSEMBLY__
     4.8 -
     4.9 -#define __PAGETABLE_PUD_FOLDED
    4.10 -
    4.11 -/*
    4.12 - * Having the pud type consist of a pgd gets the size right, and allows
    4.13 - * us to conceptually access the pgd entry that this pud is folded into
    4.14 - * without casting.
    4.15 - */
    4.16 -typedef struct { pgd_t pgd; } pud_t;
    4.17 -
    4.18 -#define PUD_SHIFT	PGDIR_SHIFT
    4.19 -#define PTRS_PER_PUD	1
    4.20 -#define PUD_SIZE  	(1UL << PUD_SHIFT)
    4.21 -#define PUD_MASK  	(~(PUD_SIZE-1))
    4.22 -
    4.23 -/*
    4.24 - * The "pgd_xxx()" functions here are trivial for a folded two-level
    4.25 - * setup: the pud is never bad, and a pud always exists (as it's folded
    4.26 - * into the pgd entry)
    4.27 - */
    4.28 -static inline int pgd_none(pgd_t pgd)		{ return 0; }
    4.29 -static inline int pgd_bad(pgd_t pgd)		{ return 0; }
    4.30 -static inline int pgd_present(pgd_t pgd)	{ return 1; }
    4.31 -static inline void pgd_clear(pgd_t *pgd)	{ }
    4.32 -#define pud_ERROR(pud)				(pgd_ERROR((pud).pgd))
    4.33 -
    4.34 -#define pgd_populate(mm, pgd, pud)		do { } while (0)
    4.35 -/*
    4.36 - * (puds are folded into pgds so this doesn't get actually called,
    4.37 - * but the define is needed for a generic inline function.)
    4.38 - */
    4.39 -#define set_pgd(pgdptr, pgdval)			set_pud((pud_t *)(pgdptr), (pud_t) { pgdval })
    4.40 -
    4.41 -static inline pud_t * pud_offset(pgd_t * pgd, unsigned long address)
    4.42 -{
    4.43 -	return (pud_t *)pgd;
    4.44 -}
    4.45 -
    4.46 -#define pud_val(x)				(pgd_val((x).pgd))
    4.47 -#define __pud(x)				((pud_t) { __pgd(x) } )
    4.48 -
    4.49 -#define pgd_page(pgd)				(pud_page((pud_t){ pgd }))
    4.50 -#define pgd_page_kernel(pgd)			(pud_page_kernel((pud_t){ pgd }))
    4.51 -
    4.52 -/*
    4.53 - * allocating and freeing a pud is trivial: the 1-entry pud is
    4.54 - * inside the pgd, so has no extra memory associated with it.
    4.55 - */
    4.56 -#define pud_alloc_one(mm, address)		NULL
    4.57 -#define pud_free(x)				do { } while (0)
    4.58 -#define __pud_free_tlb(tlb, x)			do { } while (0)
    4.59 -
    4.60 -#undef  pud_addr_end
    4.61 -#define pud_addr_end(addr, end)			(end)
    4.62 -
    4.63 -#endif /* __ASSEMBLY__ */
    4.64 -#endif /* _PGTABLE_NOPUD_H */