git: kernel - Fix additional races in lwp_signotify()
dillon at crater.dragonflybsd.org
Thu Nov 17 10:47:01 PST 2011
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Thu Nov 17 10:44:16 2011 -0800
kernel - Fix additional races in lwp_signotify()
* lwp_signotify() was improperly scheduling threads whos td_gd is on the
local cpu without checking the SINTR flags. This can catch a thread in
the middle of being transitioned to another cpu and cause havoc.
* Only schedule the thread if the SINTR flags are set.
* We can't call setrunnable() from an IPI so adjustments have to be made
in the remote cpu to set the lp's lwp_stat state before issuing the IPI
and only do the scheduling of its thread from the IPI function.
Summary of changes:
sys/kern/kern_sig.c | 81 ++++++++++++++++++++++++++++++++++++--------------
1 files changed, 58 insertions(+), 23 deletions(-)
DragonFly BSD source repository
More information about the Commits