From 881f28d8e897daee3d6ba1c591098b50931b6cec Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Mon, 9 Mar 2009 09:19:42 +0000 Subject: [PATCH] [IA64] fix compilation error caused by 19286:dd489125a2e7 This patch fixes compilation error caused by 19286:dd489125a2e7 Signed-off-by: Isaku Yamahata --- xen/arch/ia64/xen/xensetup.c | 6 ++++++ xen/include/asm-ia64/mm.h | 23 ++++++++++++++++++++++- 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/xen/arch/ia64/xen/xensetup.c b/xen/arch/ia64/xen/xensetup.c index bc867dbe4e..c3affb4b0d 100644 --- a/xen/arch/ia64/xen/xensetup.c +++ b/xen/arch/ia64/xen/xensetup.c @@ -337,6 +337,8 @@ is_platform_hp_ski(void) static int __initdata dom0_vhpt_size_log2; integer_param("dom0_vhpt_size_log2", dom0_vhpt_size_log2); #endif +unsigned long xen_fixed_mfn_start __read_mostly; +unsigned long xen_fixed_mfn_end __read_mostly; void __init start_kernel(void) { @@ -556,6 +558,10 @@ skip_move: (xenheap_phys_end-__pa(xen_heap_start)) >> 20, (xenheap_phys_end-__pa(xen_heap_start)) >> 10); + /* for is_xen_fixed_mfn() */ + xen_fixed_mfn_start = virt_to_mfn(&_start); + xen_fixed_mfn_end = virt_to_mfn(xen_heap_start); + end_boot_allocator(); softirq_init(); diff --git a/xen/include/asm-ia64/mm.h b/xen/include/asm-ia64/mm.h index ec0af88389..c4da3a18e5 100644 --- a/xen/include/asm-ia64/mm.h +++ b/xen/include/asm-ia64/mm.h @@ -149,13 +149,34 @@ page_list_splice_init(struct page_list_head *list, struct page_list_head *head) # define PGC_xen_heap PG_mask(1, 2) /* bit PG_shift(3) reserved. See asm-x86/mm.h */ /* PG_mask(7, 6) reserved. See asm-x86/mm.h*/ + + /* Page is broken? */ +#define _PGC_broken PG_shift(7) +#define PGC_broken PG_mask(1, 7) + /* Page is offline pending ? */ +#define _PGC_offlining PG_shift(8) +#define PGC_offlining PG_mask(1, 8) + /* Page is offlined */ +#define _PGC_offlined PG_shift(9) +#define PGC_offlined PG_mask(1, 9) +#define PGC_offlined_broken (PGC_offlined | PGC_broken) + +#define is_page_offlining(page) ((page)->count_info & PGC_offlining) +#define is_page_offlined(page) ((page)->count_info & PGC_offlined) +#define is_page_broken(page) ((page)->count_info & PGC_broken) +#define is_page_online(page) (!is_page_offlined(page)) + /* Count of references to this frame. */ -#define PGC_count_width PG_shift(6) +#define PGC_count_width PG_shift(9) #define PGC_count_mask ((1UL<count_info & PGC_xen_heap) #define is_xen_heap_mfn(mfn) (mfn_valid(mfn) && \ is_xen_heap_page(mfn_to_page(mfn))) +#define is_xen_fixed_mfn(mfn) \ + (xen_fixed_mfn_start <= (mfn) && (mfn) <= xen_fixed_mfn_end) #ifdef CONFIG_IA64_PICKLE_DOMAIN #define page_get_owner(_p) \ -- 2.30.2