Commit 00c85b65 authored by Christophe JAILLET's avatar Christophe JAILLET Committed by Jason Gunthorpe
Browse files

RDMA/rtrs: Remove a useless kfree()

'sess->rbufs' is known to be NULL here, so there is no point in kfree'ing
it.

Fixes: 6a98d71d ("RDMA/rtrs: client: main functionality")
Link: https://lore.kernel.org/r/9a57c9f837fa2c6f0070578a1bc4840688f62962.1628185335.git.christophe.jaillet@wanadoo.fr


Signed-off-by: default avatarChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Acked-by: default avatarMd Haris Iqbal <haris.iqbal@ionos.com>
Signed-off-by: default avatarJason Gunthorpe <jgg@nvidia.com>
parent c4c7d7a4
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -1844,7 +1844,6 @@ static int rtrs_rdma_conn_established(struct rtrs_clt_con *con,
		}

		if (!sess->rbufs) {
			kfree(sess->rbufs);
			sess->rbufs = kcalloc(queue_depth, sizeof(*sess->rbufs),
					      GFP_KERNEL);
			if (!sess->rbufs)