• A
    [PATCH] fault-injection capability for disk IO · c17bb495
    Akinobu Mita 提交于
    This patch provides fault-injection capability for disk IO.
    
    Boot option:
    
    fail_make_request=<probability>,<interval>,<space>,<times>
    
    	<interval> -- specifies the interval of failures.
    
    	<probability> -- specifies how often it should fail in percent.
    
    	<space> -- specifies the size of free space where disk IO can be issued
    		   safely in bytes.
    
    	<times> -- specifies how many times failures may happen at most.
    
    Debugfs:
    
    /debug/fail_make_request/interval
    /debug/fail_make_request/probability
    /debug/fail_make_request/specifies
    /debug/fail_make_request/times
    
    Example:
    
    	fail_make_request=10,100,0,-1
    	echo 1 > /sys/blocks/hda/hda1/make-it-fail
    
    generic_make_request() on /dev/hda1 fails once per 10 times.
    
    Cc: Jens Axboe <axboe@suse.de>
    Signed-off-by: NAkinobu Mita <akinobu.mita@gmail.com>
    Signed-off-by: NAndrew Morton <akpm@osdl.org>
    Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
    c17bb495
genhd.c 17.4 KB