From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tetsuya Mukawa Subject: Re: [PATCH v3 2/8] eal: Add pci_uio_map_uio_resource_by_index() Date: Tue, 30 Jun 2015 11:34:00 +0900 Message-ID: <55920018.1040004@igel.co.jp> References: <1432016513-8456-5-git-send-email-mukawa@igel.co.jp> <1435546610-4533-1-git-send-email-mukawa@igel.co.jp> <1435546610-4533-3-git-send-email-mukawa@igel.co.jp> <8CEF83825BEC744B83065625E567D7C204A42D6C@IRSMSX108.ger.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit To: "Iremonger, Bernard" , "dev@dpdk.org" Return-path: Received: from mail-pa0-f44.google.com (mail-pa0-f44.google.com [209.85.220.44]) by dpdk.org (Postfix) with ESMTP id 178EEC30A for ; Tue, 30 Jun 2015 04:34:04 +0200 (CEST) Received: by pabvl15 with SMTP id vl15so114473307pab.1 for ; Mon, 29 Jun 2015 19:34:03 -0700 (PDT) In-Reply-To: <8CEF83825BEC744B83065625E567D7C204A42D6C@IRSMSX108.ger.corp.intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 2015/06/29 22:36, Iremonger, Bernard wrote: > >> -----Original Message----- >> From: Tetsuya Mukawa [mailto:mukawa@igel.co.jp] >> Sent: Monday, June 29, 2015 3:57 AM >> To: dev@dpdk.org >> Cc: Iremonger, Bernard; david.marchand@6wind.com; Tetsuya.Mukawa >> Subject: [PATCH v3 2/8] eal: Add pci_uio_map_uio_resource_by_index() >> >> From: "Tetsuya.Mukawa" >> >> This patch adds a new function called pci_uio_map_resource_by_index(). >> The function hides how to map uio resource in linuxapp and bsdapp. >> With the function, pci_uio_map_resource() will be more abstracted. >> >> Signed-off-by: Tetsuya Mukawa > Hi Tetsuya, > > There are two comments inline below. > >> --- >> lib/librte_eal/bsdapp/eal/eal_pci.c | 107 +++++++++++++++----------- >> lib/librte_eal/linuxapp/eal/eal_pci_uio.c | 124 +++++++++++++++++--------- >> ---- >> 2 files changed, 133 insertions(+), 98 deletions(-) >> >> diff --git a/lib/librte_eal/bsdapp/eal/eal_pci.c >> b/lib/librte_eal/bsdapp/eal/eal_pci.c >> index 2d9f3a5..61d1fe5 100644 >> --- a/lib/librte_eal/bsdapp/eal/eal_pci.c >> +++ b/lib/librte_eal/bsdapp/eal/eal_pci.c >> @@ -240,20 +240,73 @@ close_fd: >> return -1; >> } >> >> +static int >> +pci_uio_map_uio_resource_by_index(struct rte_pci_device *dev, int >> res_idx, >> + struct mapped_pci_resource *uio_res, int map_idx) { > The name of this function is a bit long winded, pci_uio_map_resource_by_index() might be better. > >> a/lib/librte_eal/linuxapp/eal/eal_pci_uio.c >> b/lib/librte_eal/linuxapp/eal/eal_pci_uio.c >> index 9e0b617..7da4543 100644 >> --- a/lib/librte_eal/linuxapp/eal/eal_pci_uio.c >> +++ b/lib/librte_eal/linuxapp/eal/eal_pci_uio.c >> @@ -333,19 +333,82 @@ close_fd: >> return -1; >> } >> >> +static int >> +pci_uio_map_uio_resource_by_index(struct rte_pci_device *dev, int >> res_idx, >> + struct mapped_pci_resource *uio_res, int map_idx) { > The name of this function is a bit long winded, pci_uio_map_resource_by_index() might be better. I will fix above 2 issues. Regards, Tetsuya