From patchwork Wed Jan 9 09:15:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shamir Rabinovitch X-Patchwork-Id: 10753709 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 42BD6746 for ; Wed, 9 Jan 2019 09:15:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 22B3E28C29 for ; Wed, 9 Jan 2019 09:15:34 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1707128C93; Wed, 9 Jan 2019 09:15:34 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY 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 B09CA28CCD for ; Wed, 9 Jan 2019 09:15:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730224AbfAIJPd (ORCPT ); Wed, 9 Jan 2019 04:15:33 -0500 Received: from aserp2130.oracle.com ([141.146.126.79]:56520 "EHLO aserp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729979AbfAIJPc (ORCPT ); Wed, 9 Jan 2019 04:15:32 -0500 Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id x099DYvI052368; Wed, 9 Jan 2019 09:15:29 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id; s=corp-2018-07-02; bh=TZVQpqQYS1uf0uKhhL4pnf5AZh+rPn82X9TNI7/iVdc=; b=ry33qTu0+q+pQlfbTmB95pGvPc5vX8iHAqkascFEqwsnpqsI5AZfnFh6u7hZaYv916Da /cM1hyes7SuZ7WCXwbY6YtBu/nFDmT3UNZmNYVC2PuWFrMpFGqisDMe/glFW53yC/9ro T6+N3eFXpxiSHJuXqJmCq562lDseLaDJork66QD0GEnioo1L+aX6nnz7yFXtERosV/wV Zn2kVlpqG0bjZ97YwP9a+rVFC+xH+hSswOZSXclPozw6s1UN336UAnNBVe00Qe0FxLUA ilYzqDNSLNqLAN4xxsRQ+ngLzDvUymcQBl1zSOIm6LVMEKYJrS+khHD81ucXKUXB6TWI HQ== Received: from userv0021.oracle.com (userv0021.oracle.com [156.151.31.71]) by aserp2130.oracle.com with ESMTP id 2ptj3e0brg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 09 Jan 2019 09:15:29 +0000 Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userv0021.oracle.com (8.14.4/8.14.4) with ESMTP id x099FSjs028006 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 9 Jan 2019 09:15:28 GMT Received: from abhmp0010.oracle.com (abhmp0010.oracle.com [141.146.116.16]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x099FRRu006355; Wed, 9 Jan 2019 09:15:28 GMT Received: from localhost.localdomain (/10.175.22.105) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 09 Jan 2019 01:15:27 -0800 From: Shamir Rabinovitch To: linux-rdma@vger.kernel.org Cc: dledford@redhat.com, jgg@ziepe.ca Subject: [PATCH for-next v1 0/2] ib_umem_get extract ib_ucontext from ib_udata Date: Wed, 9 Jan 2019 11:15:14 +0200 Message-Id: <20190109091516.3922-1-shamir.rabinovitch@oracle.com> X-Mailer: git-send-email 2.17.2 X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9130 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=722 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1901090079 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 As preparation for shared ib_pd model, a cleanup in rdma code is needed which currently rely on the ib_pd->uobject->ucontext . As suggested by Jason in the RFC patch, the ucontext will be taken from ib_udata. ib_ueme_get was one of those places that tied themself to the ib_pd uobject. Cahnge this to allow more easy transition to shared ib_pd model in the future. Shamir Rabinovitch (2): IB/{core,uverbs}: move ib_umem_xxx functions from ib_core to ib_uverbs IB/{core,hw}: ib_umem_get extract ib_ucontext from ib_udata drivers/infiniband/core/Makefile | 4 ++-- drivers/infiniband/core/umem.c | 9 +++++-- drivers/infiniband/core/uverbs_main.c | 24 +++++++++++++++++++ drivers/infiniband/hw/bnxt_re/ib_verbs.c | 10 ++++---- drivers/infiniband/hw/cxgb3/iwch_provider.c | 2 +- drivers/infiniband/hw/cxgb4/mem.c | 2 +- drivers/infiniband/hw/hns/hns_roce_cq.c | 6 ++--- drivers/infiniband/hw/hns/hns_roce_db.c | 5 ++-- drivers/infiniband/hw/hns/hns_roce_mr.c | 4 ++-- drivers/infiniband/hw/hns/hns_roce_qp.c | 2 +- drivers/infiniband/hw/hns/hns_roce_srq.c | 4 ++-- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 2 +- drivers/infiniband/hw/mlx4/cq.c | 12 +++++----- drivers/infiniband/hw/mlx4/doorbell.c | 5 ++-- drivers/infiniband/hw/mlx4/mlx4_ib.h | 3 ++- drivers/infiniband/hw/mlx4/mr.c | 11 +++++---- drivers/infiniband/hw/mlx4/qp.c | 5 ++-- drivers/infiniband/hw/mlx4/srq.c | 4 ++-- drivers/infiniband/hw/mlx5/cq.c | 7 +++--- drivers/infiniband/hw/mlx5/devx.c | 2 +- drivers/infiniband/hw/mlx5/doorbell.c | 5 ++-- drivers/infiniband/hw/mlx5/mlx5_ib.h | 4 +++- drivers/infiniband/hw/mlx5/mr.c | 22 ++++++++--------- drivers/infiniband/hw/mlx5/odp.c | 4 ++-- drivers/infiniband/hw/mlx5/qp.c | 24 +++++++++---------- drivers/infiniband/hw/mlx5/srq.c | 4 ++-- drivers/infiniband/hw/mthca/mthca_provider.c | 2 +- drivers/infiniband/hw/nes/nes_verbs.c | 2 +- drivers/infiniband/hw/ocrdma/ocrdma_verbs.c | 2 +- drivers/infiniband/hw/qedr/verbs.c | 24 +++++++++---------- drivers/infiniband/hw/vmw_pvrdma/pvrdma_cq.c | 2 +- drivers/infiniband/hw/vmw_pvrdma/pvrdma_mr.c | 2 +- drivers/infiniband/hw/vmw_pvrdma/pvrdma_qp.c | 4 ++-- drivers/infiniband/hw/vmw_pvrdma/pvrdma_srq.c | 2 +- drivers/infiniband/sw/rdmavt/mr.c | 2 +- drivers/infiniband/sw/rxe/rxe_mr.c | 2 +- include/rdma/ib_umem.h | 5 ++-- include/rdma/ib_verbs.h | 1 + 38 files changed, 137 insertions(+), 99 deletions(-)