diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/i386/kernel/io_apic.c | 2 | ||||
-rw-r--r-- | arch/i386/kernel/vmi.c | 23 | ||||
-rw-r--r-- | arch/i386/mm/highmem.c | 2 | ||||
-rw-r--r-- | arch/x86_64/kernel/early-quirks.c | 2 |
4 files changed, 26 insertions, 3 deletions
diff --git a/arch/i386/kernel/io_apic.c b/arch/i386/kernel/io_apic.c index e4408ff4e674..b3ab8ffebd27 100644 --- a/arch/i386/kernel/io_apic.c +++ b/arch/i386/kernel/io_apic.c | |||
@@ -736,7 +736,7 @@ failed: | |||
736 | return 0; | 736 | return 0; |
737 | } | 737 | } |
738 | 738 | ||
739 | int __init irqbalance_disable(char *str) | 739 | int __devinit irqbalance_disable(char *str) |
740 | { | 740 | { |
741 | irqbalance_disabled = 1; | 741 | irqbalance_disabled = 1; |
742 | return 1; | 742 | return 1; |
diff --git a/arch/i386/kernel/vmi.c b/arch/i386/kernel/vmi.c index fb07a1aad225..edc339fa5038 100644 --- a/arch/i386/kernel/vmi.c +++ b/arch/i386/kernel/vmi.c | |||
@@ -69,6 +69,7 @@ struct { | |||
69 | void (*flush_tlb)(int); | 69 | void (*flush_tlb)(int); |
70 | void (*set_initial_ap_state)(int, int); | 70 | void (*set_initial_ap_state)(int, int); |
71 | void (*halt)(void); | 71 | void (*halt)(void); |
72 | void (*set_lazy_mode)(int mode); | ||
72 | } vmi_ops; | 73 | } vmi_ops; |
73 | 74 | ||
74 | /* XXX move this to alternative.h */ | 75 | /* XXX move this to alternative.h */ |
@@ -574,6 +575,26 @@ vmi_startup_ipi_hook(int phys_apicid, unsigned long start_eip, | |||
574 | } | 575 | } |
575 | #endif | 576 | #endif |
576 | 577 | ||
578 | static void vmi_set_lazy_mode(int mode) | ||
579 | { | ||
580 | static DEFINE_PER_CPU(int, lazy_mode); | ||
581 | |||
582 | if (!vmi_ops.set_lazy_mode) | ||
583 | return; | ||
584 | |||
585 | /* Modes should never nest or overlap */ | ||
586 | BUG_ON(__get_cpu_var(lazy_mode) && !(mode == PARAVIRT_LAZY_NONE || | ||
587 | mode == PARAVIRT_LAZY_FLUSH)); | ||
588 | |||
589 | if (mode == PARAVIRT_LAZY_FLUSH) { | ||
590 | vmi_ops.set_lazy_mode(0); | ||
591 | vmi_ops.set_lazy_mode(__get_cpu_var(lazy_mode)); | ||
592 | } else { | ||
593 | vmi_ops.set_lazy_mode(mode); | ||
594 | __get_cpu_var(lazy_mode) = mode; | ||
595 | } | ||
596 | } | ||
597 | |||
577 | static inline int __init check_vmi_rom(struct vrom_header *rom) | 598 | static inline int __init check_vmi_rom(struct vrom_header *rom) |
578 | { | 599 | { |
579 | struct pci_header *pci; | 600 | struct pci_header *pci; |
@@ -804,7 +825,7 @@ static inline int __init activate_vmi(void) | |||
804 | para_wrap(load_esp0, vmi_load_esp0, set_kernel_stack, UpdateKernelStack); | 825 | para_wrap(load_esp0, vmi_load_esp0, set_kernel_stack, UpdateKernelStack); |
805 | para_fill(set_iopl_mask, SetIOPLMask); | 826 | para_fill(set_iopl_mask, SetIOPLMask); |
806 | para_fill(io_delay, IODelay); | 827 | para_fill(io_delay, IODelay); |
807 | para_fill(set_lazy_mode, SetLazyMode); | 828 | para_wrap(set_lazy_mode, vmi_set_lazy_mode, set_lazy_mode, SetLazyMode); |
808 | 829 | ||
809 | /* user and kernel flush are just handled with different flags to FlushTLB */ | 830 | /* user and kernel flush are just handled with different flags to FlushTLB */ |
810 | para_wrap(flush_tlb_user, vmi_flush_tlb_user, flush_tlb, FlushTLB); | 831 | para_wrap(flush_tlb_user, vmi_flush_tlb_user, flush_tlb, FlushTLB); |
diff --git a/arch/i386/mm/highmem.c b/arch/i386/mm/highmem.c index bb2de1089add..ac70d09df7ee 100644 --- a/arch/i386/mm/highmem.c +++ b/arch/i386/mm/highmem.c | |||
@@ -42,6 +42,7 @@ void *kmap_atomic(struct page *page, enum km_type type) | |||
42 | 42 | ||
43 | vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); | 43 | vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); |
44 | set_pte(kmap_pte-idx, mk_pte(page, kmap_prot)); | 44 | set_pte(kmap_pte-idx, mk_pte(page, kmap_prot)); |
45 | arch_flush_lazy_mmu_mode(); | ||
45 | 46 | ||
46 | return (void*) vaddr; | 47 | return (void*) vaddr; |
47 | } | 48 | } |
@@ -82,6 +83,7 @@ void *kmap_atomic_pfn(unsigned long pfn, enum km_type type) | |||
82 | idx = type + KM_TYPE_NR*smp_processor_id(); | 83 | idx = type + KM_TYPE_NR*smp_processor_id(); |
83 | vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); | 84 | vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); |
84 | set_pte(kmap_pte-idx, pfn_pte(pfn, kmap_prot)); | 85 | set_pte(kmap_pte-idx, pfn_pte(pfn, kmap_prot)); |
86 | arch_flush_lazy_mmu_mode(); | ||
85 | 87 | ||
86 | return (void*) vaddr; | 88 | return (void*) vaddr; |
87 | } | 89 | } |
diff --git a/arch/x86_64/kernel/early-quirks.c b/arch/x86_64/kernel/early-quirks.c index 148c6bcf5bb4..fede55a53995 100644 --- a/arch/x86_64/kernel/early-quirks.c +++ b/arch/x86_64/kernel/early-quirks.c | |||
@@ -88,7 +88,7 @@ struct chipset { | |||
88 | void (*f)(void); | 88 | void (*f)(void); |
89 | }; | 89 | }; |
90 | 90 | ||
91 | static struct __initdata chipset early_qrk[] = { | 91 | static struct chipset early_qrk[] __initdata = { |
92 | { PCI_VENDOR_ID_NVIDIA, nvidia_bugs }, | 92 | { PCI_VENDOR_ID_NVIDIA, nvidia_bugs }, |
93 | { PCI_VENDOR_ID_VIA, via_bugs }, | 93 | { PCI_VENDOR_ID_VIA, via_bugs }, |
94 | { PCI_VENDOR_ID_ATI, ati_bugs }, | 94 | { PCI_VENDOR_ID_ATI, ati_bugs }, |