diff options
author | Mike Snitzer <snitzer@redhat.com> | 2014-05-13 13:49:39 -0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2014-05-14 16:12:17 -0400 |
commit | 4cdd2ad78098244c1bc9ec4374ea1c225fd1cd6f (patch) | |
tree | 9892d1a825e80cd6299ec49e3279166124a551f9 | |
parent | 85ad643b7e7e52d37620fb272a9fd577a8095647 (diff) | |
download | linux-4cdd2ad78098244c1bc9ec4374ea1c225fd1cd6f.tar.bz2 |
dm mpath: fix lock order inconsistency in multipath_ioctl
Commit 3e9f1be1b40 ("dm mpath: remove process_queued_ios()") did not
consistently take the multipath device's spinlock (m->lock) before
calling dm_table_run_md_queue_async() -- which takes the q->queue_lock.
Found with code inspection using hint from reported lockdep warning.
Reported-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
-rw-r--r-- | drivers/md/dm-mpath.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/dm-mpath.c b/drivers/md/dm-mpath.c index aa009e865871..fa0f6cbd6a41 100644 --- a/drivers/md/dm-mpath.c +++ b/drivers/md/dm-mpath.c @@ -1566,8 +1566,8 @@ static int multipath_ioctl(struct dm_target *ti, unsigned int cmd, } if (m->pg_init_required) __pg_init_all_paths(m); - spin_unlock_irqrestore(&m->lock, flags); dm_table_run_md_queue_async(m->ti->table); + spin_unlock_irqrestore(&m->lock, flags); } return r ? : __blkdev_driver_ioctl(bdev, mode, cmd, arg); |