From: Kalesh AP Date: Thu, 14 Aug 2025 11:25:54 +0000 (+0530) Subject: RDMA/bnxt_re: Delete always true SGID table check X-Git-Tag: v6.18-rc1~102^2~66 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4a9fba4d008a0d395407224f18def611ee85ba09;p=thirdparty%2Flinux.git RDMA/bnxt_re: Delete always true SGID table check The "sgid_tbl" inside "rdev->qplib_res" is a static memory. Hence, the check always return true. Signed-off-by: Kalesh AP Link: https://patch.msgid.link/20250814112555.221665-9-kalesh-anakkur.purayil@broadcom.com Signed-off-by: Leon Romanovsky --- diff --git a/drivers/infiniband/hw/bnxt_re/ib_verbs.c b/drivers/infiniband/hw/bnxt_re/ib_verbs.c index 98bc8b6290f1..195a9ba6f65d 100644 --- a/drivers/infiniband/hw/bnxt_re/ib_verbs.c +++ b/drivers/infiniband/hw/bnxt_re/ib_verbs.c @@ -375,7 +375,7 @@ int bnxt_re_del_gid(const struct ib_gid_attr *attr, void **context) if (!ctx) return -EINVAL; - if (sgid_tbl && sgid_tbl->active) { + if (sgid_tbl->active) { if (ctx->idx >= sgid_tbl->max) return -EINVAL; gid_to_del = &sgid_tbl->tbl[ctx->idx].gid;