aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/raid1.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2016-06-09 10:00:36 -0400
committerJens Axboe <axboe@fb.com>2016-06-09 11:52:25 -0400
commit288dab8a35a0bde426a09870943c8d3ee3a50dab (patch)
tree483fd3eb60ff8f44d149fb28d3b79e5212645104 /drivers/md/raid1.c
parent56332f02a562390a3198525ad78cb4f558805c0f (diff)
block: add a separate operation type for secure erase
Instead of overloading the discard support with the REQ_SECURE flag. Use the opportunity to rename the queue flag as well, and remove the dead checks for this flag in the RAID 1 and RAID 10 drivers that don't claim support for secure erase. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'drivers/md/raid1.c')
-rw-r--r--drivers/md/raid1.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c
index 10e53cd6a995..41d9c31da3b3 100644
--- a/drivers/md/raid1.c
+++ b/drivers/md/raid1.c
@@ -1058,7 +1058,6 @@ static void raid1_make_request(struct mddev *mddev, struct bio * bio)
1058 const unsigned long do_sync = (bio->bi_rw & REQ_SYNC); 1058 const unsigned long do_sync = (bio->bi_rw & REQ_SYNC);
1059 const unsigned long do_flush_fua = (bio->bi_rw & 1059 const unsigned long do_flush_fua = (bio->bi_rw &
1060 (REQ_PREFLUSH | REQ_FUA)); 1060 (REQ_PREFLUSH | REQ_FUA));
1061 const unsigned long do_sec = (bio->bi_rw & REQ_SECURE);
1062 struct md_rdev *blocked_rdev; 1061 struct md_rdev *blocked_rdev;
1063 struct blk_plug_cb *cb; 1062 struct blk_plug_cb *cb;
1064 struct raid1_plug_cb *plug = NULL; 1063 struct raid1_plug_cb *plug = NULL;
@@ -1376,7 +1375,7 @@ read_again:
1376 conf->mirrors[i].rdev->data_offset); 1375 conf->mirrors[i].rdev->data_offset);
1377 mbio->bi_bdev = conf->mirrors[i].rdev->bdev; 1376 mbio->bi_bdev = conf->mirrors[i].rdev->bdev;
1378 mbio->bi_end_io = raid1_end_write_request; 1377 mbio->bi_end_io = raid1_end_write_request;
1379 bio_set_op_attrs(mbio, op, do_flush_fua | do_sync | do_sec); 1378 bio_set_op_attrs(mbio, op, do_flush_fua | do_sync);
1380 mbio->bi_private = r1_bio; 1379 mbio->bi_private = r1_bio;
1381 1380
1382 atomic_inc(&r1_bio->remaining); 1381 atomic_inc(&r1_bio->remaining);