diff options
author | Jeremy Fitzhardinge <jeremy@xensource.com> | 2007-07-17 21:37:07 -0400 |
---|---|---|
committer | Jeremy Fitzhardinge <jeremy@goop.org> | 2007-07-18 11:47:45 -0400 |
commit | 60223a326fc8fa6e90e2c3fd28ae6de4a311d731 (patch) | |
tree | cf4e667a56402b846488373bfaf5bf840395e219 /arch/i386/xen/smp.c | |
parent | 3e2b8fbeec8f005672f2a2e862fb9c26a0bafedc (diff) |
xen: Place vcpu_info structure into per-cpu memory
An experimental patch for Xen allows guests to place their vcpu_info
structs anywhere. We try to use this to place the vcpu_info into the
PDA, which allows direct access.
If this works, then switch to using direct access operations for
irq_enable, disable, save_fl and restore_fl.
Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
Cc: Chris Wright <chrisw@sous-sol.org>
Cc: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'arch/i386/xen/smp.c')
-rw-r--r-- | arch/i386/xen/smp.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/i386/xen/smp.c b/arch/i386/xen/smp.c index a620918f87ee..557b8e24706a 100644 --- a/arch/i386/xen/smp.c +++ b/arch/i386/xen/smp.c | |||
@@ -142,8 +142,6 @@ void __init xen_smp_prepare_boot_cpu(void) | |||
142 | BUG_ON(smp_processor_id() != 0); | 142 | BUG_ON(smp_processor_id() != 0); |
143 | native_smp_prepare_boot_cpu(); | 143 | native_smp_prepare_boot_cpu(); |
144 | 144 | ||
145 | xen_vcpu_setup(0); | ||
146 | |||
147 | /* We've switched to the "real" per-cpu gdt, so make sure the | 145 | /* We've switched to the "real" per-cpu gdt, so make sure the |
148 | old memory can be recycled */ | 146 | old memory can be recycled */ |
149 | make_lowmem_page_readwrite(&per_cpu__gdt_page); | 147 | make_lowmem_page_readwrite(&per_cpu__gdt_page); |
@@ -152,6 +150,8 @@ void __init xen_smp_prepare_boot_cpu(void) | |||
152 | cpus_clear(cpu_sibling_map[cpu]); | 150 | cpus_clear(cpu_sibling_map[cpu]); |
153 | cpus_clear(cpu_core_map[cpu]); | 151 | cpus_clear(cpu_core_map[cpu]); |
154 | } | 152 | } |
153 | |||
154 | xen_setup_vcpu_info_placement(); | ||
155 | } | 155 | } |
156 | 156 | ||
157 | void __init xen_smp_prepare_cpus(unsigned int max_cpus) | 157 | void __init xen_smp_prepare_cpus(unsigned int max_cpus) |
@@ -262,7 +262,6 @@ int __cpuinit xen_cpu_up(unsigned int cpu) | |||
262 | 262 | ||
263 | init_gdt(cpu); | 263 | init_gdt(cpu); |
264 | per_cpu(current_task, cpu) = idle; | 264 | per_cpu(current_task, cpu) = idle; |
265 | xen_vcpu_setup(cpu); | ||
266 | irq_ctx_init(cpu); | 265 | irq_ctx_init(cpu); |
267 | xen_setup_timer(cpu); | 266 | xen_setup_timer(cpu); |
268 | 267 | ||