diff options
author | hselasky <hselasky@FreeBSD.org> | 2016-05-25 09:04:06 +0000 |
---|---|---|
committer | hselasky <hselasky@FreeBSD.org> | 2016-05-25 09:04:06 +0000 |
commit | dbcba89131b58b7216efb8356da2adfc1a788cb7 (patch) | |
tree | b5692322399cbb88c01e1d6789f5a87750374cfb /sys/compat/linuxkpi/common/include/linux/sched.h | |
parent | 6a7280215260369b317474512d2b44c105a020a8 (diff) | |
download | FreeBSD-src-dbcba89131b58b7216efb8356da2adfc1a788cb7.zip FreeBSD-src-dbcba89131b58b7216efb8356da2adfc1a788cb7.tar.gz |
Add checks for SCHEDULER_STOPPED() so that code using the LinuxKPI can
run after a panic(). This for example allows a LinuxKPI based graphics
stack to receive prints during a panic.
Obtained from: kmacy @
MFC after: 1 week
Sponsored by: Mellanox Technologies
Diffstat (limited to 'sys/compat/linuxkpi/common/include/linux/sched.h')
-rw-r--r-- | sys/compat/linuxkpi/common/include/linux/sched.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/sched.h b/sys/compat/linuxkpi/common/include/linux/sched.h index bdaf7ae..c9f2a39 100644 --- a/sys/compat/linuxkpi/common/include/linux/sched.h +++ b/sys/compat/linuxkpi/common/include/linux/sched.h @@ -91,7 +91,7 @@ CTASSERT(sizeof(((struct thread *)0)->td_retval[1]) >= sizeof(uintptr_t)); do { \ void *c; \ \ - if (cold) \ + if (cold || SCHEDULER_STOPPED()) \ break; \ c = curthread; \ sleepq_lock(c); \ |