diff options
38 files changed, 150 insertions, 77 deletions
diff --git a/arch/x86/Makefile b/arch/x86/Makefile index ce6ad7e6a7d7..33f71b01fd22 100644 --- a/arch/x86/Makefile +++ b/arch/x86/Makefile | |||
| @@ -79,6 +79,7 @@ else | |||
| 79 | UTS_MACHINE := x86_64 | 79 | UTS_MACHINE := x86_64 |
| 80 | CHECKFLAGS += -D__x86_64__ -m64 | 80 | CHECKFLAGS += -D__x86_64__ -m64 |
| 81 | 81 | ||
| 82 | biarch := -m64 | ||
| 82 | KBUILD_AFLAGS += -m64 | 83 | KBUILD_AFLAGS += -m64 |
| 83 | KBUILD_CFLAGS += -m64 | 84 | KBUILD_CFLAGS += -m64 |
| 84 | 85 | ||
diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile index abb9eba61b50..dbe8dd2fe247 100644 --- a/arch/x86/boot/Makefile +++ b/arch/x86/boot/Makefile | |||
| @@ -71,7 +71,7 @@ $(obj)/vmlinux.bin: $(obj)/compressed/vmlinux FORCE | |||
| 71 | 71 | ||
| 72 | SETUP_OBJS = $(addprefix $(obj)/,$(setup-y)) | 72 | SETUP_OBJS = $(addprefix $(obj)/,$(setup-y)) |
| 73 | 73 | ||
| 74 | sed-voffset := -e 's/^\([0-9a-fA-F]*\) . \(_text\|_end\)$$/\#define VO_\2 0x\1/p' | 74 | sed-voffset := -e 's/^\([0-9a-fA-F]*\) [ABCDGRSTVW] \(_text\|_end\)$$/\#define VO_\2 0x\1/p' |
| 75 | 75 | ||
| 76 | quiet_cmd_voffset = VOFFSET $@ | 76 | quiet_cmd_voffset = VOFFSET $@ |
| 77 | cmd_voffset = $(NM) $< | sed -n $(sed-voffset) > $@ | 77 | cmd_voffset = $(NM) $< | sed -n $(sed-voffset) > $@ |
| @@ -80,7 +80,7 @@ targets += voffset.h | |||
| 80 | $(obj)/voffset.h: vmlinux FORCE | 80 | $(obj)/voffset.h: vmlinux FORCE |
| 81 | $(call if_changed,voffset) | 81 | $(call if_changed,voffset) |
| 82 | 82 | ||
| 83 | sed-zoffset := -e 's/^\([0-9a-fA-F]*\) . \(startup_32\|startup_64\|efi32_stub_entry\|efi64_stub_entry\|efi_pe_entry\|input_data\|_end\|z_.*\)$$/\#define ZO_\2 0x\1/p' | 83 | sed-zoffset := -e 's/^\([0-9a-fA-F]*\) [ABCDGRSTVW] \(startup_32\|startup_64\|efi32_stub_entry\|efi64_stub_entry\|efi_pe_entry\|input_data\|_end\|z_.*\)$$/\#define ZO_\2 0x\1/p' |
| 84 | 84 | ||
| 85 | quiet_cmd_zoffset = ZOFFSET $@ | 85 | quiet_cmd_zoffset = ZOFFSET $@ |
| 86 | cmd_zoffset = $(NM) $< | sed -n $(sed-zoffset) > $@ | 86 | cmd_zoffset = $(NM) $< | sed -n $(sed-zoffset) > $@ |
diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c index 17684615374b..57ab74df7eea 100644 --- a/arch/x86/boot/compressed/misc.c +++ b/arch/x86/boot/compressed/misc.c | |||
| @@ -354,7 +354,7 @@ static void parse_elf(void *output) | |||
| 354 | free(phdrs); | 354 | free(phdrs); |
| 355 | } | 355 | } |
| 356 | 356 | ||
| 357 | asmlinkage void *decompress_kernel(void *rmode, memptr heap, | 357 | asmlinkage __visible void *decompress_kernel(void *rmode, memptr heap, |
| 358 | unsigned char *input_data, | 358 | unsigned char *input_data, |
| 359 | unsigned long input_len, | 359 | unsigned long input_len, |
| 360 | unsigned char *output, | 360 | unsigned char *output, |
diff --git a/arch/x86/include/asm/hpet.h b/arch/x86/include/asm/hpet.h index b18df579c0e9..36f7125945e3 100644 --- a/arch/x86/include/asm/hpet.h +++ b/arch/x86/include/asm/hpet.h | |||
| @@ -63,6 +63,7 @@ | |||
| 63 | /* hpet memory map physical address */ | 63 | /* hpet memory map physical address */ |
| 64 | extern unsigned long hpet_address; | 64 | extern unsigned long hpet_address; |
| 65 | extern unsigned long force_hpet_address; | 65 | extern unsigned long force_hpet_address; |
| 66 | extern int boot_hpet_disable; | ||
| 66 | extern u8 hpet_blockid; | 67 | extern u8 hpet_blockid; |
| 67 | extern int hpet_force_user; | 68 | extern int hpet_force_user; |
| 68 | extern u8 hpet_msi_disable; | 69 | extern u8 hpet_msi_disable; |
diff --git a/arch/x86/include/uapi/asm/msr-index.h b/arch/x86/include/uapi/asm/msr-index.h index c827ace3121b..fcf2b3ae1bf0 100644 --- a/arch/x86/include/uapi/asm/msr-index.h +++ b/arch/x86/include/uapi/asm/msr-index.h | |||
| @@ -384,7 +384,7 @@ | |||
| 384 | #define MSR_IA32_MISC_ENABLE_MWAIT_BIT 18 | 384 | #define MSR_IA32_MISC_ENABLE_MWAIT_BIT 18 |
| 385 | #define MSR_IA32_MISC_ENABLE_MWAIT (1ULL << MSR_IA32_MISC_ENABLE_MWAIT_BIT) | 385 | #define MSR_IA32_MISC_ENABLE_MWAIT (1ULL << MSR_IA32_MISC_ENABLE_MWAIT_BIT) |
| 386 | #define MSR_IA32_MISC_ENABLE_LIMIT_CPUID_BIT 22 | 386 | #define MSR_IA32_MISC_ENABLE_LIMIT_CPUID_BIT 22 |
| 387 | #define MSR_IA32_MISC_ENABLE_LIMIT_CPUID (1ULL << MSR_IA32_MISC_ENABLE_LIMIT_CPUID_BIT); | 387 | #define MSR_IA32_MISC_ENABLE_LIMIT_CPUID (1ULL << MSR_IA32_MISC_ENABLE_LIMIT_CPUID_BIT) |
| 388 | #define MSR_IA32_MISC_ENABLE_XTPR_DISABLE_BIT 23 | 388 | #define MSR_IA32_MISC_ENABLE_XTPR_DISABLE_BIT 23 |
| 389 | #define MSR_IA32_MISC_ENABLE_XTPR_DISABLE (1ULL << MSR_IA32_MISC_ENABLE_XTPR_DISABLE_BIT) | 389 | #define MSR_IA32_MISC_ENABLE_XTPR_DISABLE (1ULL << MSR_IA32_MISC_ENABLE_XTPR_DISABLE_BIT) |
| 390 | #define MSR_IA32_MISC_ENABLE_XD_DISABLE_BIT 34 | 390 | #define MSR_IA32_MISC_ENABLE_XD_DISABLE_BIT 34 |
diff --git a/arch/x86/kernel/acpi/sleep.c b/arch/x86/kernel/acpi/sleep.c index 3a2ae4c88948..31368207837c 100644 --- a/arch/x86/kernel/acpi/sleep.c +++ b/arch/x86/kernel/acpi/sleep.c | |||
| @@ -31,7 +31,7 @@ static char temp_stack[4096]; | |||
| 31 | * | 31 | * |
| 32 | * Wrapper around acpi_enter_sleep_state() to be called by assmebly. | 32 | * Wrapper around acpi_enter_sleep_state() to be called by assmebly. |
| 33 | */ | 33 | */ |
| 34 | acpi_status asmlinkage x86_acpi_enter_sleep_state(u8 state) | 34 | acpi_status asmlinkage __visible x86_acpi_enter_sleep_state(u8 state) |
| 35 | { | 35 | { |
| 36 | return acpi_enter_sleep_state(state); | 36 | return acpi_enter_sleep_state(state); |
| 37 | } | 37 | } |
diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c index d23aa82e7a7b..992060e09897 100644 --- a/arch/x86/kernel/apic/io_apic.c +++ b/arch/x86/kernel/apic/io_apic.c | |||
| @@ -2189,7 +2189,7 @@ void send_cleanup_vector(struct irq_cfg *cfg) | |||
| 2189 | cfg->move_in_progress = 0; | 2189 | cfg->move_in_progress = 0; |
| 2190 | } | 2190 | } |
| 2191 | 2191 | ||
| 2192 | asmlinkage void smp_irq_move_cleanup_interrupt(void) | 2192 | asmlinkage __visible void smp_irq_move_cleanup_interrupt(void) |
| 2193 | { | 2193 | { |
| 2194 | unsigned vector, me; | 2194 | unsigned vector, me; |
| 2195 | 2195 | ||
diff --git a/arch/x86/kernel/cpu/mcheck/therm_throt.c b/arch/x86/kernel/cpu/mcheck/therm_throt.c index d921b7ee6595..36a1bb6d1ee0 100644 --- a/arch/x86/kernel/cpu/mcheck/therm_throt.c +++ b/arch/x86/kernel/cpu/mcheck/therm_throt.c | |||
| @@ -429,14 +429,14 @@ static inline void __smp_thermal_interrupt(void) | |||
| 429 | smp_thermal_vector(); | 429 | smp_thermal_vector(); |
| 430 | } | 430 | } |
| 431 | 431 | ||
| 432 | asmlinkage void smp_thermal_interrupt(struct pt_regs *regs) | 432 | asmlinkage __visible void smp_thermal_interrupt(struct pt_regs *regs) |
| 433 | { | 433 | { |
| 434 | entering_irq(); | 434 | entering_irq(); |
| 435 | __smp_thermal_interrupt(); | 435 | __smp_thermal_interrupt(); |
| 436 | exiting_ack_irq(); | 436 | exiting_ack_irq(); |
| 437 | } | 437 | } |
| 438 | 438 | ||
| 439 | asmlinkage void smp_trace_thermal_interrupt(struct pt_regs *regs) | 439 | asmlinkage __visible void smp_trace_thermal_interrupt(struct pt_regs *regs) |
| 440 | { | 440 | { |
| 441 | entering_irq(); | 441 | entering_irq(); |
| 442 | trace_thermal_apic_entry(THERMAL_APIC_VECTOR); | 442 | trace_thermal_apic_entry(THERMAL_APIC_VECTOR); |
diff --git a/arch/x86/kernel/cpu/mcheck/threshold.c b/arch/x86/kernel/cpu/mcheck/threshold.c index fe6b1c86645b..7245980186ee 100644 --- a/arch/x86/kernel/cpu/mcheck/threshold.c +++ b/arch/x86/kernel/cpu/mcheck/threshold.c | |||
| @@ -24,14 +24,14 @@ static inline void __smp_threshold_interrupt(void) | |||
| 24 | mce_threshold_vector(); | 24 | mce_threshold_vector(); |
| 25 | } | 25 | } |
| 26 | 26 | ||
| 27 | asmlinkage void smp_threshold_interrupt(void) | 27 | asmlinkage __visible void smp_threshold_interrupt(void) |
| 28 | { | 28 | { |
| 29 | entering_irq(); | 29 | entering_irq(); |
| 30 | __smp_threshold_interrupt(); | 30 | __smp_threshold_interrupt(); |
| 31 | exiting_ack_irq(); | 31 | exiting_ack_irq(); |
| 32 | } | 32 | } |
| 33 | 33 | ||
| 34 | asmlinkage void smp_trace_threshold_interrupt(void) | 34 | asmlinkage __visible void smp_trace_threshold_interrupt(void) |
| 35 | { | 35 | { |
| 36 | entering_irq(); | 36 | entering_irq(); |
| 37 | trace_threshold_apic_entry(THRESHOLD_APIC_VECTOR); | 37 | trace_threshold_apic_entry(THRESHOLD_APIC_VECTOR); |
diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c index 6e2537c32190..6cda0baeac9d 100644 --- a/arch/x86/kernel/early-quirks.c +++ b/arch/x86/kernel/early-quirks.c | |||
| @@ -17,6 +17,7 @@ | |||
| 17 | #include <asm/dma.h> | 17 | #include <asm/dma.h> |
| 18 | #include <asm/io_apic.h> | 18 | #include <asm/io_apic.h> |
| 19 | #include <asm/apic.h> | 19 | #include <asm/apic.h> |
| 20 | #include <asm/hpet.h> | ||
| 20 | #include <asm/iommu.h> | 21 | #include <asm/iommu.h> |
| 21 | #include <asm/gart.h> | 22 | #include <asm/gart.h> |
| 22 | #include <asm/irq_remapping.h> | 23 | #include <asm/irq_remapping.h> |
| @@ -530,6 +531,15 @@ static void __init intel_graphics_stolen(int num, int slot, int func) | |||
| 530 | } | 531 | } |
| 531 | } | 532 | } |
| 532 | 533 | ||
| 534 | static void __init force_disable_hpet(int num, int slot, int func) | ||
| 535 | { | ||
| 536 | #ifdef CONFIG_HPET_TIMER | ||
| 537 | boot_hpet_disable = 1; | ||
| 538 | pr_info("x86/hpet: Will disable the HPET for this platform because it's not reliable\n"); | ||
| 539 | #endif | ||
| 540 | } | ||
| 541 | |||
| 542 | |||
| 533 | #define QFLAG_APPLY_ONCE 0x1 | 543 | #define QFLAG_APPLY_ONCE 0x1 |
| 534 | #define QFLAG_APPLIED 0x2 | 544 | #define QFLAG_APPLIED 0x2 |
| 535 | #define QFLAG_DONE (QFLAG_APPLY_ONCE|QFLAG_APPLIED) | 545 | #define QFLAG_DONE (QFLAG_APPLY_ONCE|QFLAG_APPLIED) |
| @@ -567,6 +577,12 @@ static struct chipset early_qrk[] __initdata = { | |||
| 567 | PCI_BASE_CLASS_BRIDGE, 0, intel_remapping_check }, | 577 | PCI_BASE_CLASS_BRIDGE, 0, intel_remapping_check }, |
| 568 | { PCI_VENDOR_ID_INTEL, PCI_ANY_ID, PCI_CLASS_DISPLAY_VGA, PCI_ANY_ID, | 578 | { PCI_VENDOR_ID_INTEL, PCI_ANY_ID, PCI_CLASS_DISPLAY_VGA, PCI_ANY_ID, |
| 569 | QFLAG_APPLY_ONCE, intel_graphics_stolen }, | 579 | QFLAG_APPLY_ONCE, intel_graphics_stolen }, |
| 580 | /* | ||
| 581 | * HPET on current version of Baytrail platform has accuracy | ||
| 582 | * problems, disable it for now: | ||
| 583 | */ | ||
| 584 | { PCI_VENDOR_ID_INTEL, 0x0f00, | ||
| 585 | PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet}, | ||
| 570 | {} | 586 | {} |
| 571 | }; | 587 | }; |
| 572 | 588 | ||
diff --git a/arch/x86/kernel/head32.c b/arch/x86/kernel/head32.c index c61a14a4a310..d6c1b9836995 100644 --- a/arch/x86/kernel/head32.c +++ b/arch/x86/kernel/head32.c | |||
| @@ -29,7 +29,7 @@ static void __init i386_default_early_setup(void) | |||
| 29 | reserve_ebda_region(); | 29 | reserve_ebda_region(); |
| 30 | } | 30 | } |
| 31 | 31 | ||
| 32 | asmlinkage void __init i386_start_kernel(void) | 32 | asmlinkage __visible void __init i386_start_kernel(void) |
| 33 | { | 33 | { |
| 34 | sanitize_boot_params(&boot_params); | 34 | sanitize_boot_params(&boot_params); |
| 35 | 35 | ||
diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c index 85126ccbdf6b..068054f4bf20 100644 --- a/arch/x86/kernel/head64.c +++ b/arch/x86/kernel/head64.c | |||
| @@ -137,7 +137,7 @@ static void __init copy_bootdata(char *real_mode_data) | |||
| 137 | } | 137 | } |
| 138 | } | 138 | } |
| 139 | 139 | ||
| 140 | asmlinkage void __init x86_64_start_kernel(char * real_mode_data) | 140 | asmlinkage __visible void __init x86_64_start_kernel(char * real_mode_data) |
| 141 | { | 141 | { |
| 142 | int i; | 142 | int i; |
| 143 | 143 | ||
diff --git a/arch/x86/kernel/hpet.c b/arch/x86/kernel/hpet.c index 8d80ae011603..4177bfbc80b0 100644 --- a/arch/x86/kernel/hpet.c +++ b/arch/x86/kernel/hpet.c | |||
| @@ -88,7 +88,7 @@ static inline void hpet_clear_mapping(void) | |||
| 88 | /* | 88 | /* |
| 89 | * HPET command line enable / disable | 89 | * HPET command line enable / disable |
| 90 | */ | 90 | */ |
| 91 | static int boot_hpet_disable; | 91 | int boot_hpet_disable; |
| 92 | int hpet_force_user; | 92 | int hpet_force_user; |
| 93 | static int hpet_verbose; | 93 | static int hpet_verbose; |
| 94 | 94 | ||
diff --git a/arch/x86/kernel/process_64.c b/arch/x86/kernel/process_64.c index 9c0280f93d05..898d077617a9 100644 --- a/arch/x86/kernel/process_64.c +++ b/arch/x86/kernel/process_64.c | |||
| @@ -52,7 +52,7 @@ | |||
| 52 | 52 | ||
| 53 | asmlinkage extern void ret_from_fork(void); | 53 | asmlinkage extern void ret_from_fork(void); |
| 54 | 54 | ||
| 55 | asmlinkage DEFINE_PER_CPU(unsigned long, old_rsp); | 55 | __visible DEFINE_PER_CPU(unsigned long, old_rsp); |
| 56 | 56 | ||
| 57 | /* Prints also some state that isn't saved in the pt_regs */ | 57 | /* Prints also some state that isn't saved in the pt_regs */ |
| 58 | void __show_regs(struct pt_regs *regs, int all) | 58 | void __show_regs(struct pt_regs *regs, int all) |
diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c index 3399d3a99730..52b1157c53eb 100644 --- a/arch/x86/kernel/reboot.c +++ b/arch/x86/kernel/reboot.c | |||
| @@ -191,6 +191,16 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = { | |||
| 191 | }, | 191 | }, |
| 192 | }, | 192 | }, |
| 193 | 193 | ||
| 194 | /* Certec */ | ||
| 195 | { /* Handle problems with rebooting on Certec BPC600 */ | ||
| 196 | .callback = set_pci_reboot, | ||
| 197 | .ident = "Certec BPC600", | ||
| 198 | .matches = { | ||
| 199 | DMI_MATCH(DMI_SYS_VENDOR, "Certec"), | ||
| 200 | DMI_MATCH(DMI_PRODUCT_NAME, "BPC600"), | ||
| 201 | }, | ||
| 202 | }, | ||
| 203 | |||
| 194 | /* Dell */ | 204 | /* Dell */ |
| 195 | { /* Handle problems with rebooting on Dell DXP061 */ | 205 | { /* Handle problems with rebooting on Dell DXP061 */ |
| 196 | .callback = set_bios_reboot, | 206 | .callback = set_bios_reboot, |
diff --git a/arch/x86/kernel/smp.c b/arch/x86/kernel/smp.c index 7c3a5a61f2e4..be8e1bde07aa 100644 --- a/arch/x86/kernel/smp.c +++ b/arch/x86/kernel/smp.c | |||
| @@ -168,7 +168,7 @@ static int smp_stop_nmi_callback(unsigned int val, struct pt_regs *regs) | |||
| 168 | * this function calls the 'stop' function on all other CPUs in the system. | 168 | * this function calls the 'stop' function on all other CPUs in the system. |
| 169 | */ | 169 | */ |
| 170 | 170 | ||
| 171 | asmlinkage void smp_reboot_interrupt(void) | 171 | asmlinkage __visible void smp_reboot_interrupt(void) |
| 172 | { | 172 | { |
| 173 | ack_APIC_irq(); | 173 | ack_APIC_irq(); |
| 174 | irq_enter(); | 174 | irq_enter(); |
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index 57409f6b8c62..f73b5d435bdc 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c | |||
| @@ -357,7 +357,7 @@ exit: | |||
| 357 | * for scheduling or signal handling. The actual stack switch is done in | 357 | * for scheduling or signal handling. The actual stack switch is done in |
| 358 | * entry.S | 358 | * entry.S |
| 359 | */ | 359 | */ |
| 360 | asmlinkage __kprobes struct pt_regs *sync_regs(struct pt_regs *eregs) | 360 | asmlinkage __visible __kprobes struct pt_regs *sync_regs(struct pt_regs *eregs) |
| 361 | { | 361 | { |
| 362 | struct pt_regs *regs = eregs; | 362 | struct pt_regs *regs = eregs; |
| 363 | /* Did already sync */ | 363 | /* Did already sync */ |
| @@ -601,11 +601,11 @@ do_spurious_interrupt_bug(struct pt_regs *regs, long error_code) | |||
| 601 | #endif | 601 | #endif |
| 602 | } | 602 | } |
| 603 | 603 | ||
| 604 | asmlinkage void __attribute__((weak)) smp_thermal_interrupt(void) | 604 | asmlinkage __visible void __attribute__((weak)) smp_thermal_interrupt(void) |
| 605 | { | 605 | { |
| 606 | } | 606 | } |
| 607 | 607 | ||
| 608 | asmlinkage void __attribute__((weak)) smp_threshold_interrupt(void) | 608 | asmlinkage __visible void __attribute__((weak)) smp_threshold_interrupt(void) |
| 609 | { | 609 | { |
| 610 | } | 610 | } |
| 611 | 611 | ||
diff --git a/arch/x86/kernel/vsmp_64.c b/arch/x86/kernel/vsmp_64.c index 5edc34b5b951..b99b9ad8540c 100644 --- a/arch/x86/kernel/vsmp_64.c +++ b/arch/x86/kernel/vsmp_64.c | |||
| @@ -36,7 +36,7 @@ static int irq_routing_comply = 1; | |||
| 36 | * and vice versa. | 36 | * and vice versa. |
| 37 | */ | 37 | */ |
| 38 | 38 | ||
| 39 | asmlinkage unsigned long vsmp_save_fl(void) | 39 | asmlinkage __visible unsigned long vsmp_save_fl(void) |
| 40 | { | 40 | { |
| 41 | unsigned long flags = native_save_fl(); | 41 | unsigned long flags = native_save_fl(); |
| 42 | 42 | ||
| @@ -56,7 +56,7 @@ __visible void vsmp_restore_fl(unsigned long flags) | |||
| 56 | } | 56 | } |
| 57 | PV_CALLEE_SAVE_REGS_THUNK(vsmp_restore_fl); | 57 | PV_CALLEE_SAVE_REGS_THUNK(vsmp_restore_fl); |
| 58 | 58 | ||
| 59 | asmlinkage void vsmp_irq_disable(void) | 59 | asmlinkage __visible void vsmp_irq_disable(void) |
| 60 | { | 60 | { |
| 61 | unsigned long flags = native_save_fl(); | 61 | unsigned long flags = native_save_fl(); |
| 62 | 62 | ||
| @@ -64,7 +64,7 @@ asmlinkage void vsmp_irq_disable(void) | |||
| 64 | } | 64 | } |
| 65 | PV_CALLEE_SAVE_REGS_THUNK(vsmp_irq_disable); | 65 | PV_CALLEE_SAVE_REGS_THUNK(vsmp_irq_disable); |
| 66 | 66 | ||
| 67 | asmlinkage void vsmp_irq_enable(void) | 67 | asmlinkage __visible void vsmp_irq_enable(void) |
| 68 | { | 68 | { |
| 69 | unsigned long flags = native_save_fl(); | 69 | unsigned long flags = native_save_fl(); |
| 70 | 70 | ||
diff --git a/arch/x86/kernel/vsyscall_gtod.c b/arch/x86/kernel/vsyscall_gtod.c index f9c6e56e14b5..9531fbb123ba 100644 --- a/arch/x86/kernel/vsyscall_gtod.c +++ b/arch/x86/kernel/vsyscall_gtod.c | |||
| @@ -43,7 +43,7 @@ void update_vsyscall(struct timekeeper *tk) | |||
| 43 | vdata->monotonic_time_sec = tk->xtime_sec | 43 | vdata->monotonic_time_sec = tk->xtime_sec |
| 44 | + tk->wall_to_monotonic.tv_sec; | 44 | + tk->wall_to_monotonic.tv_sec; |
| 45 | vdata->monotonic_time_snsec = tk->xtime_nsec | 45 | vdata->monotonic_time_snsec = tk->xtime_nsec |
| 46 | + (tk->wall_to_monotonic.tv_nsec | 46 | + ((u64)tk->wall_to_monotonic.tv_nsec |
| 47 | << tk->shift); | 47 | << tk->shift); |
| 48 | while (vdata->monotonic_time_snsec >= | 48 | while (vdata->monotonic_time_snsec >= |
| 49 | (((u64)NSEC_PER_SEC) << tk->shift)) { | 49 | (((u64)NSEC_PER_SEC) << tk->shift)) { |
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 8b8fc0b792ba..b6c0bacca9bd 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c | |||
| @@ -280,7 +280,7 @@ int kvm_set_apic_base(struct kvm_vcpu *vcpu, struct msr_data *msr_info) | |||
| 280 | } | 280 | } |
| 281 | EXPORT_SYMBOL_GPL(kvm_set_apic_base); | 281 | EXPORT_SYMBOL_GPL(kvm_set_apic_base); |
| 282 | 282 | ||
| 283 | asmlinkage void kvm_spurious_fault(void) | 283 | asmlinkage __visible void kvm_spurious_fault(void) |
| 284 | { | 284 | { |
| 285 | /* Fault while not rebooting. We want the trace. */ | 285 | /* Fault while not rebooting. We want the trace. */ |
| 286 | BUG(); | 286 | BUG(); |
diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c index ad1fb5f53925..aae94132bc24 100644 --- a/arch/x86/lguest/boot.c +++ b/arch/x86/lguest/boot.c | |||
| @@ -233,13 +233,13 @@ static void lguest_end_context_switch(struct task_struct *next) | |||
| 233 | * flags word contains all kind of stuff, but in practice Linux only cares | 233 | * flags word contains all kind of stuff, but in practice Linux only cares |
| 234 | * about the interrupt flag. Our "save_flags()" just returns that. | 234 | * about the interrupt flag. Our "save_flags()" just returns that. |
| 235 | */ | 235 | */ |
| 236 | asmlinkage unsigned long lguest_save_fl(void) | 236 | asmlinkage __visible unsigned long lguest_save_fl(void) |
| 237 | { | 237 | { |
| 238 | return lguest_data.irq_enabled; | 238 | return lguest_data.irq_enabled; |
| 239 | } | 239 | } |
| 240 | 240 | ||
| 241 | /* Interrupts go off... */ | 241 | /* Interrupts go off... */ |
| 242 | asmlinkage void lguest_irq_disable(void) | 242 | asmlinkage __visible void lguest_irq_disable(void) |
| 243 | { | 243 | { |
| 244 | lguest_data.irq_enabled = 0; | 244 | lguest_data.irq_enabled = 0; |
| 245 | } | 245 | } |
diff --git a/arch/x86/lib/msr.c b/arch/x86/lib/msr.c index db9db446b71a..43623739c7cf 100644 --- a/arch/x86/lib/msr.c +++ b/arch/x86/lib/msr.c | |||
| @@ -76,7 +76,7 @@ static inline int __flip_bit(u32 msr, u8 bit, bool set) | |||
| 76 | if (m1.q == m.q) | 76 | if (m1.q == m.q) |
| 77 | return 0; | 77 | return 0; |
| 78 | 78 | ||
| 79 | err = msr_write(msr, &m); | 79 | err = msr_write(msr, &m1); |
| 80 | if (err) | 80 | if (err) |
| 81 | return err; | 81 | return err; |
| 82 | 82 | ||
diff --git a/arch/x86/math-emu/errors.c b/arch/x86/math-emu/errors.c index a5449089cd9f..9e6545f269e5 100644 --- a/arch/x86/math-emu/errors.c +++ b/arch/x86/math-emu/errors.c | |||
| @@ -302,7 +302,7 @@ static struct { | |||
| 302 | 0x242 in div_Xsig.S | 302 | 0x242 in div_Xsig.S |
| 303 | */ | 303 | */ |
| 304 | 304 | ||
| 305 | asmlinkage void FPU_exception(int n) | 305 | asmlinkage __visible void FPU_exception(int n) |
| 306 | { | 306 | { |
| 307 | int i, int_type; | 307 | int i, int_type; |
| 308 | 308 | ||
| @@ -492,7 +492,7 @@ int real_2op_NaN(FPU_REG const *b, u_char tagb, | |||
| 492 | 492 | ||
| 493 | /* Invalid arith operation on Valid registers */ | 493 | /* Invalid arith operation on Valid registers */ |
| 494 | /* Returns < 0 if the exception is unmasked */ | 494 | /* Returns < 0 if the exception is unmasked */ |
| 495 | asmlinkage int arith_invalid(int deststnr) | 495 | asmlinkage __visible int arith_invalid(int deststnr) |
| 496 | { | 496 | { |
| 497 | 497 | ||
| 498 | EXCEPTION(EX_Invalid); | 498 | EXCEPTION(EX_Invalid); |
| @@ -507,7 +507,7 @@ asmlinkage int arith_invalid(int deststnr) | |||
| 507 | } | 507 | } |
| 508 | 508 | ||
| 509 | /* Divide a finite number by zero */ | 509 | /* Divide a finite number by zero */ |
| 510 | asmlinkage int FPU_divide_by_zero(int deststnr, u_char sign) | 510 | asmlinkage __visible int FPU_divide_by_zero(int deststnr, u_char sign) |
| 511 | { | 511 | { |
| 512 | FPU_REG *dest = &st(deststnr); | 512 | FPU_REG *dest = &st(deststnr); |
| 513 | int tag = TAG_Valid; | 513 | int tag = TAG_Valid; |
| @@ -539,7 +539,7 @@ int set_precision_flag(int flags) | |||
| 539 | } | 539 | } |
| 540 | 540 | ||
| 541 | /* This may be called often, so keep it lean */ | 541 | /* This may be called often, so keep it lean */ |
| 542 | asmlinkage void set_precision_flag_up(void) | 542 | asmlinkage __visible void set_precision_flag_up(void) |
| 543 | { | 543 | { |
| 544 | if (control_word & CW_Precision) | 544 | if (control_word & CW_Precision) |
| 545 | partial_status |= (SW_Precision | SW_C1); /* The masked response */ | 545 | partial_status |= (SW_Precision | SW_C1); /* The masked response */ |
| @@ -548,7 +548,7 @@ asmlinkage void set_precision_flag_up(void) | |||
| 548 | } | 548 | } |
| 549 | 549 | ||
| 550 | /* This may be called often, so keep it lean */ | 550 | /* This may be called often, so keep it lean */ |
| 551 | asmlinkage void set_precision_flag_down(void) | 551 | asmlinkage __visible void set_precision_flag_down(void) |
| 552 | { | 552 | { |
| 553 | if (control_word & CW_Precision) { /* The masked response */ | 553 | if (control_word & CW_Precision) { /* The masked response */ |
| 554 | partial_status &= ~SW_C1; | 554 | partial_status &= ~SW_C1; |
| @@ -557,7 +557,7 @@ asmlinkage void set_precision_flag_down(void) | |||
| 557 | EXCEPTION(EX_Precision); | 557 | EXCEPTION(EX_Precision); |
| 558 | } | 558 | } |
| 559 | 559 | ||
| 560 | asmlinkage int denormal_operand(void) | 560 | asmlinkage __visible int denormal_operand(void) |
| 561 | { | 561 | { |
| 562 | if (control_word & CW_Denormal) { /* The masked response */ | 562 | if (control_word & CW_Denormal) { /* The masked response */ |
| 563 | partial_status |= SW_Denorm_Op; | 563 | partial_status |= SW_Denorm_Op; |
| @@ -568,7 +568,7 @@ asmlinkage int denormal_operand(void) | |||
| 568 | } | 568 | } |
| 569 | } | 569 | } |
| 570 | 570 | ||
| 571 | asmlinkage int arith_overflow(FPU_REG *dest) | 571 | asmlinkage __visible int arith_overflow(FPU_REG *dest) |
| 572 | { | 572 | { |
| 573 | int tag = TAG_Valid; | 573 | int tag = TAG_Valid; |
| 574 | 574 | ||
| @@ -596,7 +596,7 @@ asmlinkage int arith_overflow(FPU_REG *dest) | |||
| 596 | 596 | ||
| 597 | } | 597 | } |
| 598 | 598 | ||
| 599 | asmlinkage int arith_underflow(FPU_REG *dest) | 599 | asmlinkage __visible int arith_underflow(FPU_REG *dest) |
| 600 | { | 600 | { |
| 601 | int tag = TAG_Valid; | 601 | int tag = TAG_Valid; |
| 602 | 602 | ||
diff --git a/arch/x86/platform/efi/early_printk.c b/arch/x86/platform/efi/early_printk.c index 81b506d5befd..524142117296 100644 --- a/arch/x86/platform/efi/early_printk.c +++ b/arch/x86/platform/efi/early_printk.c | |||
| @@ -14,48 +14,92 @@ | |||
| 14 | 14 | ||
| 15 | static const struct font_desc *font; | 15 | static const struct font_desc *font; |
| 16 | static u32 efi_x, efi_y; | 16 | static u32 efi_x, efi_y; |
| 17 | static void *efi_fb; | ||
| 18 | static bool early_efi_keep; | ||
| 17 | 19 | ||
| 18 | static __init void early_efi_clear_scanline(unsigned int y) | 20 | /* |
| 21 | * efi earlyprintk need use early_ioremap to map the framebuffer. | ||
| 22 | * But early_ioremap is not usable for earlyprintk=efi,keep, ioremap should | ||
| 23 | * be used instead. ioremap will be available after paging_init() which is | ||
| 24 | * earlier than initcall callbacks. Thus adding this early initcall function | ||
| 25 | * early_efi_map_fb to map the whole efi framebuffer. | ||
| 26 | */ | ||
| 27 | static __init int early_efi_map_fb(void) | ||
| 19 | { | 28 | { |
| 20 | unsigned long base, *dst; | 29 | unsigned long base, size; |
| 21 | u16 len; | 30 | |
| 31 | if (!early_efi_keep) | ||
| 32 | return 0; | ||
| 22 | 33 | ||
| 23 | base = boot_params.screen_info.lfb_base; | 34 | base = boot_params.screen_info.lfb_base; |
| 24 | len = boot_params.screen_info.lfb_linelength; | 35 | size = boot_params.screen_info.lfb_size; |
| 36 | efi_fb = ioremap(base, size); | ||
| 37 | |||
| 38 | return efi_fb ? 0 : -ENOMEM; | ||
| 39 | } | ||
| 40 | early_initcall(early_efi_map_fb); | ||
| 41 | |||
| 42 | /* | ||
| 43 | * early_efi_map maps efi framebuffer region [start, start + len -1] | ||
| 44 | * In case earlyprintk=efi,keep we have the whole framebuffer mapped already | ||
| 45 | * so just return the offset efi_fb + start. | ||
| 46 | */ | ||
| 47 | static __init_refok void *early_efi_map(unsigned long start, unsigned long len) | ||
| 48 | { | ||
| 49 | unsigned long base; | ||
| 50 | |||
| 51 | base = boot_params.screen_info.lfb_base; | ||
| 52 | |||
| 53 | if (efi_fb) | ||
| 54 | return (efi_fb + start); | ||
| 55 | else | ||
| 56 | return early_ioremap(base + start, len); | ||
| 57 | } | ||
| 25 | 58 | ||
| 26 | dst = early_ioremap(base + y*len, len); | 59 | static __init_refok void early_efi_unmap(void *addr, unsigned long len) |
| 60 | { | ||
| 61 | if (!efi_fb) | ||
| 62 | early_iounmap(addr, len); | ||
| 63 | } | ||
| 64 | |||
| 65 | static void early_efi_clear_scanline(unsigned int y) | ||
| 66 | { | ||
| 67 | unsigned long *dst; | ||
| 68 | u16 len; | ||
| 69 | |||
| 70 | len = boot_params.screen_info.lfb_linelength; | ||
| 71 | dst = early_efi_map(y*len, len); | ||
| 27 | if (!dst) | 72 | if (!dst) |
| 28 | return; | 73 | return; |
| 29 | 74 | ||
| 30 | memset(dst, 0, len); | 75 | memset(dst, 0, len); |
| 31 | early_iounmap(dst, len); | 76 | early_efi_unmap(dst, len); |
| 32 | } | 77 | } |
| 33 | 78 | ||
| 34 | static __init void early_efi_scroll_up(void) | 79 | static void early_efi_scroll_up(void) |
| 35 | { | 80 | { |
| 36 | unsigned long base, *dst, *src; | 81 | unsigned long *dst, *src; |
| 37 | u16 len; | 82 | u16 len; |
| 38 | u32 i, height; | 83 | u32 i, height; |
| 39 | 84 | ||
| 40 | base = boot_params.screen_info.lfb_base; | ||
| 41 | len = boot_params.screen_info.lfb_linelength; | 85 | len = boot_params.screen_info.lfb_linelength; |
| 42 | height = boot_params.screen_info.lfb_height; | 86 | height = boot_params.screen_info.lfb_height; |
| 43 | 87 | ||
| 44 | for (i = 0; i < height - font->height; i++) { | 88 | for (i = 0; i < height - font->height; i++) { |
| 45 | dst = early_ioremap(base + i*len, len); | 89 | dst = early_efi_map(i*len, len); |
| 46 | if (!dst) | 90 | if (!dst) |
| 47 | return; | 91 | return; |
| 48 | 92 | ||
| 49 | src = early_ioremap(base + (i + font->height) * len, len); | 93 | src = early_efi_map((i + font->height) * len, len); |
| 50 | if (!src) { | 94 | if (!src) { |
| 51 | early_iounmap(dst, len); | 95 | early_efi_unmap(dst, len); |
| 52 | return; | 96 | return; |
| 53 | } | 97 | } |
| 54 | 98 | ||
| 55 | memmove(dst, src, len); | 99 | memmove(dst, src, len); |
| 56 | 100 | ||
| 57 | early_iounmap(src, len); | 101 | early_efi_unmap(src, len); |
| 58 | early_iounmap(dst, len); | 102 | early_efi_unmap(dst, len); |
| 59 | } | 103 | } |
| 60 | } | 104 | } |
| 61 | 105 | ||
| @@ -79,16 +123,14 @@ static void early_efi_write_char(u32 *dst, unsigned char c, unsigned int h) | |||
| 79 | } | 123 | } |
| 80 | } | 124 | } |
| 81 | 125 | ||
| 82 | static __init void | 126 | static void |
| 83 | early_efi_write(struct console *con, const char *str, unsigned int num) | 127 | early_efi_write(struct console *con, const char *str, unsigned int num) |
| 84 | { | 128 | { |
| 85 | struct screen_info *si; | 129 | struct screen_info *si; |
| 86 | unsigned long base; | ||
| 87 | unsigned int len; | 130 | unsigned int len; |
| 88 | const char *s; | 131 | const char *s; |
| 89 | void *dst; | 132 | void *dst; |
| 90 | 133 | ||
| 91 | base = boot_params.screen_info.lfb_base; | ||
| 92 | si = &boot_params.screen_info; | 134 | si = &boot_params.screen_info; |
| 93 | len = si->lfb_linelength; | 135 | len = si->lfb_linelength; |
| 94 | 136 | ||
| @@ -109,7 +151,7 @@ early_efi_write(struct console *con, const char *str, unsigned int num) | |||
| 109 | for (h = 0; h < font->height; h++) { | 151 | for (h = 0; h < font->height; h++) { |
| 110 | unsigned int n, x; | 152 | unsigned int n, x; |
| 111 | 153 | ||
| 112 | dst = early_ioremap(base + (efi_y + h) * len, len); | 154 | dst = early_efi_map((efi_y + h) * len, len); |
| 113 | if (!dst) | 155 | if (!dst) |
| 114 | return; | 156 | return; |
| 115 | 157 | ||
| @@ -123,7 +165,7 @@ early_efi_write(struct console *con, const char *str, unsigned int num) | |||
| 123 | s++; | 165 | s++; |
| 124 | } | 166 | } |
| 125 | 167 | ||
| 126 | early_iounmap(dst, len); | 168 | early_efi_unmap(dst, len); |
| 127 | } | 169 | } |
| 128 | 170 | ||
| 129 | num -= count; | 171 | num -= count; |
| @@ -179,6 +221,9 @@ static __init int early_efi_setup(struct console *con, char *options) | |||
| 179 | for (i = 0; i < (yres - efi_y) / font->height; i++) | 221 | for (i = 0; i < (yres - efi_y) / font->height; i++) |
| 180 | early_efi_scroll_up(); | 222 | early_efi_scroll_up(); |
| 181 | 223 | ||
| 224 | /* early_console_register will unset CON_BOOT in case ,keep */ | ||
| 225 | if (!(con->flags & CON_BOOT)) | ||
| 226 | early_efi_keep = true; | ||
| 182 | return 0; | 227 | return 0; |
| 183 | } | 228 | } |
| 184 | 229 | ||
diff --git a/arch/x86/platform/olpc/olpc-xo1-pm.c b/arch/x86/platform/olpc/olpc-xo1-pm.c index ff0174dda810..a9acde72d4ed 100644 --- a/arch/x86/platform/olpc/olpc-xo1-pm.c +++ b/arch/x86/platform/olpc/olpc-xo1-pm.c | |||
| @@ -75,7 +75,7 @@ static int xo1_power_state_enter(suspend_state_t pm_state) | |||
| 75 | return 0; | 75 | return 0; |
| 76 | } | 76 | } |
| 77 | 77 | ||
| 78 | asmlinkage int xo1_do_sleep(u8 sleep_state) | 78 | asmlinkage __visible int xo1_do_sleep(u8 sleep_state) |
| 79 | { | 79 | { |
| 80 | void *pgd_addr = __va(read_cr3()); | 80 | void *pgd_addr = __va(read_cr3()); |
| 81 | 81 | ||
diff --git a/arch/x86/power/hibernate_64.c b/arch/x86/power/hibernate_64.c index 304fca20d96e..35e2bb6c0f37 100644 --- a/arch/x86/power/hibernate_64.c +++ b/arch/x86/power/hibernate_64.c | |||
| @@ -23,7 +23,7 @@ | |||
| 23 | extern __visible const void __nosave_begin, __nosave_end; | 23 | extern __visible const void __nosave_begin, __nosave_end; |
| 24 | 24 | ||
| 25 | /* Defined in hibernate_asm_64.S */ | 25 | /* Defined in hibernate_asm_64.S */ |
| 26 | extern asmlinkage int restore_image(void); | 26 | extern asmlinkage __visible int restore_image(void); |
| 27 | 27 | ||
| 28 | /* | 28 | /* |
| 29 | * Address to jump to in the last phase of restore in order to get to the image | 29 | * Address to jump to in the last phase of restore in order to get to the image |
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 201d09a7c46b..c34bfc4bbe7f 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
| @@ -1515,7 +1515,7 @@ static void __init xen_pvh_early_guest_init(void) | |||
| 1515 | } | 1515 | } |
| 1516 | 1516 | ||
| 1517 | /* First C function to be called on Xen boot */ | 1517 | /* First C function to be called on Xen boot */ |
| 1518 | asmlinkage void __init xen_start_kernel(void) | 1518 | asmlinkage __visible void __init xen_start_kernel(void) |
| 1519 | { | 1519 | { |
| 1520 | struct physdev_set_iopl set_iopl; | 1520 | struct physdev_set_iopl set_iopl; |
| 1521 | int rc; | 1521 | int rc; |
diff --git a/arch/x86/xen/irq.c b/arch/x86/xen/irq.c index 08f763de26fe..a1207cb6472a 100644 --- a/arch/x86/xen/irq.c +++ b/arch/x86/xen/irq.c | |||
| @@ -23,7 +23,7 @@ void xen_force_evtchn_callback(void) | |||
| 23 | (void)HYPERVISOR_xen_version(0, NULL); | 23 | (void)HYPERVISOR_xen_version(0, NULL); |
| 24 | } | 24 | } |
| 25 | 25 | ||
| 26 | asmlinkage unsigned long xen_save_fl(void) | 26 | asmlinkage __visible unsigned long xen_save_fl(void) |
| 27 | { | 27 | { |
| 28 | struct vcpu_info *vcpu; | 28 | struct vcpu_info *vcpu; |
| 29 | unsigned long flags; | 29 | unsigned long flags; |
| @@ -63,7 +63,7 @@ __visible void xen_restore_fl(unsigned long flags) | |||
| 63 | } | 63 | } |
| 64 | PV_CALLEE_SAVE_REGS_THUNK(xen_restore_fl); | 64 | PV_CALLEE_SAVE_REGS_THUNK(xen_restore_fl); |
| 65 | 65 | ||
| 66 | asmlinkage void xen_irq_disable(void) | 66 | asmlinkage __visible void xen_irq_disable(void) |
| 67 | { | 67 | { |
| 68 | /* There's a one instruction preempt window here. We need to | 68 | /* There's a one instruction preempt window here. We need to |
| 69 | make sure we're don't switch CPUs between getting the vcpu | 69 | make sure we're don't switch CPUs between getting the vcpu |
| @@ -74,7 +74,7 @@ asmlinkage void xen_irq_disable(void) | |||
| 74 | } | 74 | } |
| 75 | PV_CALLEE_SAVE_REGS_THUNK(xen_irq_disable); | 75 | PV_CALLEE_SAVE_REGS_THUNK(xen_irq_disable); |
| 76 | 76 | ||
| 77 | asmlinkage void xen_irq_enable(void) | 77 | asmlinkage __visible void xen_irq_enable(void) |
| 78 | { | 78 | { |
| 79 | struct vcpu_info *vcpu; | 79 | struct vcpu_info *vcpu; |
| 80 | 80 | ||
diff --git a/drivers/pnp/pnpbios/bioscalls.c b/drivers/pnp/pnpbios/bioscalls.c index deb7f4bcdb7b..438d4c72c7b3 100644 --- a/drivers/pnp/pnpbios/bioscalls.c +++ b/drivers/pnp/pnpbios/bioscalls.c | |||
| @@ -37,7 +37,7 @@ __visible struct { | |||
| 37 | * kernel begins at offset 3GB... | 37 | * kernel begins at offset 3GB... |
| 38 | */ | 38 | */ |
| 39 | 39 | ||
| 40 | asmlinkage void pnp_bios_callfunc(void); | 40 | asmlinkage __visible void pnp_bios_callfunc(void); |
| 41 | 41 | ||
| 42 | __asm__(".text \n" | 42 | __asm__(".text \n" |
| 43 | __ALIGN_STR "\n" | 43 | __ALIGN_STR "\n" |
diff --git a/include/linux/linkage.h b/include/linux/linkage.h index 34a513a2727b..a6a42dd02466 100644 --- a/include/linux/linkage.h +++ b/include/linux/linkage.h | |||
| @@ -12,9 +12,9 @@ | |||
| 12 | #endif | 12 | #endif |
| 13 | 13 | ||
| 14 | #ifdef __cplusplus | 14 | #ifdef __cplusplus |
| 15 | #define CPP_ASMLINKAGE extern "C" __visible | 15 | #define CPP_ASMLINKAGE extern "C" |
| 16 | #else | 16 | #else |
| 17 | #define CPP_ASMLINKAGE __visible | 17 | #define CPP_ASMLINKAGE |
| 18 | #endif | 18 | #endif |
| 19 | 19 | ||
| 20 | #ifndef asmlinkage | 20 | #ifndef asmlinkage |
diff --git a/init/main.c b/init/main.c index 9c7fd4c9249f..48655ceb66f4 100644 --- a/init/main.c +++ b/init/main.c | |||
| @@ -476,7 +476,7 @@ static void __init mm_init(void) | |||
| 476 | vmalloc_init(); | 476 | vmalloc_init(); |
| 477 | } | 477 | } |
| 478 | 478 | ||
| 479 | asmlinkage void __init start_kernel(void) | 479 | asmlinkage __visible void __init start_kernel(void) |
| 480 | { | 480 | { |
| 481 | char * command_line; | 481 | char * command_line; |
| 482 | extern const struct kernel_param __start___param[], __stop___param[]; | 482 | extern const struct kernel_param __start___param[], __stop___param[]; |
diff --git a/kernel/context_tracking.c b/kernel/context_tracking.c index 6cb20d2e7ee0..019d45008448 100644 --- a/kernel/context_tracking.c +++ b/kernel/context_tracking.c | |||
| @@ -120,7 +120,7 @@ void context_tracking_user_enter(void) | |||
| 120 | * instead of preempt_schedule() to exit user context if needed before | 120 | * instead of preempt_schedule() to exit user context if needed before |
| 121 | * calling the scheduler. | 121 | * calling the scheduler. |
| 122 | */ | 122 | */ |
| 123 | asmlinkage void __sched notrace preempt_schedule_context(void) | 123 | asmlinkage __visible void __sched notrace preempt_schedule_context(void) |
| 124 | { | 124 | { |
| 125 | enum ctx_state prev_ctx; | 125 | enum ctx_state prev_ctx; |
| 126 | 126 | ||
diff --git a/kernel/locking/lockdep.c b/kernel/locking/lockdep.c index b0e9467922e1..d24e4339b46d 100644 --- a/kernel/locking/lockdep.c +++ b/kernel/locking/lockdep.c | |||
| @@ -4188,7 +4188,7 @@ void debug_show_held_locks(struct task_struct *task) | |||
| 4188 | } | 4188 | } |
| 4189 | EXPORT_SYMBOL_GPL(debug_show_held_locks); | 4189 | EXPORT_SYMBOL_GPL(debug_show_held_locks); |
| 4190 | 4190 | ||
| 4191 | asmlinkage void lockdep_sys_exit(void) | 4191 | asmlinkage __visible void lockdep_sys_exit(void) |
| 4192 | { | 4192 | { |
| 4193 | struct task_struct *curr = current; | 4193 | struct task_struct *curr = current; |
| 4194 | 4194 | ||
diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c index 18fb7a2fb14b..1ea328aafdc9 100644 --- a/kernel/power/snapshot.c +++ b/kernel/power/snapshot.c | |||
| @@ -1586,7 +1586,7 @@ swsusp_alloc(struct memory_bitmap *orig_bm, struct memory_bitmap *copy_bm, | |||
| 1586 | return -ENOMEM; | 1586 | return -ENOMEM; |
| 1587 | } | 1587 | } |
| 1588 | 1588 | ||
| 1589 | asmlinkage int swsusp_save(void) | 1589 | asmlinkage __visible int swsusp_save(void) |
| 1590 | { | 1590 | { |
| 1591 | unsigned int nr_pages, nr_highmem; | 1591 | unsigned int nr_pages, nr_highmem; |
| 1592 | 1592 | ||
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c index a45b50962295..7228258b85ec 100644 --- a/kernel/printk/printk.c +++ b/kernel/printk/printk.c | |||
| @@ -1674,7 +1674,7 @@ EXPORT_SYMBOL(printk_emit); | |||
| 1674 | * | 1674 | * |
| 1675 | * See the vsnprintf() documentation for format string extensions over C99. | 1675 | * See the vsnprintf() documentation for format string extensions over C99. |
| 1676 | */ | 1676 | */ |
| 1677 | asmlinkage int printk(const char *fmt, ...) | 1677 | asmlinkage __visible int printk(const char *fmt, ...) |
| 1678 | { | 1678 | { |
| 1679 | va_list args; | 1679 | va_list args; |
| 1680 | int r; | 1680 | int r; |
| @@ -1737,7 +1737,7 @@ void early_vprintk(const char *fmt, va_list ap) | |||
| 1737 | } | 1737 | } |
| 1738 | } | 1738 | } |
| 1739 | 1739 | ||
| 1740 | asmlinkage void early_printk(const char *fmt, ...) | 1740 | asmlinkage __visible void early_printk(const char *fmt, ...) |
| 1741 | { | 1741 | { |
| 1742 | va_list ap; | 1742 | va_list ap; |
| 1743 | 1743 | ||
diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 268a45ea238c..d9d8ece46a15 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c | |||
| @@ -2192,7 +2192,7 @@ static inline void post_schedule(struct rq *rq) | |||
| 2192 | * schedule_tail - first thing a freshly forked thread must call. | 2192 | * schedule_tail - first thing a freshly forked thread must call. |
| 2193 | * @prev: the thread we just switched away from. | 2193 | * @prev: the thread we just switched away from. |
| 2194 | */ | 2194 | */ |
| 2195 | asmlinkage void schedule_tail(struct task_struct *prev) | 2195 | asmlinkage __visible void schedule_tail(struct task_struct *prev) |
| 2196 | __releases(rq->lock) | 2196 | __releases(rq->lock) |
| 2197 | { | 2197 | { |
| 2198 | struct rq *rq = this_rq(); | 2198 | struct rq *rq = this_rq(); |
| @@ -2741,7 +2741,7 @@ static inline void sched_submit_work(struct task_struct *tsk) | |||
| 2741 | blk_schedule_flush_plug(tsk); | 2741 | blk_schedule_flush_plug(tsk); |
| 2742 | } | 2742 | } |
| 2743 | 2743 | ||
| 2744 | asmlinkage void __sched schedule(void) | 2744 | asmlinkage __visible void __sched schedule(void) |
| 2745 | { | 2745 | { |
| 2746 | struct task_struct *tsk = current; | 2746 | struct task_struct *tsk = current; |
| 2747 | 2747 | ||
| @@ -2751,7 +2751,7 @@ asmlinkage void __sched schedule(void) | |||
| 2751 | EXPORT_SYMBOL(schedule); | 2751 | EXPORT_SYMBOL(schedule); |
| 2752 | 2752 | ||
| 2753 | #ifdef CONFIG_CONTEXT_TRACKING | 2753 | #ifdef CONFIG_CONTEXT_TRACKING |
| 2754 | asmlinkage void __sched schedule_user(void) | 2754 | asmlinkage __visible void __sched schedule_user(void) |
| 2755 | { | 2755 | { |
| 2756 | /* | 2756 | /* |
| 2757 | * If we come here after a random call to set_need_resched(), | 2757 | * If we come here after a random call to set_need_resched(), |
| @@ -2783,7 +2783,7 @@ void __sched schedule_preempt_disabled(void) | |||
| 2783 | * off of preempt_enable. Kernel preemptions off return from interrupt | 2783 | * off of preempt_enable. Kernel preemptions off return from interrupt |
| 2784 | * occur there and call schedule directly. | 2784 | * occur there and call schedule directly. |
| 2785 | */ | 2785 | */ |
| 2786 | asmlinkage void __sched notrace preempt_schedule(void) | 2786 | asmlinkage __visible void __sched notrace preempt_schedule(void) |
| 2787 | { | 2787 | { |
| 2788 | /* | 2788 | /* |
| 2789 | * If there is a non-zero preempt_count or interrupts are disabled, | 2789 | * If there is a non-zero preempt_count or interrupts are disabled, |
| @@ -2813,7 +2813,7 @@ EXPORT_SYMBOL(preempt_schedule); | |||
| 2813 | * Note, that this is called and return with irqs disabled. This will | 2813 | * Note, that this is called and return with irqs disabled. This will |
| 2814 | * protect us against recursive calling from irq. | 2814 | * protect us against recursive calling from irq. |
| 2815 | */ | 2815 | */ |
| 2816 | asmlinkage void __sched preempt_schedule_irq(void) | 2816 | asmlinkage __visible void __sched preempt_schedule_irq(void) |
| 2817 | { | 2817 | { |
| 2818 | enum ctx_state prev_state; | 2818 | enum ctx_state prev_state; |
| 2819 | 2819 | ||
diff --git a/kernel/softirq.c b/kernel/softirq.c index 33e4648ae0e7..92f24f5e8d52 100644 --- a/kernel/softirq.c +++ b/kernel/softirq.c | |||
| @@ -223,7 +223,7 @@ static inline bool lockdep_softirq_start(void) { return false; } | |||
| 223 | static inline void lockdep_softirq_end(bool in_hardirq) { } | 223 | static inline void lockdep_softirq_end(bool in_hardirq) { } |
| 224 | #endif | 224 | #endif |
| 225 | 225 | ||
| 226 | asmlinkage void __do_softirq(void) | 226 | asmlinkage __visible void __do_softirq(void) |
| 227 | { | 227 | { |
| 228 | unsigned long end = jiffies + MAX_SOFTIRQ_TIME; | 228 | unsigned long end = jiffies + MAX_SOFTIRQ_TIME; |
| 229 | unsigned long old_flags = current->flags; | 229 | unsigned long old_flags = current->flags; |
| @@ -299,7 +299,7 @@ restart: | |||
| 299 | tsk_restore_flags(current, old_flags, PF_MEMALLOC); | 299 | tsk_restore_flags(current, old_flags, PF_MEMALLOC); |
| 300 | } | 300 | } |
| 301 | 301 | ||
| 302 | asmlinkage void do_softirq(void) | 302 | asmlinkage __visible void do_softirq(void) |
| 303 | { | 303 | { |
| 304 | __u32 pending; | 304 | __u32 pending; |
| 305 | unsigned long flags; | 305 | unsigned long flags; |
diff --git a/lib/dump_stack.c b/lib/dump_stack.c index f23b63f0a1c3..6745c6230db3 100644 --- a/lib/dump_stack.c +++ b/lib/dump_stack.c | |||
| @@ -23,7 +23,7 @@ static void __dump_stack(void) | |||
| 23 | #ifdef CONFIG_SMP | 23 | #ifdef CONFIG_SMP |
| 24 | static atomic_t dump_lock = ATOMIC_INIT(-1); | 24 | static atomic_t dump_lock = ATOMIC_INIT(-1); |
| 25 | 25 | ||
| 26 | asmlinkage void dump_stack(void) | 26 | asmlinkage __visible void dump_stack(void) |
| 27 | { | 27 | { |
| 28 | int was_locked; | 28 | int was_locked; |
| 29 | int old; | 29 | int old; |
| @@ -55,7 +55,7 @@ retry: | |||
| 55 | preempt_enable(); | 55 | preempt_enable(); |
| 56 | } | 56 | } |
| 57 | #else | 57 | #else |
| 58 | asmlinkage void dump_stack(void) | 58 | asmlinkage __visible void dump_stack(void) |
| 59 | { | 59 | { |
| 60 | __dump_stack(); | 60 | __dump_stack(); |
| 61 | } | 61 | } |
