aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/dm.c
diff options
context:
space:
mode:
authorMikulas Patocka <mpatocka@redhat.com>2009-04-08 19:27:13 -0400
committerAlasdair G Kergon <agk@redhat.com>2009-04-08 19:27:13 -0400
commit692d0eb9e02cf81fb387ff891f53840db2f3110a (patch)
tree0e6aa42d81cd47c55de37b55d2ffad419fe57cd0 /drivers/md/dm.c
parent9c47008d13add50ec4597a8b9eee200c515282c8 (diff)
dm: remove limited barrier support
Prepare for full barrier implementation: first remove the restricted support. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Diffstat (limited to 'drivers/md/dm.c')
-rw-r--r--drivers/md/dm.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index 25d86e2c01f2..ab3b5d84df65 100644
--- a/drivers/md/dm.c
+++ b/drivers/md/dm.c
@@ -851,11 +851,7 @@ static void __split_and_process_bio(struct mapped_device *md, struct bio *bio)
851 bio_io_error(bio); 851 bio_io_error(bio);
852 return; 852 return;
853 } 853 }
854 if (unlikely(bio_barrier(bio) && !dm_table_barrier_ok(ci.map))) { 854
855 dm_table_put(ci.map);
856 bio_endio(bio, -EOPNOTSUPP);
857 return;
858 }
859 ci.md = md; 855 ci.md = md;
860 ci.bio = bio; 856 ci.bio = bio;
861 ci.io = alloc_io(md); 857 ci.io = alloc_io(md);
@@ -937,6 +933,15 @@ static int dm_request(struct request_queue *q, struct bio *bio)
937 struct mapped_device *md = q->queuedata; 933 struct mapped_device *md = q->queuedata;
938 int cpu; 934 int cpu;
939 935
936 /*
937 * There is no use in forwarding any barrier request since we can't
938 * guarantee it is (or can be) handled by the targets correctly.
939 */
940 if (unlikely(bio_barrier(bio))) {
941 bio_endio(bio, -EOPNOTSUPP);
942 return 0;
943 }
944
940 down_read(&md->io_lock); 945 down_read(&md->io_lock);
941 946
942 cpu = part_stat_lock(); 947 cpu = part_stat_lock();