From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 79C6AA04E7; Wed, 11 Nov 2020 01:07:35 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 5C94A2B93; Wed, 11 Nov 2020 01:07:34 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by dpdk.org (Postfix) with ESMTP id 36105DED for ; Wed, 11 Nov 2020 01:07:32 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1059) id 86DE220C27FD; Tue, 10 Nov 2020 16:07:31 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 86DE220C27FD DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1605053251; bh=ZL/x8K8FKXaPsMF0l6aHM34W48SjV1lEyvJXRaUm4Dc=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=D9WeHe2PngMXgv+oAa64geddw+7qTwTttOhkhq3CYZx45X5PALS8UwPwwUfN9f5iW lxqrUl2ZWN3OYk4DXEhcBcbNVFhcdGkOA7u+bP3GBF50lUFonS1k+FXEF0QeFL8teq OjMaM8bTLEFfu4PJcx5zLTE8UaEdBC7nEE6D2Avw= Date: Tue, 10 Nov 2020 16:07:31 -0800 From: Narcisa Ana Maria Vasile To: Ophir Munk Cc: dev@dpdk.org, Raslan Darawsheh , Matan Azrad , Tal Shnaiderman , Thomas Monjalon Message-ID: <20201111000731.GE9449@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> References: <20201027232335.31427-1-ophirmu@nvidia.com> <20201027232335.31427-43-ophirmu@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201027232335.31427-43-ophirmu@nvidia.com> User-Agent: Mutt/1.5.21 (2010-09-15) Subject: Re: [dpdk-dev] [PATCH v1 42/72] common/mlx5/windows: add DevX UAR getters X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" On Tue, Oct 27, 2020 at 11:23:05PM +0000, Ophir Munk wrote: > The following getters are added: mlx5_os_get_devx_uar_mmap_offset, > mlx5_os_get_devx_uar_base_addr, mlx5_os_get_devx_uar_reg_addr, > mlx5_os_get_devx_uar_page_id. This commit is the Windows equivalent of > the Linux implementation in (1). > > (1) > commit 8638e19a10aa ("net/mlx5: remove more DV dependencies") > > Signed-off-by: Ophir Munk > --- > drivers/common/mlx5/windows/mlx5_common_os.h | 74 ++++++++++++++++++++++++++++ > 1 file changed, 74 insertions(+) > > diff --git a/drivers/common/mlx5/windows/mlx5_common_os.h b/drivers/common/mlx5/windows/mlx5_common_os.h > + * Get mmap offset. Given a pointer to an DevX UAR object of type > + * 'struct mlx5dv_devx_uar *' - return its mmap offset. > + * > + * @param[in] uar > + * Pointer to UAR object. > + * > + * @return > + * The mmap offset if uar is valid, 0 otherwise. > + */ > +static inline off_t > +mlx5_os_get_devx_uar_mmap_offset(void *uar) > +{ > + if (!uar) > + return 0; > + return 0; Should we return uar->mmap_off here? > +} > + > +/** > + * Get base addr pointer. Given a pointer to an UAR object of type > + * 'struct mlx5dv_devx_uar *' - return its base address. > + *