diff options
author | Carsten Otte <cotte@de.ibm.com> | 2007-10-29 11:09:10 -0400 |
---|---|---|
committer | Avi Kivity <avi@qumranet.com> | 2008-01-30 10:52:58 -0500 |
commit | 6866b83ed7240bf4a7c50836ee10f61c8534503f (patch) | |
tree | ca4ca86b554537998ff0ee7c78d00ea723c3f537 /drivers/kvm/kvm_main.c | |
parent | 5fb76f9be1a050a25e21a44ab2003c9d36a72a77 (diff) |
KVM: Portability: move get/set_apic_base to x86.c
This patch moves the implementation of get_apic_base and set_apic_base
from kvm_main.c to x86.c
Signed-off-by: Carsten Otte <cotte@de.ibm.com>
Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
Acked-by: Hollis Blanchard <hollisb@us.ibm.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'drivers/kvm/kvm_main.c')
-rw-r--r-- | drivers/kvm/kvm_main.c | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/drivers/kvm/kvm_main.c b/drivers/kvm/kvm_main.c index cf163bddfbd3..e8972a82544b 100644 --- a/drivers/kvm/kvm_main.c +++ b/drivers/kvm/kvm_main.c | |||
@@ -556,25 +556,6 @@ unsigned long get_cr8(struct kvm_vcpu *vcpu) | |||
556 | } | 556 | } |
557 | EXPORT_SYMBOL_GPL(get_cr8); | 557 | EXPORT_SYMBOL_GPL(get_cr8); |
558 | 558 | ||
559 | u64 kvm_get_apic_base(struct kvm_vcpu *vcpu) | ||
560 | { | ||
561 | if (irqchip_in_kernel(vcpu->kvm)) | ||
562 | return vcpu->apic_base; | ||
563 | else | ||
564 | return vcpu->apic_base; | ||
565 | } | ||
566 | EXPORT_SYMBOL_GPL(kvm_get_apic_base); | ||
567 | |||
568 | void kvm_set_apic_base(struct kvm_vcpu *vcpu, u64 data) | ||
569 | { | ||
570 | /* TODO: reserve bits check */ | ||
571 | if (irqchip_in_kernel(vcpu->kvm)) | ||
572 | kvm_lapic_set_base(vcpu, data); | ||
573 | else | ||
574 | vcpu->apic_base = data; | ||
575 | } | ||
576 | EXPORT_SYMBOL_GPL(kvm_set_apic_base); | ||
577 | |||
578 | void fx_init(struct kvm_vcpu *vcpu) | 559 | void fx_init(struct kvm_vcpu *vcpu) |
579 | { | 560 | { |
580 | unsigned after_mxcsr_mask; | 561 | unsigned after_mxcsr_mask; |