git: MPSAFE TTY - Refactor the keyboard switch code to make all drivers MPSAFE

Matthew Dillon dillon at crater.dragonflybsd.org
Sun Aug 29 13:50:37 PDT 2010


commit fc9700a1359c0dd3fa2c207933975ed59237ba2b
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Sun Aug 29 13:45:58 2010 -0700

    MPSAFE TTY - Refactor the keyboard switch code to make all drivers MPSAFE
    
    * Add a per-kbd lock.
    
    * Replace the keyboard kbd_*() macros with function wrappers which acquire
      and release the per-kbd lock on behalf of each keyboard driver.  The
      wrapper code also understands polled mode and will not acquire/release
      locks in polled mode (aka debugger).
    
    * Remove all tokens and locks from the keyboard drivers.
    
    * Do some documenting of non-blocking paths.

Summary of changes:
 sys/dev/misc/atkbd/atkbd_isa.c |    4 +-
 sys/dev/misc/kbd/atkbd.c       |   92 +------------
 sys/dev/misc/kbd/kbd.c         |    5 +
 sys/dev/misc/kbd/kbdreg.h      |  103 ++++++++------
 sys/dev/misc/kbd/kbdsw.c       |  295 +++++++++++++++++++++++++++++++++++++++
 sys/dev/misc/kbdmux/kbdmux.c   |  296 ++++++----------------------------------
 sys/dev/misc/syscons/syscons.c |   12 ++
 sys/dev/usbmisc/ukbd/ukbd.c    |  139 ++-----------------
 sys/platform/pc32/conf/files   |    4 +
 sys/platform/pc64/conf/files   |    4 +
 10 files changed, 443 insertions(+), 511 deletions(-)
 create mode 100644 sys/dev/misc/kbd/kbdsw.c

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/fc9700a1359c0dd3fa2c207933975ed59237ba2b


-- 
DragonFly BSD source repository





More information about the Commits mailing list