Page MenuHomeFreeBSD

D52421.diff
No OneTemporary

D52421.diff

diff --git a/sys/kern/kern_thr.c b/sys/kern/kern_thr.c
--- a/sys/kern/kern_thr.c
+++ b/sys/kern/kern_thr.c
@@ -346,6 +346,17 @@
p = td->td_proc;
+ /*
+ * Clear kernel ASTs in advance of selecting the last exiting
+ * thread and acquiring schedulers locks. It is fine to
+ * clear the ASTs here even if we are not going to exit after
+ * all. On the other hand, leaving them pending could trigger
+ * execution in subsystems in a context where they are not
+ * prepared to handle top kernel actions, even in execution of
+ * an unrelated thread.
+ */
+ ast_kclear(td);
+
/*
* If all of the threads in a process call this routine to
* exit (e.g. all threads call pthread_exit()), exactly one

File Metadata

Mime Type
text/plain
Expires
Sun, Feb 1, 11:00 AM (14 h, 44 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28348460
Default Alt Text
D52421.diff (715 B)

Event Timeline