The patch titled
device-mapper multipath: Barriers not supported
has been added to the -mm tree. Its filename is
device-mapper-multipath-barriers-not-supported.patch
Patches currently in -mm which might be from [EMAIL PROTECTED] are
device-mapper-multipath-barriers-not-supported.patch
device-mapper-multipath-flush-workqueue-when-destroying.patch
device-mapper-multipath-avoid-possible-suspension-deadlock.patch
device-mapper-multipath-fix-pg-initialisation-races.patch
device-mapper-fix-dm_swap_table-error-cases.patch
device-mapper-snapshots-handle-origin-extension.patch
From: Alasdair G Kergon <[EMAIL PROTECTED]>
dm multipath will report barriers as not supported with this patch.
Signed-off-by: Lars Marowsky-Bree <[EMAIL PROTECTED]>
Signed-off-by: Alasdair G Kergon <[EMAIL PROTECTED]>
Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
---
drivers/md/dm-mpath.c | 6 ++++++
drivers/md/dm-snap.c | 2 +-
drivers/md/dm.c | 2 +-
3 files changed, 8 insertions(+), 2 deletions(-)
diff -puN drivers/md/dm.c~device-mapper-multipath-barriers-not-supported
drivers/md/dm.c
--- 25/drivers/md/dm.c~device-mapper-multipath-barriers-not-supported Fri Jul
8 16:45:27 2005
+++ 25-akpm/drivers/md/dm.c Fri Jul 8 16:45:27 2005
@@ -384,7 +384,7 @@ static void __map_bio(struct dm_target *
/* error the io and bail out */
struct dm_io *io = tio->io;
free_tio(tio->io->md, tio);
- dec_pending(io, -EIO);
+ dec_pending(io, r);
bio_put(clone);
}
}
diff -puN drivers/md/dm-mpath.c~device-mapper-multipath-barriers-not-supported
drivers/md/dm-mpath.c
--- 25/drivers/md/dm-mpath.c~device-mapper-multipath-barriers-not-supported
Fri Jul 8 16:45:27 2005
+++ 25-akpm/drivers/md/dm-mpath.c Fri Jul 8 16:45:27 2005
@@ -765,6 +765,9 @@ static int multipath_map(struct dm_targe
struct mpath_io *mpio;
struct multipath *m = (struct multipath *) ti->private;
+ if (bio_barrier(bio))
+ return -EOPNOTSUPP;
+
mpio = mempool_alloc(m->mpio_pool, GFP_NOIO);
dm_bio_record(&mpio->details, bio);
@@ -988,6 +991,9 @@ static int do_end_io(struct multipath *m
if ((error == -EWOULDBLOCK) && bio_rw_ahead(bio))
return error;
+ if (error == -EOPNOTSUPP)
+ return error;
+
spin_lock(&m->lock);
if (!m->nr_valid_paths) {
if (!m->queue_if_no_path || m->suspended) {
diff -puN drivers/md/dm-snap.c~device-mapper-multipath-barriers-not-supported
drivers/md/dm-snap.c
--- 25/drivers/md/dm-snap.c~device-mapper-multipath-barriers-not-supported
Fri Jul 8 16:45:27 2005
+++ 25-akpm/drivers/md/dm-snap.c Fri Jul 8 16:45:27 2005
@@ -777,7 +777,7 @@ static int snapshot_map(struct dm_target
/* Full snapshots are not usable */
if (!s->valid)
- return -1;
+ return -EIO;
/*
* Write to snapshot - higher level takes care of RW/RO
_
-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html