ia64/xen-unstable

changeset 3069:c52145d62855

bitkeeper revision 1.1159.179.15 (419e4147MLxxTvBc9zlN1KN3pUk7BA)

setup_arch_post.h:
clear feature sep flag to avoid modification to sysenter.c
Makefile:
g/c unmodified vmlinux.lds
ioremap.c, fault.c, timer_tsc.c, setup.c, ldt.c:
Whitespace.
traps.c:
Whitespace and remove unused code.
head.S:
writable pagetables are always enabled
Makefile:
g/c unmodified vmlinux.lds and sysenter.c
.del-sysenter.c~4edabffbf333447d:
Delete: linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/sysenter.c
.del-vmlinux.lds.S~a6e49b85e6684b9a:
Delete: linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/vmlinux.lds.S
author cl349@arcadians.cl.cam.ac.uk
date Fri Nov 19 18:53:59 2004 +0000 (2004-11-19)
parents e93693f73344
children 1e3e3846e8d7
files .rootkeys linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/Makefile linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/head.S linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/ldt.c linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/setup.c linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/sysenter.c linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/timers/timer_tsc.c linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/traps.c linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/vmlinux.lds.S linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/fault.c linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/ioremap.c linux-2.6.10-rc2-xen-sparse/arch/xen/kernel/Makefile linux-2.6.10-rc2-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h
line diff
     1.1 --- a/.rootkeys	Fri Nov 19 18:03:03 2004 +0000
     1.2 +++ b/.rootkeys	Fri Nov 19 18:53:59 2004 +0000
     1.3 @@ -148,12 +148,10 @@ 4107adf1cNtsuOxOB4T6paAoY2R2PA linux-2.6
     1.4  40f56238a8iOVDEoostsbun_sy2i4g linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/process.c
     1.5  40f56238YQIJoYG2ehDGEcdTgLmGbg linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/setup.c
     1.6  40f56238nWMQg7CKbyTy0KJNvCzbtg linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/signal.c
     1.7 -40f56238UL9uv78ODDzMwLL9yryeFw linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/sysenter.c
     1.8  40f56238qVGkpO_ycnQA8k03kQzAgA linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/time.c
     1.9  40f56238NzTgeO63RGoxHrW5NQeO3Q linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/timers/Makefile
    1.10  40f56238BMqG5PuSHufpjbvp_helBw linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/timers/timer_tsc.c
    1.11  40f562389xNa78YBZciUibQjyRU_Lg linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/traps.c
    1.12 -40f56238qASEI_IOhCKWNuwFKNZrKQ linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/vmlinux.lds.S
    1.13  40f56238JypKAUG01ZojFwH7qnZ5uA linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/vsyscall.S
    1.14  40f56238wi6AdNQjm0RT57bSkwb6hg linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/vsyscall.lds
    1.15  40f56238a3w6-byOzexIlMgni76Lcg linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/Makefile
     2.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/Makefile	Fri Nov 19 18:03:03 2004 +0000
     2.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/Makefile	Fri Nov 19 18:53:59 2004 +0000
     2.3 @@ -6,7 +6,7 @@ XENARCH	:= $(subst ",,$(CONFIG_XENARCH))
     2.4  
     2.5  CFLAGS	+= -Iarch/$(XENARCH)/kernel
     2.6  
     2.7 -extra-y := head.o init_task.o vmlinux.lds
     2.8 +extra-y := head.o init_task.o
     2.9  
    2.10  obj-y	:= process.o signal.o entry.o traps.o \
    2.11  		time.o ioport.o ldt.o setup.o \
    2.12 @@ -35,7 +35,7 @@ c-obj-$(CONFIG_X86_IO_APIC)	+= io_apic.o
    2.13  c-obj-$(CONFIG_X86_NUMAQ)	+= numaq.o
    2.14  c-obj-$(CONFIG_X86_SUMMIT_NUMA)	+= summit.o
    2.15  c-obj-$(CONFIG_MODULES)		+= module.o
    2.16 -obj-y				+= sysenter.o
    2.17 +c-obj-y				+= sysenter.o
    2.18  obj-y				+= vsyscall.o
    2.19  c-obj-$(CONFIG_ACPI_SRAT) 	+= srat.o
    2.20  c-obj-$(CONFIG_HPET_TIMER) 	+= time_hpet.o
    2.21 @@ -46,8 +46,6 @@ EXTRA_AFLAGS   := -traditional
    2.22  
    2.23  c-obj-$(CONFIG_SCx200)		+= scx200.o
    2.24  
    2.25 -CPPFLAGS_vmlinux.lds += -U$(XENARCH)
    2.26 -
    2.27  # vsyscall.o contains the vsyscall DSO images as __initdata.
    2.28  # We must build both images before we can assemble it.
    2.29  # Note: kbuild does not track this dependency due to usage of .incbin
     3.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/head.S	Fri Nov 19 18:03:03 2004 +0000
     3.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/head.S	Fri Nov 19 18:53:59 2004 +0000
     3.3 @@ -4,9 +4,7 @@
     3.4  .section __xen_guest
     3.5  	.ascii	"GUEST_OS=linux,GUEST_VER=2.6,XEN_VER=2.0,VIRT_BASE=0xC0000000"
     3.6  	.ascii	",LOADER=generic"
     3.7 -#ifdef CONFIG_XEN_WRITABLE_PAGETABLES
     3.8  	.ascii	",PT_MODE_WRITABLE"
     3.9 -#endif
    3.10  	.byte	0
    3.11  
    3.12  .text
    3.13 @@ -90,7 +88,6 @@ ENTRY(stack_start)
    3.14  	.long init_thread_union+THREAD_SIZE
    3.15  	.long __BOOT_DS
    3.16  
    3.17 -# XXXcl
    3.18  .globl idt_descr
    3.19  .globl cpu_gdt_descr
    3.20  
    3.21 @@ -99,7 +96,6 @@ ENTRY(stack_start)
    3.22  idt_descr:
    3.23  	.word IDT_ENTRIES*8-1		# idt contains 256 entries
    3.24  	.long idt_table
    3.25 -# XXXcl
    3.26  
    3.27  # boot GDT descriptor (later on used by CPU#0):
    3.28  	.word 0				# 32 bit align gdt_desc.address
     4.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/ldt.c	Fri Nov 19 18:03:03 2004 +0000
     4.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/ldt.c	Fri Nov 19 18:53:59 2004 +0000
     4.3 @@ -125,8 +125,8 @@ void destroy_context(struct mm_struct *m
     4.4  		if (mm == current->active_mm)
     4.5  			clear_LDT();
     4.6  		make_pages_writable(mm->context.ldt, 
     4.7 -                                    (mm->context.size * LDT_ENTRY_SIZE) /
     4.8 -                                    PAGE_SIZE);
     4.9 +				    (mm->context.size * LDT_ENTRY_SIZE) /
    4.10 +				    PAGE_SIZE);
    4.11  		flush_page_update_queue();
    4.12  		if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE)
    4.13  			vfree(mm->context.ldt);
     5.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/setup.c	Fri Nov 19 18:03:03 2004 +0000
     5.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/setup.c	Fri Nov 19 18:53:59 2004 +0000
     5.3 @@ -686,7 +686,7 @@ static void __init parse_cmdline_early (
     5.4  	int len = 0;
     5.5  	int userdef = 0;
     5.6  
     5.7 -        memcpy(saved_command_line, xen_start_info.cmd_line, MAX_CMDLINE);
     5.8 +	memcpy(saved_command_line, xen_start_info.cmd_line, MAX_CMDLINE);
     5.9  	/* Save unparsed command line copy for /proc/cmdline */
    5.10  	saved_command_line[COMMAND_LINE_SIZE-1] = '\0';
    5.11  
     6.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/sysenter.c	Fri Nov 19 18:03:03 2004 +0000
     6.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.3 @@ -1,65 +0,0 @@
     6.4 -/*
     6.5 - * linux/arch/i386/kernel/sysenter.c
     6.6 - *
     6.7 - * (C) Copyright 2002 Linus Torvalds
     6.8 - *
     6.9 - * This file contains the needed initializations to support sysenter.
    6.10 - */
    6.11 -
    6.12 -#include <linux/init.h>
    6.13 -#include <linux/smp.h>
    6.14 -#include <linux/thread_info.h>
    6.15 -#include <linux/sched.h>
    6.16 -#include <linux/gfp.h>
    6.17 -#include <linux/string.h>
    6.18 -#include <linux/elf.h>
    6.19 -
    6.20 -#include <asm/cpufeature.h>
    6.21 -#include <asm/msr.h>
    6.22 -#include <asm/pgtable.h>
    6.23 -#include <asm/unistd.h>
    6.24 -
    6.25 -extern asmlinkage void sysenter_entry(void);
    6.26 -
    6.27 -void enable_sep_cpu(void *info)
    6.28 -{
    6.29 -	int cpu = get_cpu();
    6.30 -	struct tss_struct *tss = &per_cpu(init_tss, cpu);
    6.31 -
    6.32 -	tss->ss1 = __KERNEL_CS;
    6.33 -	tss->esp1 = sizeof(struct tss_struct) + (unsigned long) tss;
    6.34 -	wrmsr(MSR_IA32_SYSENTER_CS, __KERNEL_CS, 0);
    6.35 -	wrmsr(MSR_IA32_SYSENTER_ESP, tss->esp1, 0);
    6.36 -	wrmsr(MSR_IA32_SYSENTER_EIP, (unsigned long) sysenter_entry, 0);
    6.37 -	put_cpu();	
    6.38 -}
    6.39 -
    6.40 -/*
    6.41 - * These symbols are defined by vsyscall.o to mark the bounds
    6.42 - * of the ELF DSO images included therein.
    6.43 - */
    6.44 -extern const char vsyscall_int80_start, vsyscall_int80_end;
    6.45 -extern const char vsyscall_sysenter_start, vsyscall_sysenter_end;
    6.46 -
    6.47 -static int __init sysenter_setup(void)
    6.48 -{
    6.49 -	void *page = (void *)get_zeroed_page(GFP_ATOMIC);
    6.50 -
    6.51 -	__set_fixmap(FIX_VSYSCALL, __pa(page), PAGE_READONLY_EXEC);
    6.52 -
    6.53 -	if (1 /* XXXcl not yet */ || !boot_cpu_has(X86_FEATURE_SEP)) {
    6.54 -		memcpy(page,
    6.55 -		       &vsyscall_int80_start,
    6.56 -		       &vsyscall_int80_end - &vsyscall_int80_start);
    6.57 -		return 0;
    6.58 -	}
    6.59 -
    6.60 -	memcpy(page,
    6.61 -	       &vsyscall_sysenter_start,
    6.62 -	       &vsyscall_sysenter_end - &vsyscall_sysenter_start);
    6.63 -
    6.64 -	on_each_cpu(enable_sep_cpu, NULL, 1, 1);
    6.65 -	return 0;
    6.66 -}
    6.67 -
    6.68 -__initcall(sysenter_setup);
     7.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/timers/timer_tsc.c	Fri Nov 19 18:03:03 2004 +0000
     7.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/timers/timer_tsc.c	Fri Nov 19 18:53:59 2004 +0000
     7.3 @@ -67,10 +67,6 @@ static inline unsigned long long cycles_
     7.4  	return (cyc * cyc2ns_scale) >> CYC2NS_SCALE_FACTOR;
     7.5  }
     7.6  
     7.7 -#if 0
     7.8 -static int count2; /* counter for mark_offset_tsc() */
     7.9 -#endif
    7.10 -
    7.11  /* Cached *multiplier* to convert TSC counts to microseconds.
    7.12   * (see the equation below).
    7.13   * Equal to 2^32 * (1 / (clocks per usec) ).
    7.14 @@ -93,13 +89,13 @@ static unsigned long get_offset_tsc(void
    7.15  	eax -= shadow_tsc_stamp;
    7.16  
    7.17  	/*
    7.18 -	 * Time offset = (tsc_low delta) * fast_gettimeoffset_quotient
    7.19 -	 *             = (tsc_low delta) * (usecs_per_clock)
    7.20 -	 *             = (tsc_low delta) * (usecs_per_jiffy / clocks_per_jiffy)
    7.21 +         * Time offset = (tsc_low delta) * fast_gettimeoffset_quotient
    7.22 +         *             = (tsc_low delta) * (usecs_per_clock)
    7.23 +         *             = (tsc_low delta) * (usecs_per_jiffy / clocks_per_jiffy)
    7.24  	 *
    7.25  	 * Using a mull instead of a divl saves up to 31 clock cycles
    7.26  	 * in the critical path.
    7.27 -	 */
    7.28 +         */
    7.29  
    7.30  	__asm__("mull %2"
    7.31  		:"=a" (eax), "=d" (edx)
     8.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/traps.c	Fri Nov 19 18:03:03 2004 +0000
     8.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/traps.c	Fri Nov 19 18:53:59 2004 +0000
     8.3 @@ -127,7 +127,7 @@ static inline unsigned long print_contex
     8.4  		addr = *stack++;
     8.5  		if (__kernel_text_address(addr)) {
     8.6  			printk(" [<%08lx>]", addr);
     8.7 -			print_symbol(" %s\n", addr);
     8.8 +			print_symbol(" %s", addr);
     8.9  			printk("\n");
    8.10  		}
    8.11  	}
    8.12 @@ -737,8 +737,8 @@ fastcall void do_debug(struct pt_regs * 
    8.13  	/* If this is a kernel mode trap, save the user PC on entry to 
    8.14  	 * the kernel, that's what the debugger can make sense of.
    8.15  	 */
    8.16 -	info.si_addr = ((regs->xcs & 2) == 0) ? (void __user *)tsk->thread.eip : 
    8.17 -	                                        (void __user *)regs->eip;
    8.18 +	info.si_addr = ((regs->xcs & 2) == 0) ? (void __user *)tsk->thread.eip
    8.19 +	                                      : (void __user *)regs->eip;
    8.20  	force_sig_info(SIGTRAP, &info, tsk);
    8.21  
    8.22  	/* Disable additional traps. They'll be re-enabled when
    8.23 @@ -954,58 +954,6 @@ void __init trap_init_f00f_bug(void)
    8.24  }
    8.25  #endif
    8.26  
    8.27 -#define _set_gate(gate_addr,type,dpl,addr,seg) \
    8.28 -do { \
    8.29 -  int __d0, __d1; \
    8.30 -  __asm__ __volatile__ ("movw %%dx,%%ax\n\t" \
    8.31 -	"movw %4,%%dx\n\t" \
    8.32 -	"movl %%eax,%0\n\t" \
    8.33 -	"movl %%edx,%1" \
    8.34 -	:"=m" (*((long *) (gate_addr))), \
    8.35 -	 "=m" (*(1+(long *) (gate_addr))), "=&a" (__d0), "=&d" (__d1) \
    8.36 -	:"i" ((short) (0x8000+(dpl<<13)+(type<<8))), \
    8.37 -	 "3" ((char *) (addr)),"2" ((seg) << 16)); \
    8.38 -} while (0)
    8.39 -
    8.40 -
    8.41 -/*
    8.42 - * This needs to use 'idt_table' rather than 'idt', and
    8.43 - * thus use the _nonmapped_ version of the IDT, as the
    8.44 - * Pentium F0 0F bugfix can have resulted in the mapped
    8.45 - * IDT being write-protected.
    8.46 - */
    8.47 -void set_intr_gate(unsigned int n, void *addr)
    8.48 -{
    8.49 -	_set_gate(idt_table+n,14,0,addr,__KERNEL_CS);
    8.50 -}
    8.51 -
    8.52 -#if 0
    8.53 -/*
    8.54 - * This routine sets up an interrupt gate at directory privilege level 3.
    8.55 - */
    8.56 -static inline void set_system_intr_gate(unsigned int n, void *addr)
    8.57 -{
    8.58 -	_set_gate(idt_table+n, 14, 3, addr, __KERNEL_CS);
    8.59 -}
    8.60 -
    8.61 -static void __init set_trap_gate(unsigned int n, void *addr)
    8.62 -{
    8.63 -	_set_gate(idt_table+n,15,0,addr,__KERNEL_CS);
    8.64 -}
    8.65 -
    8.66 -static void __init set_system_gate(unsigned int n, void *addr)
    8.67 -{
    8.68 -	_set_gate(idt_table+n,15,3,addr,__KERNEL_CS);
    8.69 -}
    8.70 -#endif
    8.71 -
    8.72 -#if 0
    8.73 -static void __init set_task_gate(unsigned int n, unsigned int gdt_entry)
    8.74 -{
    8.75 -	_set_gate(idt_table+n,5,0,0,(gdt_entry<<3));
    8.76 -}
    8.77 -#endif
    8.78 -
    8.79  
    8.80  /* NB. All these are "trap gates" (i.e. events_mask isn't cleared). */
    8.81  static trap_info_t trap_table[] = {
    8.82 @@ -1030,14 +978,14 @@ static trap_info_t trap_table[] = {
    8.83  	{ 18, 0, __KERNEL_CS, (unsigned long)machine_check		},
    8.84  #endif
    8.85  	{ 19, 0, __KERNEL_CS, (unsigned long)simd_coprocessor_error	},
    8.86 -	{ SYSCALL_VECTOR, 3, __KERNEL_CS, (unsigned long)system_call	},
    8.87 -	{  0, 0,           0, 0						}
    8.88 +	{ SYSCALL_VECTOR,  3, __KERNEL_CS, (unsigned long)system_call	},
    8.89 +	{  0, 0,	   0, 0						}
    8.90  };
    8.91  
    8.92  void __init trap_init(void)
    8.93  {
    8.94 -	HYPERVISOR_set_trap_table(trap_table);    
    8.95 -        HYPERVISOR_set_fast_trap(SYSCALL_VECTOR);
    8.96 +	HYPERVISOR_set_trap_table(trap_table);
    8.97 +	HYPERVISOR_set_fast_trap(SYSCALL_VECTOR);
    8.98  
    8.99  	/*
   8.100  	 * default LDT is a single-entry callgate to lcall7 for iBCS
     9.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/kernel/vmlinux.lds.S	Fri Nov 19 18:03:03 2004 +0000
     9.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.3 @@ -1,134 +0,0 @@
     9.4 -/* ld script to make i386 Linux kernel
     9.5 - * Written by Martin Mares <mj@atrey.karlin.mff.cuni.cz>;
     9.6 - */
     9.7 -
     9.8 -#include <asm-generic/vmlinux.lds.h>
     9.9 -#include <asm/thread_info.h>
    9.10 -#include <asm/page.h>
    9.11 -
    9.12 -OUTPUT_FORMAT("elf32-i386", "elf32-i386", "elf32-i386")
    9.13 -OUTPUT_ARCH(i386)
    9.14 -ENTRY(startup_32)
    9.15 -jiffies = jiffies_64;
    9.16 -SECTIONS
    9.17 -{
    9.18 -  . = __PAGE_OFFSET + 0x100000;
    9.19 -  /* read-only */
    9.20 -  _text = .;			/* Text and read-only data */
    9.21 -  .text : {
    9.22 -	*(.text)
    9.23 -	SCHED_TEXT
    9.24 -	LOCK_TEXT
    9.25 -	*(.fixup)
    9.26 -	*(.gnu.warning)
    9.27 -	} = 0x9090
    9.28 -
    9.29 -  _etext = .;			/* End of text section */
    9.30 -
    9.31 -  . = ALIGN(16);		/* Exception table */
    9.32 -  __start___ex_table = .;
    9.33 -  __ex_table : { *(__ex_table) }
    9.34 -  __stop___ex_table = .;
    9.35 -
    9.36 -  RODATA
    9.37 -
    9.38 -  /* writeable */
    9.39 -  .data : {			/* Data */
    9.40 -	*(.data)
    9.41 -	CONSTRUCTORS
    9.42 -	}
    9.43 -
    9.44 -  . = ALIGN(4096);
    9.45 -  __nosave_begin = .;
    9.46 -  .data_nosave : { *(.data.nosave) }
    9.47 -  . = ALIGN(4096);
    9.48 -  __nosave_end = .;
    9.49 -
    9.50 -  . = ALIGN(4096);
    9.51 -  .data.page_aligned : { *(.data.idt) }
    9.52 -
    9.53 -  . = ALIGN(32);
    9.54 -  .data.cacheline_aligned : { *(.data.cacheline_aligned) }
    9.55 -
    9.56 -  _edata = .;			/* End of data section */
    9.57 -
    9.58 -  . = ALIGN(THREAD_SIZE);	/* init_task */
    9.59 -  .data.init_task : { *(.data.init_task) }
    9.60 -
    9.61 -  /* will be freed after init */
    9.62 -  . = ALIGN(4096);		/* Init code and data */
    9.63 -  __init_begin = .;
    9.64 -  .init.text : { 
    9.65 -	_sinittext = .;
    9.66 -	*(.init.text)
    9.67 -	_einittext = .;
    9.68 -  }
    9.69 -  .init.data : { *(.init.data) }
    9.70 -  . = ALIGN(16);
    9.71 -  __setup_start = .;
    9.72 -  .init.setup : { *(.init.setup) }
    9.73 -  __setup_end = .;
    9.74 -  __initcall_start = .;
    9.75 -  .initcall.init : {
    9.76 -	*(.initcall1.init) 
    9.77 -	*(.initcall2.init) 
    9.78 -	*(.initcall3.init) 
    9.79 -	*(.initcall4.init) 
    9.80 -	*(.initcall5.init) 
    9.81 -	*(.initcall6.init) 
    9.82 -	*(.initcall7.init)
    9.83 -  }
    9.84 -  __initcall_end = .;
    9.85 -  __con_initcall_start = .;
    9.86 -  .con_initcall.init : { *(.con_initcall.init) }
    9.87 -  __con_initcall_end = .;
    9.88 -  SECURITY_INIT
    9.89 -  . = ALIGN(4);
    9.90 -  __alt_instructions = .;
    9.91 -  .altinstructions : { *(.altinstructions) } 
    9.92 -  __alt_instructions_end = .; 
    9.93 - .altinstr_replacement : { *(.altinstr_replacement) } 
    9.94 -  /* .exit.text is discard at runtime, not link time, to deal with references
    9.95 -     from .altinstructions and .eh_frame */
    9.96 -  .exit.text : { *(.exit.text) }
    9.97 -  .exit.data : { *(.exit.data) }
    9.98 -  . = ALIGN(4096);
    9.99 -  __initramfs_start = .;
   9.100 -  .init.ramfs : { *(.init.ramfs) }
   9.101 -  __initramfs_end = .;
   9.102 -  . = ALIGN(32);
   9.103 -  __per_cpu_start = .;
   9.104 -  .data.percpu  : { *(.data.percpu) }
   9.105 -  __per_cpu_end = .;
   9.106 -  . = ALIGN(4096);
   9.107 -  __init_end = .;
   9.108 -  /* freed after init ends here */
   9.109 -	
   9.110 -  __bss_start = .;		/* BSS */
   9.111 -  .bss : {
   9.112 -	*(.bss.page_aligned)
   9.113 -	*(.bss)
   9.114 -  }
   9.115 -  . = ALIGN(4);
   9.116 -  __bss_stop = .; 
   9.117 -
   9.118 -  _end = . ;
   9.119 -
   9.120 -  /* This is where the kernel creates the early boot page tables */
   9.121 -  . = ALIGN(4096);
   9.122 -  pg0 = .;
   9.123 -
   9.124 -  /* Sections to be discarded */
   9.125 -  /DISCARD/ : {
   9.126 -	*(.exitcall.exit)
   9.127 -	}
   9.128 -
   9.129 -  /* Stabs debugging sections.  */
   9.130 -  .stab 0 : { *(.stab) }
   9.131 -  .stabstr 0 : { *(.stabstr) }
   9.132 -  .stab.excl 0 : { *(.stab.excl) }
   9.133 -  .stab.exclstr 0 : { *(.stab.exclstr) }
   9.134 -  .stab.index 0 : { *(.stab.index) }
   9.135 -  .stab.indexstr 0 : { *(.stab.indexstr) }
   9.136 -  .comment 0 : { *(.comment) }
   9.137 -}
    10.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/fault.c	Fri Nov 19 18:03:03 2004 +0000
    10.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/fault.c	Fri Nov 19 18:53:59 2004 +0000
    10.3 @@ -454,7 +454,8 @@ no_context:
    10.4  	printk(KERN_ALERT " printing eip:\n");
    10.5  	printk("%08lx\n", regs->eip);
    10.6  	page = ((unsigned long *) cur_pgd)[address >> 22];
    10.7 -	printk(KERN_ALERT "*pde = ma %08lx pa %08lx\n", page, machine_to_phys(page));
    10.8 +	printk(KERN_ALERT "*pde = ma %08lx pa %08lx\n", page,
    10.9 +	       machine_to_phys(page));
   10.10  	/*
   10.11  	 * We must not directly access the pte in the highpte
   10.12  	 * case, the page table might be allocated in highmem.
   10.13 @@ -467,7 +468,8 @@ no_context:
   10.14  		address &= 0x003ff000;
   10.15  		page = machine_to_phys(page);
   10.16  		page = ((unsigned long *) __va(page))[address >> PAGE_SHIFT];
   10.17 -		printk(KERN_ALERT "*pte = ma %08lx pa %08lx\n", page, machine_to_phys(page));
   10.18 +		printk(KERN_ALERT "*pte = ma %08lx pa %08lx\n", page,
   10.19 +		       machine_to_phys(page));
   10.20  	}
   10.21  #endif
   10.22  	show_trace(NULL, (unsigned long *)&regs[1]);
    11.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/ioremap.c	Fri Nov 19 18:03:03 2004 +0000
    11.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/i386/mm/ioremap.c	Fri Nov 19 18:53:59 2004 +0000
    11.3 @@ -19,20 +19,29 @@
    11.4  
    11.5  #ifndef CONFIG_XEN_PHYSDEV_ACCESS
    11.6  
    11.7 -void * __ioremap(unsigned long phys_addr, unsigned long size, unsigned long flags)
    11.8 -{ return NULL; }
    11.9 +void * __ioremap(unsigned long phys_addr, unsigned long size,
   11.10 +		 unsigned long flags)
   11.11 +{
   11.12 +	return NULL;
   11.13 +}
   11.14  
   11.15  void *ioremap_nocache (unsigned long phys_addr, unsigned long size)
   11.16 -{ return NULL; }
   11.17 +{
   11.18 +	return NULL;
   11.19 +}
   11.20  
   11.21  void iounmap(volatile void __iomem *addr)
   11.22 -{ }
   11.23 +{
   11.24 +}
   11.25  
   11.26  void __init *bt_ioremap(unsigned long phys_addr, unsigned long size)
   11.27 -{ return NULL; }
   11.28 +{
   11.29 +	return NULL;
   11.30 +}
   11.31  
   11.32  void __init bt_iounmap(void *addr, unsigned long size)
   11.33 -{ }
   11.34 +{
   11.35 +}
   11.36  
   11.37  #else
   11.38  
   11.39 @@ -140,8 +149,8 @@ void __iomem * __ioremap(unsigned long p
   11.40  	if (!size || last_addr < phys_addr)
   11.41  		return NULL;
   11.42  
   11.43 -        if (phys_addr >= 0x0 && last_addr < 0x100000)
   11.44 -                return isa_bus_to_virt(phys_addr);
   11.45 +	if (phys_addr >= 0x0 && last_addr < 0x100000)
   11.46 +		return isa_bus_to_virt(phys_addr);
   11.47  
   11.48  	/*
   11.49  	 * Don't remap the low PCI/ISA area, it's always mapped..
   11.50 @@ -246,8 +255,8 @@ void __iomem *ioremap_nocache (unsigned 
   11.51  void iounmap(volatile void __iomem *addr)
   11.52  {
   11.53  	struct vm_struct *p;
   11.54 -        if ((unsigned long)addr <= 0x100000)
   11.55 -                return;
   11.56 +	if ((unsigned long)addr <= 0x100000)
   11.57 +		return;
   11.58  	if ((void __force *) addr <= high_memory) 
   11.59  		return; 
   11.60  	p = remove_vm_area((void *) (PAGE_MASK & (unsigned long __force) addr));
   11.61 @@ -276,8 +285,8 @@ void __init *bt_ioremap(unsigned long ph
   11.62  	if (!size || last_addr < phys_addr)
   11.63  		return NULL;
   11.64  
   11.65 -        if (phys_addr >= 0x0 && last_addr < 0x100000)
   11.66 -                return isa_bus_to_virt(phys_addr);
   11.67 +	if (phys_addr >= 0x0 && last_addr < 0x100000)
   11.68 +		return isa_bus_to_virt(phys_addr);
   11.69  
   11.70  	/*
   11.71  	 * Don't remap the low PCI/ISA area, it's always mapped..
   11.72 @@ -320,8 +329,8 @@ void __init bt_iounmap(void *addr, unsig
   11.73  	enum fixed_addresses idx;
   11.74  
   11.75  	virt_addr = (unsigned long)addr;
   11.76 -        if (virt_addr < 0x100000)
   11.77 -                return;
   11.78 +	if (virt_addr < 0x100000)
   11.79 +		return;
   11.80  	if (virt_addr < fix_to_virt(FIX_BTMAP_BEGIN))
   11.81  		return;
   11.82  	offset = virt_addr & ~PAGE_MASK;
   11.83 @@ -345,51 +354,51 @@ void __init bt_iounmap(void *addr, unsig
   11.84    __direct_mk_pte((physpage) >> PAGE_SHIFT, pgprot)
   11.85  
   11.86  static inline void direct_remap_area_pte(pte_t *pte, 
   11.87 -                                        unsigned long address, 
   11.88 -                                        unsigned long size,
   11.89 -					mmu_update_t **v)
   11.90 +					 unsigned long address, 
   11.91 +					 unsigned long size,
   11.92 +					 mmu_update_t **v)
   11.93  {
   11.94 -    unsigned long end;
   11.95 +	unsigned long end;
   11.96  
   11.97 -    address &= ~PMD_MASK;
   11.98 -    end = address + size;
   11.99 -    if (end > PMD_SIZE)
  11.100 -        end = PMD_SIZE;
  11.101 -    if (address >= end)
  11.102 -        BUG();
  11.103 +	address &= ~PMD_MASK;
  11.104 +	end = address + size;
  11.105 +	if (end > PMD_SIZE)
  11.106 +		end = PMD_SIZE;
  11.107 +	if (address >= end)
  11.108 +		BUG();
  11.109  
  11.110 -    do {
  11.111 -        (*v)->ptr = virt_to_machine(pte);
  11.112 -        (*v)++;
  11.113 -        address += PAGE_SIZE;
  11.114 -        pte++;
  11.115 -    } while (address && (address < end));
  11.116 +	do {
  11.117 +		(*v)->ptr = virt_to_machine(pte);
  11.118 +		(*v)++;
  11.119 +		address += PAGE_SIZE;
  11.120 +		pte++;
  11.121 +	} while (address && (address < end));
  11.122  }
  11.123  
  11.124  static inline int direct_remap_area_pmd(struct mm_struct *mm,
  11.125 -                                        pmd_t *pmd, 
  11.126 -                                        unsigned long address, 
  11.127 -                                        unsigned long size,
  11.128 +					pmd_t *pmd, 
  11.129 +					unsigned long address, 
  11.130 +					unsigned long size,
  11.131  					mmu_update_t **v)
  11.132  {
  11.133 -    unsigned long end;
  11.134 +	unsigned long end;
  11.135  
  11.136 -    address &= ~PGDIR_MASK;
  11.137 -    end = address + size;
  11.138 -    if (end > PGDIR_SIZE)
  11.139 -        end = PGDIR_SIZE;
  11.140 -    if (address >= end)
  11.141 -        BUG();
  11.142 -    do {
  11.143 -        pte_t *pte = pte_alloc_map(mm, pmd, address);
  11.144 -        if (!pte)
  11.145 -            return -ENOMEM;
  11.146 -        direct_remap_area_pte(pte, address, end - address, v);
  11.147 -	pte_unmap(pte);
  11.148 -        address = (address + PMD_SIZE) & PMD_MASK;
  11.149 -        pmd++;
  11.150 -    } while (address && (address < end));
  11.151 -    return 0;
  11.152 +	address &= ~PGDIR_MASK;
  11.153 +	end = address + size;
  11.154 +	if (end > PGDIR_SIZE)
  11.155 +		end = PGDIR_SIZE;
  11.156 +	if (address >= end)
  11.157 +		BUG();
  11.158 +	do {
  11.159 +		pte_t *pte = pte_alloc_map(mm, pmd, address);
  11.160 +		if (!pte)
  11.161 +			return -ENOMEM;
  11.162 +		direct_remap_area_pte(pte, address, end - address, v);
  11.163 +		pte_unmap(pte);
  11.164 +		address = (address + PMD_SIZE) & PMD_MASK;
  11.165 +		pmd++;
  11.166 +	} while (address && (address < end));
  11.167 +	return 0;
  11.168  }
  11.169   
  11.170  int __direct_remap_area_pages(struct mm_struct *mm,
  11.171 @@ -397,85 +406,82 @@ int __direct_remap_area_pages(struct mm_
  11.172  			      unsigned long size, 
  11.173  			      mmu_update_t *v)
  11.174  {
  11.175 -    pgd_t * dir;
  11.176 -    unsigned long end = address + size;
  11.177 +	pgd_t * dir;
  11.178 +	unsigned long end = address + size;
  11.179  
  11.180 -    dir = pgd_offset(mm, address);
  11.181 -    flush_cache_all();
  11.182 -    if (address >= end)
  11.183 -        BUG();
  11.184 -    spin_lock(&mm->page_table_lock);
  11.185 -    do {
  11.186 -        pmd_t *pmd = pmd_alloc(mm, dir, address);
  11.187 -        if (!pmd)
  11.188 -	    return -ENOMEM;
  11.189 -        direct_remap_area_pmd(mm, pmd, address, end - address, &v);
  11.190 -        address = (address + PGDIR_SIZE) & PGDIR_MASK;
  11.191 -        dir++;
  11.192 +	dir = pgd_offset(mm, address);
  11.193 +	flush_cache_all();
  11.194 +	if (address >= end)
  11.195 +		BUG();
  11.196 +	spin_lock(&mm->page_table_lock);
  11.197 +	do {
  11.198 +		pmd_t *pmd = pmd_alloc(mm, dir, address);
  11.199 +		if (!pmd)
  11.200 +			return -ENOMEM;
  11.201 +		direct_remap_area_pmd(mm, pmd, address, end - address, &v);
  11.202 +		address = (address + PGDIR_SIZE) & PGDIR_MASK;
  11.203 +		dir++;
  11.204  
  11.205 -    } while (address && (address < end));
  11.206 -    spin_unlock(&mm->page_table_lock);
  11.207 -    flush_tlb_all();
  11.208 -    return 0;
  11.209 +	} while (address && (address < end));
  11.210 +	spin_unlock(&mm->page_table_lock);
  11.211 +	flush_tlb_all();
  11.212 +	return 0;
  11.213  }
  11.214  
  11.215  
  11.216  int direct_remap_area_pages(struct mm_struct *mm,
  11.217 -                            unsigned long address, 
  11.218 -                            unsigned long machine_addr,
  11.219 -                            unsigned long size, 
  11.220 -                            pgprot_t prot,
  11.221 -                            domid_t  domid)
  11.222 +			    unsigned long address, 
  11.223 +			    unsigned long machine_addr,
  11.224 +			    unsigned long size, 
  11.225 +			    pgprot_t prot,
  11.226 +			    domid_t  domid)
  11.227  {
  11.228 -    int i;
  11.229 -    unsigned long start_address;
  11.230 +	int i;
  11.231 +	unsigned long start_address;
  11.232  #define MAX_DIRECTMAP_MMU_QUEUE 130
  11.233 -    mmu_update_t u[MAX_DIRECTMAP_MMU_QUEUE], *w, *v;
  11.234 +	mmu_update_t u[MAX_DIRECTMAP_MMU_QUEUE], *w, *v;
  11.235  
  11.236 -    u[0].ptr  = MMU_EXTENDED_COMMAND;
  11.237 -    u[0].val  = MMUEXT_SET_FOREIGNDOM;
  11.238 -    u[0].val |= (unsigned long)domid << 16;
  11.239 -    v = w = &u[1];
  11.240 +	u[0].ptr  = MMU_EXTENDED_COMMAND;
  11.241 +	u[0].val  = MMUEXT_SET_FOREIGNDOM;
  11.242 +	u[0].val |= (unsigned long)domid << 16;
  11.243 +	v = w = &u[1];
  11.244 +
  11.245 +	start_address = address;
  11.246  
  11.247 -    start_address = address;
  11.248 +	for(i = 0; i < size; i += PAGE_SIZE) {
  11.249 +		if ((v - u) == MAX_DIRECTMAP_MMU_QUEUE) {
  11.250 +			/* Fill in the PTE pointers. */
  11.251 +			__direct_remap_area_pages(mm,
  11.252 +						  start_address, 
  11.253 +						  address-start_address, 
  11.254 +						  w);
  11.255 +	    
  11.256 +			if (HYPERVISOR_mmu_update(u, v - u, NULL) < 0)
  11.257 +				return -EFAULT;	    
  11.258 +			v = w;
  11.259 +			start_address = address;
  11.260 +		}
  11.261  
  11.262 -    for( i = 0; i < size; i += PAGE_SIZE )
  11.263 -    {
  11.264 -	if ( (v - u) == MAX_DIRECTMAP_MMU_QUEUE )
  11.265 -	{
  11.266 -	    /* Fill in the PTE pointers. */
  11.267 -	    __direct_remap_area_pages( mm,
  11.268 -				       start_address, 
  11.269 -				       address-start_address, 
  11.270 -				       w);
  11.271 -	    
  11.272 -	    if ( HYPERVISOR_mmu_update(u, v - u, NULL) < 0 )
  11.273 -		return -EFAULT;	    
  11.274 -	    v = w;
  11.275 -	    start_address = address;
  11.276 +		/*
  11.277 +		 * Fill in the machine address: PTE ptr is done later by
  11.278 +		 * __direct_remap_area_pages(). 
  11.279 +		 */
  11.280 +		v->val = (machine_addr & PAGE_MASK) | pgprot_val(prot);
  11.281 +
  11.282 +		machine_addr += PAGE_SIZE;
  11.283 +		address += PAGE_SIZE; 
  11.284 +		v++;
  11.285  	}
  11.286  
  11.287 -	/*
  11.288 -         * Fill in the machine address: PTE ptr is done later by
  11.289 -         * __direct_remap_area_pages(). 
  11.290 -         */
  11.291 -        v->val = (machine_addr & PAGE_MASK) | pgprot_val(prot);
  11.292 -
  11.293 -        machine_addr += PAGE_SIZE;
  11.294 -        address += PAGE_SIZE; 
  11.295 -        v++;
  11.296 -    }
  11.297 -
  11.298 -    if ( v != w )
  11.299 -    {
  11.300 -	/* get the ptep's filled in */
  11.301 -	__direct_remap_area_pages(mm,
  11.302 -                                  start_address, 
  11.303 -                                  address-start_address, 
  11.304 -                                  w);	 
  11.305 -	if ( unlikely(HYPERVISOR_mmu_update(u, v - u, NULL) < 0) )
  11.306 -	    return -EFAULT;	    
  11.307 -    }
  11.308 +	if (v != w) {
  11.309 +		/* get the ptep's filled in */
  11.310 +		__direct_remap_area_pages(mm,
  11.311 +					  start_address, 
  11.312 +					  address-start_address, 
  11.313 +					  w);	 
  11.314 +		if (unlikely(HYPERVISOR_mmu_update(u, v - u, NULL) < 0))
  11.315 +			return -EFAULT;	    
  11.316 +	}
  11.317      
  11.318 -    return 0;
  11.319 +	return 0;
  11.320  }
    12.1 --- a/linux-2.6.10-rc2-xen-sparse/arch/xen/kernel/Makefile	Fri Nov 19 18:03:03 2004 +0000
    12.2 +++ b/linux-2.6.10-rc2-xen-sparse/arch/xen/kernel/Makefile	Fri Nov 19 18:53:59 2004 +0000
    12.3 @@ -4,8 +4,10 @@
    12.4  
    12.5  XENARCH	:= $(subst ",,$(CONFIG_XENARCH))
    12.6  
    12.7 -$(obj)/vmlinux.lds:
    12.8 -	@ln -fsn $(srctree)/arch/$(ARCH)/$(XENARCH)/kernel/vmlinux.lds $@
    12.9 +CPPFLAGS_vmlinux.lds += -U$(XENARCH)
   12.10 +
   12.11 +$(obj)/vmlinux.lds.S:
   12.12 +	@ln -fsn $(srctree)/arch/$(XENARCH)/kernel/vmlinux.lds.S $@
   12.13  
   12.14  extra-y += vmlinux.lds
   12.15  
    13.1 --- a/linux-2.6.10-rc2-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h	Fri Nov 19 18:03:03 2004 +0000
    13.2 +++ b/linux-2.6.10-rc2-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h	Fri Nov 19 18:53:59 2004 +0000
    13.3 @@ -28,6 +28,7 @@ void __init machine_specific_modify_cpu_
    13.4  	clear_bit(X86_FEATURE_DE, c->x86_capability);
    13.5  	clear_bit(X86_FEATURE_PSE, c->x86_capability);
    13.6  	clear_bit(X86_FEATURE_PGE, c->x86_capability);
    13.7 +	clear_bit(X86_FEATURE_SEP, c->x86_capability);
    13.8  	clear_bit(X86_FEATURE_MTRR, c->x86_capability);
    13.9  	clear_bit(X86_FEATURE_FXSR, c->x86_capability);
   13.10  }