X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fthreads%2Fsynch.c;h=317c68ad501301538f47a697df7a8eaf02d4e077;hb=a03618133f7df0954802a470a4bee7674f7aed45;hp=c2764bc38d1cdb3b47efb0f0a43f8d694d493947;hpb=c51576b5aedc01da14c5f29527884f4bea49d544;p=pintos-anon diff --git a/src/threads/synch.c b/src/threads/synch.c index c2764bc..317c68a 100644 --- a/src/threads/synch.c +++ b/src/threads/synch.c @@ -55,8 +55,8 @@ sema_init (struct semaphore *sema, unsigned value) This function may sleep, so it must not be called within an interrupt handler. This function may be called with - interrupts disabled, but interrupts will be turned back on if - we need to sleep. */ + interrupts disabled, but if it sleeps then the next scheduled + thread will probably turn interrupts back on. */ void sema_down (struct semaphore *sema) {