Catch the case where the idle loop is entered with interrupts disabled,

causing a hard hang.
This commit is contained in:
grehan 2005-02-28 09:49:00 +00:00
parent 001881a134
commit 2773bd509b
2 changed files with 18 additions and 2 deletions

View File

@ -735,7 +735,15 @@ cpu_halt(void)
void
cpu_idle(void)
{
/* Insert code to halt (until next interrupt) for the idle loop */
/* TODO: Insert code to halt (until next interrupt) */
#ifdef INVARIANTS
if ((mfmsr() & PSL_EE) != PSL_EE) {
struct thread *td = curthread;
printf("td crit %x\n", td->td_md.md_savecrit);
panic("ints disabled in idleproc!");
}
#endif
}
/*

View File

@ -735,7 +735,15 @@ cpu_halt(void)
void
cpu_idle(void)
{
/* Insert code to halt (until next interrupt) for the idle loop */
/* TODO: Insert code to halt (until next interrupt) */
#ifdef INVARIANTS
if ((mfmsr() & PSL_EE) != PSL_EE) {
struct thread *td = curthread;
printf("td crit %x\n", td->td_md.md_savecrit);
panic("ints disabled in idleproc!");
}
#endif
}
/*