1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
|
Subject: Fix x86_64 xen build.
From: jbeulich@novell.com
Patch-mainline: obsolete
$subject says all.
---
arch/x86_64/kernel/crash.c | 4 ++--
arch/x86_64/kernel/pci-swiotlb-xen.c | 2 ++
arch/x86_64/kernel/process-xen.c | 7 -------
include/asm-x86_64/i387.h | 7 ++++++-
include/asm-x86_64/mach-xen/asm/page.h | 8 --------
5 files changed, 10 insertions(+), 18 deletions(-)
--- a/arch/x86_64/kernel/crash.c 2007-08-27 14:01:25.000000000 -0400
+++ b/arch/x86_64/kernel/crash.c 2007-08-27 14:01:25.000000000 -0400
@@ -25,10 +25,10 @@
#include <asm/hw_irq.h>
#include <asm/mach_apic.h>
+#ifndef CONFIG_XEN
/* This keeps a track of which one is crashing cpu. */
static int crashing_cpu;
-#ifndef CONFIG_XEN
#ifdef CONFIG_SMP
static atomic_t waiting_for_crash_ipi;
@@ -124,10 +124,10 @@ void machine_crash_shutdown(struct pt_re
/* The kernel is broken so disable interrupts */
local_irq_disable();
+#ifndef CONFIG_XEN
/* Make a note of crashing cpu. Will be used in NMI callback.*/
crashing_cpu = smp_processor_id();
-#ifndef CONFIG_XEN
nmi_shootdown_cpus();
if(cpu_has_apic)
--- a/arch/x86_64/kernel/pci-swiotlb-xen.c 2007-08-27 14:01:25.000000000 -0400
+++ b/arch/x86_64/kernel/pci-swiotlb-xen.c 2007-08-27 14:02:03.000000000 -0400
@@ -13,6 +13,8 @@ int swiotlb __read_mostly;
EXPORT_SYMBOL(swiotlb);
#endif
+void swiotlb_init(void);
+
struct dma_mapping_ops swiotlb_dma_ops = {
#if 0
.mapping_error = swiotlb_dma_mapping_error,
--- a/arch/x86_64/kernel/process-xen.c 2007-08-27 14:01:25.000000000 -0400
+++ b/arch/x86_64/kernel/process-xen.c 2007-08-27 14:02:03.000000000 -0400
@@ -465,13 +465,6 @@ out:
return err;
}
-static inline void __save_init_fpu( struct task_struct *tsk )
-{
- asm volatile( "rex64 ; fxsave %0 ; fnclex"
- : "=m" (tsk->thread.i387.fxsave));
- tsk->thread_info->status &= ~TS_USEDFPU;
-}
-
/*
* switch_to(x,y) should switch tasks from x to y.
*
--- a/include/asm-x86_64/i387.h 2007-08-27 12:09:22.000000000 -0400
+++ b/include/asm-x86_64/i387.h 2007-08-27 14:01:25.000000000 -0400
@@ -191,10 +191,15 @@ static inline void kernel_fpu_end(void)
preempt_enable();
}
-static inline void save_init_fpu(struct task_struct *tsk)
+static inline void __save_init_fpu(struct task_struct *tsk)
{
__fxsave_clear(tsk);
task_thread_info(tsk)->status &= ~TS_USEDFPU;
+}
+
+static inline void save_init_fpu(struct task_struct *tsk)
+{
+ __save_init_fpu(tsk);
stts();
}
--- a/include/asm-x86_64/mach-xen/asm/page.h 2007-08-27 14:01:25.000000000 -0400
+++ b/include/asm-x86_64/mach-xen/asm/page.h 2007-08-27 14:01:58.000000000 -0400
@@ -16,14 +16,6 @@
*/
#define _PAGE_PRESENT 0x001
-#define arch_free_page(_page,_order) \
-({ int foreign = PageForeign(_page); \
- if (foreign) \
- PageForeignDestructor(_page); \
- foreign; \
-})
-#define HAVE_ARCH_FREE_PAGE
-
/* PAGE_SHIFT determines the page size */
#define PAGE_SHIFT 12
#ifdef __ASSEMBLY__
|