mirror of
https://review.haiku-os.org/haiku
synced 2025-02-23 05:58:31 +01:00
* Create an internal variant which accepts a "bool locked" parameter. Use this from callout_reset instead of invoking it before locking, and then relocking afterwards. Eliminates some possible (though, so far as I know, benign) races. * mtx_assert always, even if the callout is not active. (Requirement notated in the comment.) * In callout_reset, do not invoke callout_stop at all unless we are cancelling; in cases of mere reschedules, simply change c_due and notify the callout thread. * While at it, use list_init_etc in init_callout; no-op change, but keeps things clean. This should fix #18338 (specifically the change to never invoke callout_stop when merely rescheduling, not cancelling.)