From b45f6d8d81d0f94897a3909c92a54f4e7eca367a Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Thu, 18 Dec 2014 00:51:12 +0000 Subject: [PATCH] process: flag a tiny race I think we can just remove the restore, but needs checking over --- Kernel/process.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Kernel/process.c b/Kernel/process.c index 647a28b4..cdebd25e 100644 --- a/Kernel/process.c +++ b/Kernel/process.c @@ -40,6 +40,8 @@ void psleep(void *event) udata.u_ptab->p_waitno = ++waitno; nready--; + /* FIXME: we don't want to restore interrupts here, but what + is the consequence */ irqrestore(irq); switchout(); /* Switch us out, and start another process */ /* Switchout doesn't return in this context until we have been switched back in, of course. */ -- 2.34.1