svn commit: r368057 - stable/12/sys/kern
Mark Johnston
markj at FreeBSD.org
Thu Nov 26 14:57:31 UTC 2020
Author: markj
Date: Thu Nov 26 14:57:30 2020
New Revision: 368057
URL: https://svnweb.freebsd.org/changeset/base/368057
Log:
MFC r367849:
callout(9): Fix a race between CPU migration and callout_drain()
Modified:
stable/12/sys/kern/kern_timeout.c
Directory Properties:
stable/12/ (props changed)
Modified: stable/12/sys/kern/kern_timeout.c
==============================================================================
--- stable/12/sys/kern/kern_timeout.c Thu Nov 26 14:42:16 2020 (r368056)
+++ stable/12/sys/kern/kern_timeout.c Thu Nov 26 14:57:30 2020 (r368057)
@@ -1274,7 +1274,7 @@ again:
* just wait for the current invocation to
* finish.
*/
- while (cc_exec_curr(cc, direct) == c) {
+ if (cc_exec_curr(cc, direct) == c) {
/*
* Use direct calls to sleepqueue interface
* instead of cv/msleep in order to avoid
@@ -1322,7 +1322,7 @@ again:
/* Reacquire locks previously released. */
PICKUP_GIANT();
- CC_LOCK(cc);
+ goto again;
}
c->c_flags &= ~CALLOUT_ACTIVE;
} else if (use_lock &&
More information about the svn-src-stable
mailing list