arch/i386/kernel/signals.c: recalc_sigpending without spinlock

Manfred Spraul manfreds en colorfullife.com
Vie Ene 21 05:59:49 CST 2000


I think there is an error in do_signal():

       default:
            lock_kernel();
            sigaddset(&current->signal, signr);
            recalc_sigpending(current);
            current->flags |= PF_SIGNALED;
            do_exit(exit_code);
            /* NOTREACHED */
      }

I haven't checked the details of the signal delivery, but it seems that
the lock_kernel() is superflous, and
spin_lock_irq(&current->sigmask_lock) is missing:


       default:
            spin_lock_irq(&current->sigmask_lock);
            sigaddset(&current->signal, signr);
            recalc_sigpending(current);
	    spin_unlock_irq(&current->sigmask_lock);
            current->flags |= PF_SIGNALED;
            do_exit(exit_code);
            /* NOTREACHED */
      }

--
	Manfred



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo en vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



Más información sobre la lista de distribución Ayuda