Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp777743ybc; Sat, 16 Nov 2019 08:31:01 -0800 (PST) X-Google-Smtp-Source: APXvYqziy9OJw9t34kx8+1i2piM55qMHxukH1cpLXD0lFeECBPyRfH8R5uAkO4X0p+RAxe0L3QhI X-Received: by 2002:a17:906:4409:: with SMTP id x9mr4577270ejo.236.1573921861482; Sat, 16 Nov 2019 08:31:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573921861; cv=none; d=google.com; s=arc-20160816; b=Q9JeftHXYzTV/ragWrrpntkdom2LlsrKHRdJ4jpBpUR3/Ki/tWttsD56WItAGZtBCZ vVDO+9u/CnTYDYMhZzkIDFLuH17L8JFW73aPKxBKnE60uJbU/0lh8zJZ/5AW7j2CBIZl A3CX1/ZjfsbkBxSaD0+IEQRjeSnH0Pkf7xjtUjdR+8jHlrvHpJ3VmXmfjGntQk7Uqfwo 5J71HMj2y/gKATpanXaK6V/gvr0QihC81ZJyL1Srdl3RQgpsHQMyNC1cKxKzUuTWbqZ5 PZf2yzvdCxYC/khnRdPcbFAkupaRq1FbuBZ9VgslEMyrHprBjyaUUTJMT/TxGkCNtYAB YKhg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=VZYgRh7xZEIfrONg9ha/qhVrl7f/tj8yIWx2Ytfir+I=; b=QrHzlHrr9Enn8Y+ARUnr51dsRJSXVbfMOMT/2RoFQYpTMXAwcJYWl/GebfHmHsVhsd +ke+W2hN7uGLB3rplaqAhJF2w3BCFoEwCz89egJqnpIQJuJLk7QGZV0o9YZ7aPwS9Rq8 21j/6UsCPpMPHOexPgD/J1wUPf/OtXT5x+VhaWQ7G8pRHrOnHukWJvhoDPx9B8I5T2h2 ecNG7wExkAdIwZGHB9fEJCqlWN1cNmq3APtxloa+bSIMW3IWXcIVDWAqkN4N45VfHhCn 0ZIygWD5GUrV0vOn0Gt3d3tk7gbXK42aljMnVeLqBbcoFlfGl2yFDOeY9xoamWFjlNJl nlqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=DWAAZuMg; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ck15si8182826ejb.358.2019.11.16.08.30.36; Sat, 16 Nov 2019 08:31:01 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=DWAAZuMg; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728092AbfKPPl7 (ORCPT + 99 others); Sat, 16 Nov 2019 10:41:59 -0500 Received: from mail.kernel.org ([198.145.29.99]:45320 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728049AbfKPPl4 (ORCPT ); Sat, 16 Nov 2019 10:41:56 -0500 Received: from sasha-vm.mshome.net (unknown [50.234.116.4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C06DC2084C; Sat, 16 Nov 2019 15:41:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1573918916; bh=N6n1vejcjZHQsQPa2gtPju+sXlhGmVg6/fyj4DwkZCs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DWAAZuMg6V3d8LWqETHEg9d/DUOkl2ZdWb/GLiPW1Drv2WAOsRKdUNwss2BxH/Pss MzlvVjDKjIcjQn49Cn5UYF0dyh5FnV7VaTU9D47XvEv3jrCfMo7Rru2beK/rS0Xw1y WolKpug1qa7QsuETe42xYyUPQcPVWb5GAmAO087Q= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Devesh Sharma , Selvin Xavier , Jason Gunthorpe , Sasha Levin , linux-rdma@vger.kernel.org Subject: [PATCH AUTOSEL 4.19 039/237] RDMA/bnxt_re: Fix qp async event reporting Date: Sat, 16 Nov 2019 10:37:54 -0500 Message-Id: <20191116154113.7417-39-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191116154113.7417-1-sashal@kernel.org> References: <20191116154113.7417-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Devesh Sharma [ Upstream commit 4c01f2e3a906a0d2d798be5751c331cf501bc129 ] Reports affiliated async event on the qp-async event channel instead of global event channel. Signed-off-by: Devesh Sharma Signed-off-by: Selvin Xavier Signed-off-by: Jason Gunthorpe Signed-off-by: Sasha Levin --- drivers/infiniband/hw/bnxt_re/main.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/drivers/infiniband/hw/bnxt_re/main.c b/drivers/infiniband/hw/bnxt_re/main.c index 22bd9784fa2ea..7ffad368c5fa1 100644 --- a/drivers/infiniband/hw/bnxt_re/main.c +++ b/drivers/infiniband/hw/bnxt_re/main.c @@ -989,12 +989,17 @@ static void bnxt_re_dispatch_event(struct ib_device *ibdev, struct ib_qp *qp, struct ib_event ib_event; ib_event.device = ibdev; - if (qp) + if (qp) { ib_event.element.qp = qp; - else + ib_event.event = event; + if (qp->event_handler) + qp->event_handler(&ib_event, qp->qp_context); + + } else { ib_event.element.port_num = port_num; - ib_event.event = event; - ib_dispatch_event(&ib_event); + ib_event.event = event; + ib_dispatch_event(&ib_event); + } } #define HWRM_QUEUE_PRI2COS_QCFG_INPUT_FLAGS_IVLAN 0x02 -- 2.20.1