kernel: Undo changes to pinned threads and blocking.

This reverts commit 58ed2965d0.
This reverts commit 055d49b1fd.

I was mistaken, it is perfectly legal to block a pinned thread.
It seems we'll need some other way to detect invalid context
switches.
This commit is contained in:
Augustin Cavalier 2019-02-20 10:33:36 -05:00
parent 055d49b1fd
commit 13c4bc94ca
2 changed files with 0 additions and 7 deletions

View File

@ -233,9 +233,7 @@ x86_hardware_interrupt(struct iframe* frame)
apic_end_of_interrupt();
}
thread->pinned_to_cpu++;
int_io_interrupt_handler(vector, levelTriggered);
thread->pinned_to_cpu--;
if (levelTriggered) {
if (!sCurrentPIC->end_of_interrupt(vector))

View File

@ -2847,11 +2847,6 @@ thread_block_timeout(timer* timer)
static inline status_t
thread_block_locked(Thread* thread)
{
if (thread->pinned_to_cpu > 0) {
panic("attempting to block thread %" B_PRId32 ", which is pinned!",
thread->id);
}
if (thread->wait.status == 1) {
// check for signals, if interruptible
if (thread_is_interrupted(thread, thread->wait.flags)) {