From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jerin Jacob Subject: Re: [PATCH 04/20] thunderx/nicvf: add get_reg and get_reg_length support Date: Fri, 13 May 2016 13:44:03 +0530 Message-ID: <20160513081402.GB4425@localhost.localdomain> References: <1462634198-2289-1-git-send-email-jerin.jacob@caviumnetworks.com> <1462634198-2289-5-git-send-email-jerin.jacob@caviumnetworks.com> <3AEA2BF9852C6F48A459DA490692831F01025933@IRSMSX109.ger.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Cc: "dev@dpdk.org" , "thomas.monjalon@6wind.com" , "Richardson, Bruce" , Maciej Czekaj , Kamil Rytarowski , Zyta Szpak , Slawomir Rosek , Radoslaw Biernacki To: "Pattan, Reshma" Return-path: Received: from na01-bn1-obe.outbound.protection.outlook.com (mail-bn1on0058.outbound.protection.outlook.com [157.56.110.58]) by dpdk.org (Postfix) with ESMTP id 384108D8B for ; Fri, 13 May 2016 10:14:40 +0200 (CEST) Content-Disposition: inline In-Reply-To: <3AEA2BF9852C6F48A459DA490692831F01025933@IRSMSX109.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 Thu, May 12, 2016 at 03:39:56PM +0000, Pattan, Reshma wrote: > > > > -----Original Message----- > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Jerin Jacob > > Sent: Saturday, May 7, 2016 4:16 PM > > To: dev@dpdk.org > > Cc: thomas.monjalon@6wind.com; Richardson, Bruce > > ; Jerin Jacob > > ; Maciej Czekaj > > ; Kamil Rytarowski > > ; Zyta Szpak > > ; Slawomir Rosek ; > > Radoslaw Biernacki > > Subject: [dpdk-dev] [PATCH 04/20] thunderx/nicvf: add get_reg and > > get_reg_length support > > > > + > > +static int > > +nicvf_dev_get_regs(struct rte_eth_dev *dev, struct rte_dev_reg_info > > +*regs) { > > + uint64_t *data = regs->data; > > + struct nicvf *nic = nicvf_pmd_priv(dev); > > + > > + if (data == NULL) > > + return -EINVAL; > > nicvf_reg_dump prints to stdout if data in NULL, so do we still want to return here? Yes as base is code common for other data plane libraries and I think in DPDK get_regs callback perspective it makes sense to add this check as PMD driver expected to get the data in the buffer. Thanks for the review. I agree with your all other review comments in another thread. Will fix it V2. > > Thanks, > Reshma > > >