Lines Matching defs:stripe

35 #include "raid-stripe-tree.h"
3863 struct btrfs_stripe *stripe;
3868 stripe = btrfs_stripe_nr(chunk, i);
3869 if (btrfs_stripe_devid(leaf, stripe) == bargs->devid)
3889 struct btrfs_stripe *stripe;
3904 stripe = btrfs_stripe_nr(chunk, i);
3905 if (btrfs_stripe_devid(leaf, stripe) != bargs->devid)
3908 stripe_offset = btrfs_stripe_offset(leaf, stripe);
5291 * The DUP profile stores more than one stripe per device, the
5402 struct btrfs_io_stripe *stripe = &map->stripes[i];
5403 struct btrfs_device *device = stripe->dev;
5405 btrfs_set_extent_bit(&device->alloc_state, stripe->physical,
5406 stripe->physical + map->stripe_size - 1,
5414 struct btrfs_io_stripe *stripe = &map->stripes[i];
5415 struct btrfs_device *device = stripe->dev;
5417 btrfs_clear_extent_bit(&device->alloc_state, stripe->physical,
5418 stripe->physical + map->stripe_size - 1,
5617 struct btrfs_stripe *stripe;
5638 * not exists, or persisting a stripe of the chunk item with such ID.
5671 stripe = &chunk->stripe;
5676 btrfs_set_stack_stripe_devid(stripe, device->devid);
5677 btrfs_set_stack_stripe_offset(stripe, dev_offset);
5678 memcpy(stripe->dev_uuid, device->uuid, BTRFS_UUID_SIZE);
5679 stripe++;
5839 * Fail a stripe at a time on every retry except the stripe under
5898 /* If no read-preferred device is set use the first stripe. */
5920 * Select a stripe for reading using the round-robin algorithm.
5924 * 2. Determine the stripe number for the current read by taking the modulus
5927 * stripe index = (total sectors / min sectors per dev) % num stripes
5929 * The calculated stripe index is then used to select the corresponding device
6107 /* stripe_offset is the offset of this block in its stripe */
6118 * the number of our device in the stripe array
6167 * Special for the first stripe and
6168 * the last stripe:
6268 * For GET_READ_MIRRORS, we can only return at most 1 extra stripe for
6281 * Swap the last stripe stripes and reduce @nr_extra_stripes.
6282 * The extra stripe would still be there, but won't be accessed.
6300 * Stripe_nr is the stripe where this block falls. stripe_offset is
6301 * the offset of this block in its stripe.
6313 * For full stripe start, we use previously calculated
6331 * For writes to RAID56, allow to write a full stripe set, but
6332 * no straddling of stripe sets.
6339 * For other RAID types and for RAID56 reads, allow a single stripe (on
6466 * Needs full stripe mapping.
6468 * Push stripe_nr back to the start of the full stripe For those cases
6469 * needing a full stripe, @stripe_nr is the full stripe number.
6481 /* Return the length to the full stripe end. */
6496 /* Just grab the data stripe directly. */
6521 * due to factors like zones and RAID0/5/6/10 stripe
6548 * data/P stripe error and rebuild from the remaining
6625 * the number of our device in the stripe array
6632 "stripe index math went horribly wrong, got stripe_index=%u, num_stripes=%u",
6705 * stripe into the bioc.
8213 * - The range does not cross stripe boundary
8232 /* The map range should not cross stripe boundary. */
8235 /* Already mapped to single stripe. */
8239 /* Map the RAID56 multi-stripe writes to a single one. */