CVSROOT: /cvs Module name: src Changes by: m...@cvs.openbsd.org 2014/07/10 06:21:09
Modified files: sys/kern : vfs_subr.c sys/dev : softraid.c softraidvar.h Log message: Stop using a shutdown hook for softraid(4) and explicitly shutdown the disciplines right after vfs_shutdown(). This change is required in order to be able to set `cold' to 1 before traversing the device (mainbus) tree for DVACT_POWERDOWN when halting a machine. Yes, this is ugly because sr_shutdown() needs to sleep. But at least it is obvious and hopefully somebody will be ofended and fix it. In order to properly flush the cache of the disks under softraid0, sr_shutdown() now propagates DVACT_POWERDOWN for this particular subtree of devices which are not under mainbus. As a side effect sd(4) shutdown hook should no longer be necessary. Tested by stsp@ and Jean-Philippe Ouellet. ok deraadt@, stsp@, jsing@