git: devfs - Introduce MPSAFE read/write/ioctl support

Alex Hornung alexh at crater.dragonflybsd.org
Mon Dec 21 00:33:16 PST 2009


commit 3a1032a61f3ea2b7ca93c34278f5220f31a9b9a6
Author: Alex Hornung <ahornung at gmail.com>
Date:   Mon Dec 21 08:22:46 2009 +0000

    devfs - Introduce MPSAFE read/write/ioctl support
    
    * Add D_MPSAFE_READ, D_MPSAFE_WRITE and D_MPSAFE_IOCTL defines for use
      with the dev_ops structure to mark the read,write and/or ioctl methods
      as mpsafe.
    
    * Change devfs so that it won't acquire the mplock for
      read/writes/ioctls that are marked as MPSAFE.
    
    * Add some statistics under sysctl vfs.devfs about the number of read
      and writes done with the mplock and without it.
    
    * While here, MPSAFE specf_stat in devfs so it doesn't acquire the
      mplock anymore as it doesn't even need it.

Summary of changes:
 sys/sys/device.h            |    3 +
 sys/vfs/devfs/devfs_core.c  |    2 +-
 sys/vfs/devfs/devfs_vnops.c |  121 +++++++++++++++++++++++++++----------------
 3 files changed, 80 insertions(+), 46 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/3a1032a61f3ea2b7ca93c34278f5220f31a9b9a6


-- 
DragonFly BSD source repository





More information about the Commits mailing list