From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 3E07AA0562; Tue, 4 May 2021 12:55:44 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CD5BF40147; Tue, 4 May 2021 12:55:43 +0200 (CEST) Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by mails.dpdk.org (Postfix) with ESMTP id 120FB40141 for ; Tue, 4 May 2021 12:55:41 +0200 (CEST) Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.nyi.internal (Postfix) with ESMTP id 4C11F5C0152; Tue, 4 May 2021 06:55:41 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Tue, 04 May 2021 06:55:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm1; bh= jN5spfM3o2wKGhnoXSHu4okw7SGf0TgDslSj1oqjfW8=; b=OFqMyyJqvjdq6zRI hT+3xxebWroYNMy39ofeRhVH89VLc15B/LQuvCSwETR9Yx+ifTuHX/xMQ9SW+R82 jMb6pWJJAKCEa8B/DVEyJY+yLI7Bx/U+L7WS9jG2NPDJQ+jzbKjUdTywCSQvPCNR U/7NL5igTmgVrbR8Kvcz4Ib42n73Vb1HVB85eidKHx6twzVHstCmAelmubfydzsD /fyyT5x7bbItO0W7eUG0eP90f6+C820J4yc9Vx74OizgtLrld1qmM805IIlxXxNK o4wSCVjUvWpfuWmJkZrL8A0i9fh5Y30xNv6Qxi6b0fH+xkyoHUBgMavbOD1S6AGD 5KUH4A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=jN5spfM3o2wKGhnoXSHu4okw7SGf0TgDslSj1oqjf W8=; b=hCXVeB4uOFaYX5rk/Qmhs9ag2zMc57FEfysUJDnjIOJi1kQedUaFfJq3W wEtcf4lZwXHLpHs1Mii5IOo+EnDt28D8HpdKk+c68u7VOzcab0g1eg995IXwv0gl 8hrlzCWmF1LvswcDls+apauso8enPTeLaTyFATpL7Yb6RNCoXHAvHWcNm2kCAM6u v954aiRMyBFFWXz2kpPWw9ImpIAub/nGgcsSXLcDmL0W6svyFXG2nqrhsDtk6vQg dU7cpuRrRXRYti+DscP38QXrQwczv86HphhdWt4iW4vqKwZgvpitLh69AZtyLmvS rK7u4DJkU3h8hh573Gb9nU512Jsew== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdefiedgfeeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkfgjfhgggfgtsehtufertddttddvnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepudeggfdvfeduffdtfeeglefghfeukefgfffhueejtdetuedtjeeu ieeivdffgeehnecukfhppeejjedrudefgedrvddtfedrudekgeenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghl ohhnrdhnvght X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 4 May 2021 06:55:40 -0400 (EDT) From: Thomas Monjalon To: Shiri Kuzin , Matan Azrad Cc: dev@dpdk.org, matan@nvidia.com, gakhil@marvell.com, suanmingm@nvidia.com Date: Tue, 04 May 2021 12:55:39 +0200 Message-ID: <1674943.THMBtb7gHN@thomas> In-Reply-To: <20210429154335.2820028-13-matan@nvidia.com> References: <20210408204849.9543-1-shirik@nvidia.com> <20210429154335.2820028-1-matan@nvidia.com> <20210429154335.2820028-13-matan@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v2 12/16] common/mlx5: share get ib device match function X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 29/04/2021 17:43, Matan Azrad: > From: Shiri Kuzin > > The get_ib_device_match function iterates over the list of ib devices > returned by the get_device_list glue function and returns the ib device > matching the provided address. > > Since this function is in use by several drivers, in this patch we > share the function in common part. > > Signed-off-by: Shiri Kuzin > Acked-by: Matan Azrad > --- > --- a/drivers/common/mlx5/linux/mlx5_common_os.c > +++ b/drivers/common/mlx5/linux/mlx5_common_os.c > +struct ibv_device * > +mlx5_os_get_ib_device_match(struct rte_pci_addr *addr) It would be better as mlx5_get_pci_ibv_device() in drivers/common/mlx5/mlx5_common_pci.c Just need to forward declare struct ibv_device in drivers/common/mlx5/mlx5_common.h This is what is done internally for sub-functions. > --- a/drivers/common/mlx5/mlx5_common.h > +++ b/drivers/common/mlx5/mlx5_common.h > @@ -18,6 +18,7 @@ > > #include "mlx5_prm.h" > #include "mlx5_devx_cmds.h" > +#include "mlx5_common_os.h" > > /* Reported driver name. */ > #define MLX5_PCI_DRIVER_NAME "mlx5_pci" > @@ -215,6 +216,7 @@ enum mlx5_class { > MLX5_CLASS_VDPA = RTE_BIT64(1), > MLX5_CLASS_REGEX = RTE_BIT64(2), > MLX5_CLASS_COMPRESS = RTE_BIT64(3), > + MLX5_CLASS_CRYPTO = RTE_BIT64(4), > }; This change has nothing to do in this patch I think. > --- a/drivers/common/mlx5/version.map > +++ b/drivers/common/mlx5/version.map > @@ -111,6 +111,7 @@ INTERNAL { > mlx5_os_reg_mr; > mlx5_os_umem_reg; > mlx5_os_umem_dereg; > + mlx5_os_get_ib_device_match; # WINDOWS_NO_EXPORT Please keep alphabetical order.