diff options
author | Wei, Gang <gang.wei@intel.com> | 2012-01-11 10:34:45 +0100 |
---|---|---|
committer | Wei, Gang <gang.wei@intel.com> | 2012-01-11 10:34:45 +0100 |
commit | 8254d9de116ba2346f489a529208a531a461c723 (patch) | |
tree | 1efe39dc30544451a479514690b1cb30ca094997 /xen/arch/x86/smpboot.c | |
parent | e31a66a2b81d1a3d7db829b603865586d44d6216 (diff) | |
download | xen-8254d9de116ba2346f489a529208a531a461c723.tar.gz xen-8254d9de116ba2346f489a529208a531a461c723.tar.bz2 xen-8254d9de116ba2346f489a529208a531a461c723.zip |
x86: add a new SMP bring up way for tboot case
From: Wei, Gang <gang.wei@intel.com>
tboot may be trying to put APs waiting in MWAIT loops before launching
Xen. Xen could check the new flag field in v6 tboot shared page for the
hint. If TB_FLAG_AP_WAKE_SUPPORT bit in flag field is set, Xen BSP have
to write the monitored memory(g_tboot_shared->ap_wake_trigger) to bring
APs out of MWAIT loops. The sipi vector should be written in
g_tboot_shared->ap_wake_addr before waking up APs.
Signed-off-by: Joseph Cihula <joseph.cihula@intel.com>
Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Gang Wei <gang.wei@intel.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Committed-by: Jan Beulich <jbeulich@suse.com>
Diffstat (limited to 'xen/arch/x86/smpboot.c')
-rw-r--r-- | xen/arch/x86/smpboot.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/xen/arch/x86/smpboot.c b/xen/arch/x86/smpboot.c index 748932366b..8463709dfd 100644 --- a/xen/arch/x86/smpboot.c +++ b/xen/arch/x86/smpboot.c @@ -555,8 +555,7 @@ int alloc_cpu_id(void) static int do_boot_cpu(int apicid, int cpu) { - unsigned long boot_error; - int timeout, rc = 0; + int timeout, boot_error = 0, rc = 0; unsigned long start_eip; /* @@ -586,7 +585,8 @@ static int do_boot_cpu(int apicid, int cpu) smpboot_setup_warm_reset_vector(start_eip); /* Starting actual IPI sequence... */ - boot_error = wakeup_secondary_cpu(apicid, start_eip); + if ( !tboot_in_measured_env() || tboot_wake_ap(apicid, start_eip) ) + boot_error = wakeup_secondary_cpu(apicid, start_eip); if ( !boot_error ) { |