cvs commit: src/sys/kern kern_sig.c kern_synch.c src/sys/machine/pc32/i386 machdep.c src/sys/machine/vkernel/i386 cpu_regs.c fork_tramp.s trap.c src/sys/machine/vkernel/include globaldata.h md_var.h src/sys/machine/vkernel/platform systimer.c ...

Matthew Dillon dillon at crater.dragonflybsd.org
Sun Jan 14 00:00:12 PST 2007


dillon      2007/01/13 23:59:09 PST

DragonFly src repository

  Modified files:
    sys/kern             kern_sig.c kern_synch.c 
    sys/machine/pc32/i386 machdep.c 
    sys/machine/vkernel/i386 cpu_regs.c fork_tramp.s trap.c 
    sys/machine/vkernel/include globaldata.h md_var.h 
    sys/machine/vkernel/platform systimer.c 
    sys/sys              proc.h signal.h signalvar.h 
    sys/vm               vm_vmspace.c 
  Log:
  Implement a new signal delivery mechanism, SA_MAILBOX.  If specified the
  sigaction structure's sa_mailbox pointer (field is unioned with sa_handler)
  points to a location in user memory.  When the signal occurs, the location
  is overwritten with the signal number and the next system call made (or
  the current one running) will return EINTR.  NO SIGNAL STATE IS PUSHED,
  NO SIGNAL VECTOR IS DISPATCHED.  This makes mailbox signaling very fast.
  
  Userland can interlock against the mailbox simply by polling and clearing
  the mailbox prior to doing a system call.  The mailbox signal will be
  properly interlocked against the system call.  Userland does not need to
  make any other system calls (no sigblock() or sigsetmask() calls) to
  properly interlock delivery.  The kernel interrupts at most one system call
  per signal delivered via this mechanism, even if the userland does not
  clear the mailbox.
  
  As of this implementatino, mailbox delivery can cause an extra 'false'
  interruption of a system call.  system calls do not currently poll installed
  mailboxes to deal with false hits.  Mailbox signaling is meant to be used
  under tightly managed conditions.
  
  Move the virtual kernel check from sendsig() to postsig().  Mailbox
  delivery must do any virtual kernel swaps prior to posting a mailbox signal.
  
  Adjust go_user() to take an interrupt frame instead of a trap frame.
  
  Replace the sigblock() based idle loop interlock with a mailbox interlock.
  Add mailbox checks to the go_user() vmspace_ctl() loop (currently a bit of
  a hack).
  
  Revision  Changes    Path
  1.61      +80 -18    src/sys/kern/kern_sig.c
  1.71      +27 -6     src/sys/kern/kern_synch.c
  1.115     +0 -11     src/sys/machine/pc32/i386/machdep.c
  1.10      +5 -13     src/sys/machine/vkernel/i386/cpu_regs.c
  1.2       +2 -0      src/sys/machine/vkernel/i386/fork_tramp.s
  1.12      +28 -29    src/sys/machine/vkernel/i386/trap.c
  1.5       +1 -1      src/sys/machine/vkernel/include/globaldata.h
  1.13      +2 -1      src/sys/machine/vkernel/include/md_var.h
  1.7       +20 -2     src/sys/machine/vkernel/platform/systimer.c
  1.90      +1 -1      src/sys/sys/proc.h
  1.6       +7 -2      src/sys/sys/signal.h
  1.16      +1 -0      src/sys/sys/signalvar.h
  1.10      +8 -0      src/sys/vm/vm_vmspace.c


http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_sig.c.diff?r1=1.60&r2=1.61&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_synch.c.diff?r1=1.70&r2=1.71&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/pc32/i386/machdep.c.diff?r1=1.114&r2=1.115&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/vkernel/i386/cpu_regs.c.diff?r1=1.9&r2=1.10&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/vkernel/i386/fork_tramp.s.diff?r1=1.1&r2=1.2&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/vkernel/i386/trap.c.diff?r1=1.11&r2=1.12&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/vkernel/include/globaldata.h.diff?r1=1.4&r2=1.5&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/vkernel/include/md_var.h.diff?r1=1.12&r2=1.13&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/machine/vkernel/platform/systimer.c.diff?r1=1.6&r2=1.7&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/proc.h.diff?r1=1.89&r2=1.90&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/signal.h.diff?r1=1.5&r2=1.6&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/signalvar.h.diff?r1=1.15&r2=1.16&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vm/vm_vmspace.c.diff?r1=1.9&r2=1.10&f=u





More information about the Commits mailing list