K 10 svn:author V 3 jtl K 8 svn:date V 27 2017-06-08T20:47:18.652251Z K 7 svn:log V 612 With EARLY_AP_STARTUP enabled, we are seeing crashes in softclock_call_cc() during bootup. Debugging information shows that softclock_call_cc() is trying to execute the vt_consdev.vd_timer callout, and the callout structure contains a NULL c_func. This appears to be due to a race between vt_upgrade() running callout_reset() and vt_resume_flush_timer() calling callout_schedule(). Fix the race by ensuring that vd_timer_armed is always set before attempting to (re)schedule the callout. Discussed with: emaste MFC after: 2 weeks Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D9828 END