From patchwork Mon Jun 5 05:00:16 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leon Romanovsky X-Patchwork-Id: 9765491 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B2AD760364 for ; Mon, 5 Jun 2017 05:00:30 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A686527DCD for ; Mon, 5 Jun 2017 05:00:30 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9B5BB27E63; Mon, 5 Jun 2017 05:00:30 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1A36427DCD for ; Mon, 5 Jun 2017 05:00:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751262AbdFEFA3 (ORCPT ); Mon, 5 Jun 2017 01:00:29 -0400 Received: from mail.kernel.org ([198.145.29.99]:54014 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751258AbdFEFA2 (ORCPT ); Mon, 5 Jun 2017 01:00:28 -0400 Received: from localhost (unknown [213.57.247.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id A6B95239A4; Mon, 5 Jun 2017 05:00:27 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A6B95239A4 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=leon@kernel.org From: Leon Romanovsky To: Doug Ledford Cc: linux-rdma@vger.kernel.org, Yishai Hadas Subject: [PATCH rdma-next V1 1/6] IB/core: Enable QP creation which is associated to underlay QP Date: Mon, 5 Jun 2017 08:00:16 +0300 Message-Id: <20170605050021.12236-2-leon@kernel.org> X-Mailer: git-send-email 2.12.2 In-Reply-To: <20170605050021.12236-1-leon@kernel.org> References: <20170605050021.12236-1-leon@kernel.org> Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Yishai Hadas Enable QP creation which is associated to some underlay QP as of IPoIB QP. It comes to allow in downstream patches a user space applications to accelerate send and receive traffic which is typically handled by IPoIB ULP. A successful QP creation will end-up by having an overlay QP (e.g. the created one) which is associated to an already existing underlay one (e.g. IPoIB QP). The underlay QP is responsible for the transport, the packets on the wire will hold its QPN, its pkey will be used, etc. The overlay QP can steer incoming packets which were target to the underlay QP into its own RQ. It can post send WQEs on its own SQ, the hardware will use the transport properties of the underlay QP to format the packets on the wire. Note: The underlay QP should be in an RTR/RTS state in order to enable the overlay QP to work properly. Each QP should manage its properties and objects via modify, query and destroy. Specifically, overlay QP can't affect the underlay QP properties and vice versa. Signed-off-by: Yishai Hadas Reviewed-by: Maor Gottlieb Signed-off-by: Leon Romanovsky --- include/rdma/ib_verbs.h | 2 ++ 1 file changed, 2 insertions(+) -- 2.12.2 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h index ba8314ec5768..ba97b33f31c5 100644 --- a/include/rdma/ib_verbs.h +++ b/include/rdma/ib_verbs.h @@ -1059,6 +1059,7 @@ enum ib_qp_create_flags { IB_QP_CREATE_USE_GFP_NOIO = 1 << 7, IB_QP_CREATE_SCATTER_FCS = 1 << 8, IB_QP_CREATE_CVLAN_STRIPPING = 1 << 9, + IB_QP_CREATE_ASSOC_QPN = 1 << 10, /* reserve bits 26-31 for low level drivers' internal use */ IB_QP_CREATE_RESERVED_START = 1 << 26, IB_QP_CREATE_RESERVED_END = 1 << 31, @@ -1086,6 +1087,7 @@ struct ib_qp_init_attr { */ u8 port_num; struct ib_rwq_ind_table *rwq_ind_tbl; + u32 associated_qpn; }; struct ib_qp_open_attr {