Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3130961ybi; Thu, 18 Jul 2019 21:38:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqxGRXvc3SebU9vNX4bpoKNcoVE9+b5Cjh1iCA6v2YIx982I+C2bQYzVinpZ3ssrzd0kbnY6 X-Received: by 2002:a63:ef4b:: with SMTP id c11mr49088635pgk.129.1563511081999; Thu, 18 Jul 2019 21:38:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563511081; cv=none; d=google.com; s=arc-20160816; b=kmoIv3I5HdMDNaoKQ5F0bYZxZr+ohsf9/SvQFF7w/wZ7Fjzthp23ZUfMWmDhQ7c+Og w87mxEcfsHW/E7Csy3pjMno0TaTdeDAQZCyl/1PS37dCuPFo2VTM3EeWXWvvHqEUYBZc ORbOrpva/kiYCje8lTOt+5szR/wV8WxycsnHGVwX3H9mLRUdV7HTicMLq08KqDi8PRLn JYJJNFdxYeO3JJNWzEt+iZ9HUFCK3PUdScfAAD2DA7hj0eRd+uTCk9TMUxecA2NXVqzU bqI9lwQJi6g3Cw26jRgpybieHZFWh7PHHwSRRyLiR1gvLtqRuM4bubWPsng5fWV2VeFT iY/g== 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=TTyfUiEVyVCDkmsJVg3EtdrzsFkSa/v80gPOh2II+sU=; b=PpuMGV/WKqh2dNbwSxKFYEbFhR8mRSIY1jPtohORy99GMZs6F0kDcQyuof08MwmwCQ LqHhDQuGRLlO1QYtWWtLPzE6axO242U7HNDTTFHRA/9yGp9Zy3KIz2c6ZcYZc7CnqMH9 FRr+WnMyYp+u4/H+4WguYvcRSly9Ood03cmLQ2wmVXsUYXcDFMJV5Xk2RhILTP3LmTYR dBAvcNDRMRCg9E/l4YTKX90iXbZVoFHDE19SeFZ1gcL6+QdIH+kCaiaahvFOs29l//pH krENpG/T3/VqBjFKIhdVscXAwuMZq7sUzEqmCDghUNYMMlTF9btzsDBAlMQUMTrEPBjd UfOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="BQEza/1A"; 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 d22si3402141pls.112.2019.07.18.21.37.46; Thu, 18 Jul 2019 21:38:01 -0700 (PDT) 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="BQEza/1A"; 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 S1727380AbfGSEAc (ORCPT + 99 others); Fri, 19 Jul 2019 00:00:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:60236 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728996AbfGSEAW (ORCPT ); Fri, 19 Jul 2019 00:00:22 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (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 276072189F; Fri, 19 Jul 2019 04:00:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1563508822; bh=8jc9kvZcD3+DghNPJWeOogXprIlcVQ98zV7vIwDv3T0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BQEza/1AeTQKJ/dKK0m89aUHwXGOIsyz8wpkWGFXLuINsGD6CXj0iZ6F1+OqRVU/L CiDdYPhCcBoMmUFHrc6Aj9hqG8iGQ4YZBbU6MmtYchYAr5RUZul/1NQG24fuyEbsMj lPLiCzgCZBIgHfxN75+79GnrVtGr00OfLXDRBbis= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: "Liu, Changcheng" , Changcheng Liu , Shiraz Saleem , Jason Gunthorpe , Sasha Levin , linux-rdma@vger.kernel.org Subject: [PATCH AUTOSEL 5.2 108/171] RDMA/i40iw: Set queue pair state when being queried Date: Thu, 18 Jul 2019 23:55:39 -0400 Message-Id: <20190719035643.14300-108-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190719035643.14300-1-sashal@kernel.org> References: <20190719035643.14300-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: "Liu, Changcheng" [ Upstream commit 2e67e775845373905d2c2aecb9062c2c4352a535 ] The API for ib_query_qp requires the driver to set qp_state and cur_qp_state on return, add the missing sets. Fixes: d37498417947 ("i40iw: add files for iwarp interface") Signed-off-by: Changcheng Liu Acked-by: Shiraz Saleem Reviewed-by: Jason Gunthorpe Signed-off-by: Jason Gunthorpe Signed-off-by: Sasha Levin --- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/infiniband/hw/i40iw/i40iw_verbs.c b/drivers/infiniband/hw/i40iw/i40iw_verbs.c index 5689d742bafb..4c88d6f72574 100644 --- a/drivers/infiniband/hw/i40iw/i40iw_verbs.c +++ b/drivers/infiniband/hw/i40iw/i40iw_verbs.c @@ -772,6 +772,8 @@ static int i40iw_query_qp(struct ib_qp *ibqp, struct i40iw_qp *iwqp = to_iwqp(ibqp); struct i40iw_sc_qp *qp = &iwqp->sc_qp; + attr->qp_state = iwqp->ibqp_state; + attr->cur_qp_state = attr->qp_state; attr->qp_access_flags = 0; attr->cap.max_send_wr = qp->qp_uk.sq_size; attr->cap.max_recv_wr = qp->qp_uk.rq_size; -- 2.20.1