powerpc64: Clear FSCR SPR, so that it's in a known state

This now turns any access to the DSCR SPR into a SIGILL.  Later commits will
make DCSR work correctly on POWER8 and POWER9.

PR:		237208
This commit is contained in:
Justin Hibbits 2019-04-26 03:18:49 +00:00
parent 38a6d5495b
commit 17b72853f4
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=346730
2 changed files with 9 additions and 0 deletions

View File

@ -98,6 +98,12 @@ cpudep_ap_early_bootstrap(void)
mtspr(SPR_LPCR, lpcr);
isync();
/*
* Nuke FSCR, to be managed on a per-process basis
* later.
*/
mtspr(SPR_FSCR, 0);
}
#endif
break;

View File

@ -663,6 +663,9 @@ cpu_powerx_setup(int cpuid, uint16_t vers)
if ((mfmsr() & PSL_HV) == 0)
return;
/* Nuke the FSCR, to disable all facilities. */
mtspr(SPR_FSCR, 0);
/* Configure power-saving */
switch (vers) {
case IBMPOWER8: