DragonFly BSD
DragonFly commits List (threaded) for 2012-11
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

git: mfi(4): Don't assert lock holding when dumping or during a panic.


From: Sascha Wildner <swildner@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 7 Nov 2012 13:13:20 -0800 (PST)

commit 148e9c0bc3408f258f158bf6fb40ab19ce200cf0
Author: Sascha Wildner <saw@online.de>
Date:   Wed Nov 7 22:10:51 2012 +0100

    mfi(4): Don't assert lock holding when dumping or during a panic.
    
    FreeBSD's mtx_assert() does it the same way, but we usually translate
    mtx_assert() into a KKASSERT(lockstatus(&lock, curthread) != 0).
    
    For now, replace all of these assertions in mfi(4) with a function that
    mimics the mtx_assert() behavior of FreeBSD, since some of the asserting
    functions are used by the dumping code.
    
    We might think about a real lockassert() function in the future that
    has this exception too.
    
    This commit fixes dumping on most supported adapters. Thunderbolt series
    adapters still have an (unrelated) command timeout issue which I'm
    looking at.
    
    Reported and tested (on a PERC 5/i) by Tim Howe <tim@130collective.org>.

Summary of changes:
 sys/dev/raid/mfi/mfi.c       |   28 ++++++++++++++--------------
 sys/dev/raid/mfi/mfi_cam.c   |    2 +-
 sys/dev/raid/mfi/mfi_disk.c  |    4 ++--
 sys/dev/raid/mfi/mfi_syspd.c |    4 ++--
 sys/dev/raid/mfi/mfi_tbolt.c |    6 +++---
 sys/dev/raid/mfi/mfivar.h    |   11 +++++++++++
 6 files changed, 33 insertions(+), 22 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/148e9c0bc3408f258f158bf6fb40ab19ce200cf0


-- 
DragonFly BSD source repository



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]