From patchwork Mon Apr 13 12:37:13 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Wang X-Patchwork-Id: 6208481 Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id D90DC9F1AC for ; Mon, 13 Apr 2015 12:37:44 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id F26492034B for ; Mon, 13 Apr 2015 12:37:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 011D4202E9 for ; Mon, 13 Apr 2015 12:37:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932505AbbDMMhU (ORCPT ); Mon, 13 Apr 2015 08:37:20 -0400 Received: from mail-wg0-f41.google.com ([74.125.82.41]:35587 "EHLO mail-wg0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932135AbbDMMhR (ORCPT ); Mon, 13 Apr 2015 08:37:17 -0400 Received: by wgyo15 with SMTP id o15so79235874wgy.2 for ; Mon, 13 Apr 2015 05:37:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=b4XV6eyZkiaeWrdiKolvriUd6ASKKqAjz+X2DV66bSE=; b=m0FLuW13CuT4D51mDFddHC9JoqRdPlJlJSAmtqGW0rjklBT1IFDV+wIh3+26SAGvTy jzWHy0IfBRMkkT/zsHzYo8vHcrRTBfYSoZPlvO2CJSdtbUeAw24xOMug5TRVGMymJ01G JPL4DAYhk4G3KUGnmg6GeX1Iv+fuQUk8wJK23R1MclCYPCHOLiSoKkrjkq1E8fzoMWs1 2sSirIAE1w6/uF/HTadnr//LyN/pxlbWiVS6jc2uy9F1DRLPSmbMf4938pFeWJUvujba yE6ZsuKnTnZoBnZW9ct21IWDSZ+mSL2Ajgu0ijdgJbkyk0yBqj6IQuoe6zWsSWOzVwVM LwSA== X-Gm-Message-State: ALoCoQkQdJHVSLEBVzhyKeXZPczHpkAW890vXGpJlLP/9jPFRYXrsmgb5kQDbe8r/T4WoWK8pyg8 X-Received: by 10.194.110.69 with SMTP id hy5mr28241736wjb.121.1428928636389; Mon, 13 Apr 2015 05:37:16 -0700 (PDT) Received: from [192.168.71.52] ([62.217.45.26]) by mx.google.com with ESMTPSA id gt4sm11317514wib.21.2015.04.13.05.37.14 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 13 Apr 2015 05:37:15 -0700 (PDT) Message-ID: <552BB879.4000409@profitbricks.com> Date: Mon, 13 Apr 2015 14:37:13 +0200 From: Michael Wang User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: Roland Dreier , Sean Hefty , Hal Rosenstock , linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org CC: Tom Tucker , Steve Wise , Hoang-Nam Nguyen , Christoph Raisch , Mike Marciniszyn , Eli Cohen , Faisal Latif , Jack Morgenstein , Or Gerlitz , Haggai Eran , Ira Weiny , Tom Talpey , Jason Gunthorpe , Doug Ledford , Michael Wang Subject: [PATCH v3 28/28] IB/Verbs: Cleanup rdma_node_get_transport() References: <552BB470.4090407@profitbricks.com> In-Reply-To: <552BB470.4090407@profitbricks.com> Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY, URIBL_BLACK autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP We have get rid of all the scene using legacy rdma_node_get_transport(), now clean it up. Cc: Steve Wise Cc: Tom Talpey Cc: Jason Gunthorpe Cc: Doug Ledford Cc: Ira Weiny Cc: Sean Hefty Signed-off-by: Michael Wang --- drivers/infiniband/core/verbs.c | 21 --------------------- include/rdma/ib_verbs.h | 3 --- 2 files changed, 24 deletions(-) diff --git a/drivers/infiniband/core/verbs.c b/drivers/infiniband/core/verbs.c index 2e0c2cf1..d2a2b52 100644 --- a/drivers/infiniband/core/verbs.c +++ b/drivers/infiniband/core/verbs.c @@ -107,27 +107,6 @@ __attribute_const__ int ib_rate_to_mbps(enum ib_rate rate) } EXPORT_SYMBOL(ib_rate_to_mbps); -__attribute_const__ enum rdma_transport_type -rdma_node_get_transport(enum rdma_node_type node_type) -{ - switch (node_type) { - case RDMA_NODE_IB_CA: - case RDMA_NODE_IB_SWITCH: - case RDMA_NODE_IB_ROUTER: - return RDMA_TRANSPORT_IB; - case RDMA_NODE_RNIC: - return RDMA_TRANSPORT_IWARP; - case RDMA_NODE_USNIC: - return RDMA_TRANSPORT_USNIC; - case RDMA_NODE_USNIC_UDP: - return RDMA_TRANSPORT_USNIC_UDP; - default: - BUG(); - return 0; - } -} -EXPORT_SYMBOL(rdma_node_get_transport); - enum rdma_link_layer rdma_port_get_link_layer(struct ib_device *device, u8 port_num) { if (device->get_link_layer) diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h index 9f6b88e..3cc3f53 100644 --- a/include/rdma/ib_verbs.h +++ b/include/rdma/ib_verbs.h @@ -84,9 +84,6 @@ enum rdma_transport_type { RDMA_TRANSPORT_IBOE, }; -__attribute_const__ enum rdma_transport_type -rdma_node_get_transport(enum rdma_node_type node_type); - enum rdma_link_layer { IB_LINK_LAYER_UNSPECIFIED, IB_LINK_LAYER_INFINIBAND,