• Kent Overstreet's avatar
    bcachefs: Mark stripe buckets with correct data type · 91065976
    Kent Overstreet authored
    Currently, we don't use bucket data type for tracking whether buckets
    are part of a stripe; parity buckets are BCH_DATA_parity, but data
    buckets in a stripe are BCH_DATA_user. There's a separate counter,
    buckets_ec, outside the BCH_DATA_TYPES system for tracking number of
    buckets on a device that are part of a stripe.
    
    The trouble with this approach is that it's too coarse grained, and we
    need better information on fragmentation for debugging copygc.
    
    With this patch, data buckets in a stripe are now tracked as
    BCH_DATA_stripe buckets.
    
    This doesn't yet differentiate between erasure coded and non-erasure
    coded data in a stripe bucket, nor do we yet track empty data buckets in
    stripes.
    Signed-off-by: default avatarKent Overstreet <kent.overstreet@linux.dev>
    91065976
movinggc.c 6.37 KB