All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Kalderon <michal.kalderon@marvell.com>
To: <michal.kalderon@marvell.com>, <ariel.elior@marvell.com>,
	<dledford@redhat.com>, <jgg@ziepe.ca>
Cc: <linux-rdma@vger.kernel.org>
Subject: [PATCH v4 rdma-next 1/4] RDMA/qedr: Fix srqs xarray initialization
Date: Sun, 27 Oct 2019 22:04:48 +0200	[thread overview]
Message-ID: <20191027200451.28187-2-michal.kalderon@marvell.com> (raw)
In-Reply-To: <20191027200451.28187-1-michal.kalderon@marvell.com>

There was a missing initialization for the srqs xarray.
SRQs xarray can also be called from irq context when searching
for an element and uses the xa_XXX_irq apis, therefore should
be initialized with IRQ flags.

Fixes: 9fd15987ed27 ("qedr: Convert srqidr to XArray")
Signed-off-by: Ariel Elior <ariel.elior@marvell.com>
Signed-off-by: Michal Kalderon <michal.kalderon@marvell.com>
---
 drivers/infiniband/hw/qedr/main.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/infiniband/hw/qedr/main.c b/drivers/infiniband/hw/qedr/main.c
index 5136b835e1ba..aa0bda428690 100644
--- a/drivers/infiniband/hw/qedr/main.c
+++ b/drivers/infiniband/hw/qedr/main.c
@@ -357,6 +357,7 @@ static int qedr_alloc_resources(struct qedr_dev *dev)
 		return -ENOMEM;
 
 	spin_lock_init(&dev->sgid_lock);
+	xa_init_flags(&dev->srqs, XA_FLAGS_LOCK_IRQ);
 
 	if (IS_IWARP(dev)) {
 		xa_init_flags(&dev->qps, XA_FLAGS_LOCK_IRQ);
-- 
2.14.5


  reply	other threads:[~2019-10-27 20:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-27 20:04 [PATCH v4 rdma-next 0/4] RDMA/qedr: Fix memory leaks and synchronization Michal Kalderon
2019-10-27 20:04 ` Michal Kalderon [this message]
2019-10-27 20:04 ` [PATCH v4 rdma-next 2/4] RDMA/qedr: Fix qpids xarray api used Michal Kalderon
2019-10-27 20:04 ` [PATCH v4 rdma-next 3/4] RDMA/qedr: Fix synchronization methods and memory leaks in qedr Michal Kalderon
2019-10-27 20:04 ` [PATCH v4 rdma-next 4/4] RDMA/qedr: Fix memory leak in user qp and mr Michal Kalderon
2019-10-28 17:07 ` [PATCH v4 rdma-next 0/4] RDMA/qedr: Fix memory leaks and synchronization Jason Gunthorpe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191027200451.28187-2-michal.kalderon@marvell.com \
    --to=michal.kalderon@marvell.com \
    --cc=ariel.elior@marvell.com \
    --cc=dledford@redhat.com \
    --cc=jgg@ziepe.ca \
    --cc=linux-rdma@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.