Remove or conditionalize some hypervisor-unfriendly instruction sequences.
This commit is contained in:
parent
6413b05739
commit
16bfd6f347
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=215160
@ -1136,10 +1136,6 @@ moea64_bootstrap(mmu_t mmup, vm_offset_t kernelstart, vm_offset_t kernelend)
|
|||||||
moea64_add_ofw_mappings(mmup, mmu, sz);
|
moea64_add_ofw_mappings(mmup, mmu, sz);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef SMP
|
|
||||||
TLBSYNC();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Calculate the last available physical address.
|
* Calculate the last available physical address.
|
||||||
*/
|
*/
|
||||||
|
@ -78,7 +78,13 @@ machdep_ap_bootstrap(void)
|
|||||||
;
|
;
|
||||||
|
|
||||||
/* Initialize DEC and TB, sync with the BSP values */
|
/* Initialize DEC and TB, sync with the BSP values */
|
||||||
|
#ifdef __powerpc64__
|
||||||
|
/* Writing to the time base register is hypervisor-privileged */
|
||||||
|
if (mfmsr() & PSL_HV)
|
||||||
|
mttb(ap_timebase);
|
||||||
|
#else
|
||||||
mttb(ap_timebase);
|
mttb(ap_timebase);
|
||||||
|
#endif
|
||||||
decr_ap_init();
|
decr_ap_init();
|
||||||
|
|
||||||
/* Serialize console output and AP count increment */
|
/* Serialize console output and AP count increment */
|
||||||
@ -240,7 +246,13 @@ cpu_mp_unleash(void *dummy)
|
|||||||
/* Let APs continue */
|
/* Let APs continue */
|
||||||
atomic_store_rel_int(&ap_letgo, 1);
|
atomic_store_rel_int(&ap_letgo, 1);
|
||||||
|
|
||||||
|
#ifdef __powerpc64__
|
||||||
|
/* Writing to the time base register is hypervisor-privileged */
|
||||||
|
if (mfmsr() & PSL_HV)
|
||||||
|
mttb(ap_timebase);
|
||||||
|
#else
|
||||||
mttb(ap_timebase);
|
mttb(ap_timebase);
|
||||||
|
#endif
|
||||||
|
|
||||||
while (ap_awake < smp_cpus)
|
while (ap_awake < smp_cpus)
|
||||||
;
|
;
|
||||||
|
Loading…
Reference in New Issue
Block a user