]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
dm mpath: do not lock up a CPU with requeuing activity
authorBart Van Assche <bart.vanassche@wdc.com>
Wed, 9 Aug 2017 18:32:12 +0000 (11:32 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 7 Sep 2017 06:37:16 +0000 (08:37 +0200)
commit 1c23484c355ec360ca2f37914f8a4802c6baeead upstream.

When using the block layer in single queue mode, get_request()
returns ERR_PTR(-EAGAIN) if the queue is dying and the REQ_NOWAIT
flag has been passed to get_request(). Avoid that the kernel
reports soft lockup complaints in this case due to continuous
requeuing activity.

Fixes: 7083abbbf ("dm mpath: avoid that path removal can trigger an infinite loop")
Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
Tested-by: Laurence Oberman <loberman@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/md/dm-mpath.c

index 3df056b73b6610927a57058394a5bbe08f1b3404..fa0df4a3e1bedaf7752e896a0c31751c20d2c8c0 100644 (file)
@@ -504,7 +504,6 @@ static int multipath_clone_and_map(struct dm_target *ti, struct request *rq,
                if (queue_dying) {
                        atomic_inc(&m->pg_init_in_progress);
                        activate_or_offline_path(pgpath);
-                       return DM_MAPIO_REQUEUE;
                }
                return DM_MAPIO_DELAY_REQUEUE;
        }