git: DragonFly_RELEASE_4_8 Make sure that cam(4)'s dashutdown handler runs before DEVICE_SHUTDOWN().

Sascha Wildner swildner at crater.dragonflybsd.org
Sun Jul 30 12:43:49 PDT 2017


commit 2fdb51aedcdcff7a250c31f7d302df12e8e75ed2
Author: Imre Vadász <imre at vdsz.com>
Date:   Sun Jul 30 16:08:58 2017 +0200

    Make sure that cam(4)'s dashutdown handler runs before DEVICE_SHUTDOWN().
    
    This meant, that the DEVICE_SHUTDOWN() callback of scsi drivers was running
    before the final SYNCHRONIZE_CACHE scsi command was sent by cam(4). For
    most drivers this was still fine, since usually the DEVICE_SHUTDOWN()
    callback - if it's even implemented - only flushes the command queue.
    
    This change avoids freezing at the end of shutdown which was known to
    happen with the twa(4), and virtio_scsi(4) drivers.
    
    The SHUTDOWN_PRI_SECOND priority is selected, because it's so far unused,
    and inbetween existing handlers in the shutdown_post_sync phase, that are
    at SHUTDOWN_PRI_FIRST and at SHUTDOWN_PRI_DEFAULT.
    
    Tested-by: swildner (on twa(4)), ivadasz (on virtio_scsi(4))

Summary of changes:
 sys/bus/cam/scsi/scsi_da.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/2fdb51aedcdcff7a250c31f7d302df12e8e75ed2


-- 
DragonFly BSD source repository



More information about the Commits mailing list