|
|
@@ -1139,6 +1139,9 @@ again:
|
|
|
bi->bi_io_vec[0].bv_len = STRIPE_SIZE;
|
|
|
bi->bi_io_vec[0].bv_offset = 0;
|
|
|
bi->bi_iter.bi_size = STRIPE_SIZE;
|
|
|
+ bi->bi_write_hint = sh->dev[i].write_hint;
|
|
|
+ if (!rrdev)
|
|
|
+ sh->dev[i].write_hint = RWF_WRITE_LIFE_NOT_SET;
|
|
|
/*
|
|
|
* If this is discard request, set bi_vcnt 0. We don't
|
|
|
* want to confuse SCSI because SCSI will replace payload
|
|
|
@@ -1190,6 +1193,8 @@ again:
|
|
|
rbi->bi_io_vec[0].bv_len = STRIPE_SIZE;
|
|
|
rbi->bi_io_vec[0].bv_offset = 0;
|
|
|
rbi->bi_iter.bi_size = STRIPE_SIZE;
|
|
|
+ rbi->bi_write_hint = sh->dev[i].write_hint;
|
|
|
+ sh->dev[i].write_hint = RWF_WRITE_LIFE_NOT_SET;
|
|
|
/*
|
|
|
* If this is discard request, set bi_vcnt 0. We don't
|
|
|
* want to confuse SCSI because SCSI will replace payload
|
|
|
@@ -3204,6 +3209,7 @@ static int add_stripe_bio(struct stripe_head *sh, struct bio *bi, int dd_idx,
|
|
|
(unsigned long long)sh->sector);
|
|
|
|
|
|
spin_lock_irq(&sh->stripe_lock);
|
|
|
+ sh->dev[dd_idx].write_hint = bi->bi_write_hint;
|
|
|
/* Don't allow new IO added to stripes in batch list */
|
|
|
if (sh->batch_head)
|
|
|
goto overlap;
|