• N
    [PATCH] md: Core of raid5 resize process · ccfcc3c1
    NeilBrown 提交于
    This patch provides the core of the resize/expand process.
    
    sync_request notices if a 'reshape' is happening and acts accordingly.
    
    It allocated new stripe_heads for the next chunk-wide-stripe in the target
    geometry, marking them STRIPE_EXPANDING.
    
    Then it finds which stripe heads in the old geometry can provide data needed
    by these and marks them STRIPE_EXPAND_SOURCE.  This causes stripe_handle to
    read all blocks on those stripes.
    
    Once all blocks on a STRIPE_EXPAND_SOURCE stripe_head are read, any that are
    needed are copied into the corresponding STRIPE_EXPANDING stripe_head.  Once a
    STRIPE_EXPANDING stripe_head is full, it is marks STRIPE_EXPAND_READY and then
    is written out and released.
    Signed-off-by: NNeil Brown <neilb@suse.de>
    Signed-off-by: NAndrew Morton <akpm@osdl.org>
    Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
    ccfcc3c1
raid5.h 10.8 KB