Page MenuHomeFreeBSD

Don't enable interrupts in init_secondary().
ClosedPublic

Authored by markj on Jan 22 2020, 11:02 PM.
Tags
None
Referenced Files
F165345424: D23328.id.diff
Fri, Aug 7, 6:25 PM
F165267181: D23328.id67170.diff
Fri, Aug 7, 7:16 AM
F165222500: D23328.id67206.diff
Thu, Aug 6, 11:09 PM
Unknown Object (File)
Thu, Jul 23, 8:03 PM
Unknown Object (File)
Wed, Jul 22, 3:21 PM
Unknown Object (File)
Tue, Jul 21, 12:47 PM
Unknown Object (File)
Tue, Jul 14, 2:01 PM
Unknown Object (File)
May 7 2026, 7:57 PM
Subscribers

Details

Summary

Doing so can cause deadlocks or panics during boot. In QEMU I was
seeing occasional panics during boot when a statclock interrupt
interrupted an idle thread in init_secondary(), before per-CPU scheduler
data structures were linked. It also seemed to be causing some
mysterious boot failures in AWS but I don't have console access and so
cannot confirm.

The idle threads are set up to release a spinlock section and enable
interrupts in fork_exit(), so there is no need to enable interrupts
earlier.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable