From patchwork Thu May 4 13:23:07 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sagi Grimberg X-Patchwork-Id: 9711941 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 A356560235 for ; Thu, 4 May 2017 13:23:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 99E6F2868D for ; Thu, 4 May 2017 13:23:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8EA4028699; Thu, 4 May 2017 13:23:32 +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=-5.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, URIBL_BLACK 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 6544A2868D for ; Thu, 4 May 2017 13:23:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751565AbdEDNXa (ORCPT ); Thu, 4 May 2017 09:23:30 -0400 Received: from bombadil.infradead.org ([65.50.211.133]:40819 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750848AbdEDNX3 (ORCPT ); Thu, 4 May 2017 09:23:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Message-Id:Date:Subject:Cc:To:From: Sender:Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=i3hXjHjcs9WReLwtLQ/52Cqrd9NzUpHRGCK01BSCEJ0=; b=AQmeujC9YepIrewVvjOHtl1Us GAuf5wQl/szMdeklq6seO76cqNFdxGob6F0JlmRGOi9xs9hpOxolFcbFPwdUkedzDnfmUL0SkFYMh O6i9LPtKxyIdjQrV6u0LZuGH9kPeM13qub+9mYPBkEZJcWlLXBGa5FGTtS6rwcSi0ST9jrqc2c2qX vwiyqmxIA7yVtgCLsk6RxeBK0FEGFnv8o+ARiTWvqBwd/kLxCSGSPDqBkrKdoe4Y/GHqeqzWuWSYl IW/va8wWvrShi4JSmD1A3emEf0M8frENTz/xZ+f+UOn0uJRRPISDSDv7aGDDA05XnThKghpkz0pqU AotDi8AvA==; Received: from bzq-82-81-101-184.red.bezeqint.net ([82.81.101.184] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtpsa (Exim 4.87 #1 (Red Hat Linux)) id 1d6Gj7-0003Kf-Iw; Thu, 04 May 2017 13:23:28 +0000 From: Sagi Grimberg To: linux-rdma@vger.kernel.org Cc: Leon Romanovsky , Moni Shoua Subject: [PATCH] rxe: expose num_possible_cpus() cnum_comp_vectors Date: Thu, 4 May 2017 16:23:07 +0300 Message-Id: <1493904187-13686-1-git-send-email-sagi@grimberg.me> X-Mailer: git-send-email 2.7.4 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 Their completely logical, so don't pose an artificial limitation. Signed-off-by: Sagi Grimberg Reviewed-by: Leon Romanovsky Acked-by: Moni Shoua --- drivers/infiniband/sw/rxe/rxe_param.h | 1 - drivers/infiniband/sw/rxe/rxe_verbs.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/infiniband/sw/rxe/rxe_param.h b/drivers/infiniband/sw/rxe/rxe_param.h index 13ed2cc6eaa2..1b596fbbe251 100644 --- a/drivers/infiniband/sw/rxe/rxe_param.h +++ b/drivers/infiniband/sw/rxe/rxe_param.h @@ -114,7 +114,6 @@ enum rxe_device_param { RXE_MAX_UCONTEXT = 512, RXE_NUM_PORT = 1, - RXE_NUM_COMP_VECTORS = 1, RXE_MIN_QP_INDEX = 16, RXE_MAX_QP_INDEX = 0x00020000, diff --git a/drivers/infiniband/sw/rxe/rxe_verbs.c b/drivers/infiniband/sw/rxe/rxe_verbs.c index 4c9080c94c06..3be4cbe365c6 100644 --- a/drivers/infiniband/sw/rxe/rxe_verbs.c +++ b/drivers/infiniband/sw/rxe/rxe_verbs.c @@ -1237,7 +1237,7 @@ int rxe_register_device(struct rxe_dev *rxe) dev->owner = THIS_MODULE; dev->node_type = RDMA_NODE_IB_CA; dev->phys_port_cnt = 1; - dev->num_comp_vectors = RXE_NUM_COMP_VECTORS; + dev->num_comp_vectors = num_possible_cpus(); dev->dev.parent = rxe_dma_device(rxe); dev->local_dma_lkey = 0; dev->node_guid = rxe_node_guid(rxe);