diff options
author | Laszlo Ersek <lersek@redhat.com> | 2013-03-21 00:23:20 +0100 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2013-04-04 19:23:09 -0500 |
commit | dab8623430926a8c55a149c22b2b8e2edb786ae3 (patch) | |
tree | 5615603abe612879585ae46ad937c9060c865ada /hw | |
parent | 23084327dc5c2f42e8a1c3e39ec565e344c7f52e (diff) |
extract/unify the constant 0xfee00000 as APIC_DEFAULT_ADDRESS
A common dependency of the constant's current users:
- hw/apic_common.c
- hw/i386/kvmvapic.c
- target-i386/cpu.c
is "target-i386/cpu.h".
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>
Message-id: 1363821803-3380-9-git-send-email-lersek@redhat.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/apic_common.c | 2 | ||||
-rw-r--r-- | hw/i386/kvmvapic.c | 2 |
2 files changed, 1 insertions, 3 deletions
diff --git a/hw/apic_common.c b/hw/apic_common.c index d0c261602c..37985097ca 100644 --- a/hw/apic_common.c +++ b/hw/apic_common.c @@ -218,7 +218,7 @@ static void apic_reset_common(DeviceState *d) bool bsp; bsp = cpu_is_bsp(s->cpu); - s->apicbase = 0xfee00000 | + s->apicbase = APIC_DEFAULT_ADDRESS | (bsp ? MSR_IA32_APICBASE_BSP : 0) | MSR_IA32_APICBASE_ENABLE; s->vapic_paddr = 0; diff --git a/hw/i386/kvmvapic.c b/hw/i386/kvmvapic.c index c151c95c3e..cc95e5c3f0 100644 --- a/hw/i386/kvmvapic.c +++ b/hw/i386/kvmvapic.c @@ -13,8 +13,6 @@ #include "sysemu/kvm.h" #include "hw/apic_internal.h" -#define APIC_DEFAULT_ADDRESS 0xfee00000 - #define VAPIC_IO_PORT 0x7e #define VAPIC_CPU_SHIFT 7 |