RDMA/rtrs-clt: Check if the queue_depth has changed during a reconnection
authorMd Haris Iqbal <haris.iqbal@cloud.ionos.com>
Fri, 28 May 2021 11:30:17 +0000 (13:30 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Jul 2021 15:07:01 +0000 (17:07 +0200)
commit84d3b0760dfc0d0ecb95ca9bf54ab77b16eb6ed0
tree6da686d586055c0d19e7b2c113ba84d91dcf111f
parentb69606171c143ac34a6791d5316fd5b4fbf16b1f
RDMA/rtrs-clt: Check if the queue_depth has changed during a reconnection

[ Upstream commit 5b73b799c25c68a4703cd6c5ac4518006d9865b8 ]

The queue_depth is a module parameter for rtrs_server. It is used on the
client side to determing the queue_depth of the request queue for the RNBD
virtual block device.

During a reconnection event for an already mapped device, in case the
rtrs_server module queue_depth has changed, fail the reconnect attempt.

Also stop further auto reconnection attempts. A manual reconnect via
sysfs has to be triggerred.

Fixes: 6a98d71daea18 ("RDMA/rtrs: client: main functionality")
Link: https://lore.kernel.org/r/20210528113018.52290-20-jinpu.wang@ionos.com
Signed-off-by: Md Haris Iqbal <haris.iqbal@ionos.com>
Signed-off-by: Gioh Kim <gi-oh.kim@ionos.com>
Signed-off-by: Jack Wang <jinpu.wang@ionos.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/infiniband/ulp/rtrs/rtrs-clt.c