diff options
Diffstat (limited to 'arch')
93 files changed, 1480 insertions, 822 deletions
diff --git a/arch/arm/mm/fault.c b/arch/arm/mm/fault.c index c04124a095c..846cce48e2b 100644 --- a/arch/arm/mm/fault.c +++ b/arch/arm/mm/fault.c @@ -145,8 +145,8 @@ void do_bad_area(unsigned long addr, unsigned int fsr, struct pt_regs *regs) __do_kernel_fault(mm, addr, fsr, regs); } -#define VM_FAULT_BADMAP (-20) -#define VM_FAULT_BADACCESS (-21) +#define VM_FAULT_BADMAP 0x010000 +#define VM_FAULT_BADACCESS 0x020000 static int __do_page_fault(struct mm_struct *mm, unsigned long addr, unsigned int fsr, @@ -249,7 +249,7 @@ do_page_fault(unsigned long addr, unsigned int fsr, struct pt_regs *regs) /* * Handle the "normal" case first - VM_FAULT_MAJOR / VM_FAULT_MINOR */ - if (likely(!(fault & VM_FAULT_ERROR))) + if (likely(!(fault & (VM_FAULT_ERROR | VM_FAULT_BADMAP | VM_FAULT_BADACCESS)))) return 0; /* diff --git a/arch/i386/boot/compressed/relocs.c b/arch/i386/boot/compressed/relocs.c index b0e21c3cee5..2d77ee728f9 100644 --- a/arch/i386/boot/compressed/relocs.c +++ b/arch/i386/boot/compressed/relocs.c @@ -31,6 +31,7 @@ static const char* safe_abs_relocs[] = { "__kernel_rt_sigreturn", "__kernel_sigreturn", "SYSENTER_RETURN", + "VDSO_NOTE_MASK", "xen_irq_disable_direct_reloc", "xen_save_fl_direct_reloc", }; diff --git a/arch/i386/kernel/vsyscall-note.S b/arch/i386/kernel/vsyscall-note.S index 271f16a8ca0..07c0daf7823 100644 --- a/arch/i386/kernel/vsyscall-note.S +++ b/arch/i386/kernel/vsyscall-note.S @@ -14,7 +14,6 @@ ELFNOTE_START(Linux, 0, "a") ELFNOTE_END #ifdef CONFIG_XEN - /* * Add a special note telling glibc's dynamic linker a fake hardware * flavor that it will use to choose the search path for libraries in the @@ -28,15 +27,19 @@ ELFNOTE_END * It should contain: * hwcap 1 nosegneg * to match the mapping of bit to name that we give here. + * + * At runtime, the fake hardware feature will be considered to be present + * if its bit is set in the mask word. So, we start with the mask 0, and + * at boot time we set VDSO_NOTE_NONEGSEG_BIT if running under Xen. */ -/* Bit used for the pseudo-hwcap for non-negative segments. We use - bit 1 to avoid bugs in some versions of glibc when bit 0 is - used; the choice is otherwise arbitrary. */ -#define VDSO_NOTE_NONEGSEG_BIT 1 +#include "../xen/vdso.h" /* Defines VDSO_NOTE_NONEGSEG_BIT. */ + .globl VDSO_NOTE_MASK ELFNOTE_START(GNU, 2, "a") - .long 1, 1<<VDSO_NOTE_NONEGSEG_BIT /* ncaps, mask */ + .long 1 /* ncaps */ +VDSO_NOTE_MASK: + .long 0 /* mask */ .byte VDSO_NOTE_NONEGSEG_BIT; .asciz "nosegneg" /* bit, name */ ELFNOTE_END #endif diff --git a/arch/i386/xen/events.c b/arch/i386/xen/events.c index 8904acc20f8..da1b173547a 100644 --- a/arch/i386/xen/events.c +++ b/arch/i386/xen/events.c @@ -31,6 +31,7 @@ #include <asm/irq.h> #include <asm/sync_bitops.h> #include <asm/xen/hypercall.h> +#include <asm/xen/hypervisor.h> #include <xen/events.h> #include <xen/interface/xen.h> diff --git a/arch/i386/xen/setup.c b/arch/i386/xen/setup.c index 2fe6eac510f..f84e7722664 100644 --- a/arch/i386/xen/setup.c +++ b/arch/i386/xen/setup.c @@ -19,6 +19,7 @@ #include <xen/features.h> #include "xen-ops.h" +#include "vdso.h" /* These are code, but not functions. Defined in entry.S */ extern const char xen_hypervisor_callback[]; @@ -55,6 +56,18 @@ static void xen_idle(void) } } +/* + * Set the bit indicating "nosegneg" library variants should be used. + */ +static void fiddle_vdso(void) +{ + extern u32 VDSO_NOTE_MASK; /* See ../kernel/vsyscall-note.S. */ + extern char vsyscall_int80_start; + u32 *mask = (u32 *) ((unsigned long) &VDSO_NOTE_MASK - VDSO_PRELINK + + &vsyscall_int80_start); + *mask |= 1 << VDSO_NOTE_NONEGSEG_BIT; +} + void __init xen_arch_setup(void) { struct physdev_set_iopl set_iopl; @@ -93,4 +106,6 @@ void __init xen_arch_setup(void) #endif paravirt_disable_iospace(); + + fiddle_vdso(); } diff --git a/arch/i386/xen/vdso.h b/arch/i386/xen/vdso.h new file mode 100644 index 00000000000..861fedfe523 --- /dev/null +++ b/arch/i386/xen/vdso.h @@ -0,0 +1,4 @@ +/* Bit used for the pseudo-hwcap for non-negative segments. We use + bit 1 to avoid bugs in some versions of glibc when bit 0 is + used; the choice is otherwise arbitrary. */ +#define VDSO_NOTE_NONEGSEG_BIT 1 diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig index a86e2e9a639..20a9c08e59c 100644 --- a/arch/m68k/Kconfig +++ b/arch/m68k/Kconfig @@ -37,6 +37,10 @@ config TIME_LOW_RES bool default y +config GENERIC_IOMAP + bool + default y + config ARCH_MAY_HAVE_PC_FDC bool depends on Q40 || (BROKEN && SUN3X) @@ -45,6 +49,9 @@ config ARCH_MAY_HAVE_PC_FDC config NO_IOPORT def_bool y +config NO_DMA + def_bool SUN3 + mainmenu "Linux/68k Kernel Configuration" source "init/Kconfig" diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c index cb8e7609df4..78df98f2029 100644 --- a/arch/m68k/apollo/config.c +++ b/arch/m68k/apollo/config.c @@ -148,8 +148,8 @@ void dn_serial_print (const char *str) } } -void config_apollo(void) { - +void __init config_apollo(void) +{ int i; dn_setup_model(); diff --git a/arch/m68k/apollo/dn_ints.c b/arch/m68k/apollo/dn_ints.c index 13bd41bed28..5d47f3aa381 100644 --- a/arch/m68k/apollo/dn_ints.c +++ b/arch/m68k/apollo/dn_ints.c @@ -37,7 +37,7 @@ static struct irq_controller apollo_irq_controller = { }; -void dn_init_IRQ(void) +void __init dn_init_IRQ(void) { m68k_setup_user_interrupt(VEC_USER + 96, 16, dn_process_int); m68k_setup_irq_controller(&apollo_irq_controller, IRQ_APOLLO, 16); diff --git a/arch/m68k/atari/atakeyb.c b/arch/m68k/atari/atakeyb.c index 1c29603b16b..2b5f64726a2 100644 --- a/arch/m68k/atari/atakeyb.c +++ b/arch/m68k/atari/atakeyb.c @@ -13,6 +13,7 @@ * enhanced by Bjoern Brauel and Roman Hodek */ +#include <linux/module.h> #include <linux/sched.h> #include <linux/kernel.h> #include <linux/interrupt.h> @@ -42,6 +43,9 @@ void (*atari_mouse_interrupt_hook) (char *); void (*atari_input_keyboard_interrupt_hook) (unsigned char, char); /* Hook for mouse inputdev driver */ void (*atari_input_mouse_interrupt_hook) (char *); +EXPORT_SYMBOL(atari_mouse_interrupt_hook); +EXPORT_SYMBOL(atari_input_keyboard_interrupt_hook); +EXPORT_SYMBOL(atari_input_mouse_interrupt_hook); /* variables for IKBD self test: */ @@ -429,6 +433,7 @@ void ikbd_mouse_rel_pos(void) ikbd_write(cmd, 1); } +EXPORT_SYMBOL(ikbd_mouse_rel_pos); /* Set absolute mouse position reporting */ void ikbd_mouse_abs_pos(int xmax, int ymax) @@ -453,6 +458,7 @@ void ikbd_mouse_thresh(int x, int y) ikbd_write(cmd, 3); } +EXPORT_SYMBOL(ikbd_mouse_thresh); /* Set mouse scale */ void ikbd_mouse_scale(int x, int y) @@ -495,6 +501,7 @@ void ikbd_mouse_y0_top(void) ikbd_write(cmd, 1); } +EXPORT_SYMBOL(ikbd_mouse_y0_top); /* Resume */ void ikbd_resume(void) @@ -511,6 +518,7 @@ void ikbd_mouse_disable(void) ikbd_write(cmd, 1); } +EXPORT_SYMBOL(ikbd_mouse_disable); /* Pause output */ void ikbd_pause(void) @@ -696,7 +704,6 @@ int __init atari_keyb_init(void) return 0; } - int atari_kbdrate(struct kbd_repeat *k) { if (k->delay > 0) { diff --git a/arch/m68k/bvme6000/config.c b/arch/m68k/bvme6000/config.c index 896ae3d3d91..9433a88a33c 100644 --- a/arch/m68k/bvme6000/config.c +++ b/arch/m68k/bvme6000/config.c @@ -97,7 +97,7 @@ static int bvme6000_get_hardware_list(char *buffer) * This function is called during kernel startup to initialize * the bvme6000 IRQ handling routines. */ -static void bvme6000_init_IRQ(void) +static void __init bvme6000_init_IRQ(void) { m68k_setup_user_interrupt(VEC_USER, 192, NULL); } diff --git a/arch/m68k/kernel/head.S b/arch/m68k/kernel/head.S index 05741f23356..faa6764f1d1 100644 --- a/arch/m68k/kernel/head.S +++ b/arch/m68k/kernel/head.S @@ -577,7 +577,7 @@ func_define putn,1 #endif .endm -.text +.section ".text.head","ax" ENTRY(_stext) /* * Version numbers of the bootinfo interface |