From mboxrd@z Thu Jan 1 00:00:00 1970 From: Zyta Szpak Subject: Re: [PATCH v3 1/2] ethdev: add callback to get register size in bytes Date: Wed, 22 Jun 2016 10:19:08 +0200 Message-ID: <576A49FC.2090400@semihalf.com> References: <1464767771-19159-1-git-send-email-zr@semihalf.com> <575ED666.2010509@intel.com> <1667158.opORKPN5aG@xps13> <57690F01.6020600@semihalf.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: Remy Horton , dev@dpdk.org To: Thomas Monjalon Return-path: Received: from mail-lf0-f48.google.com (mail-lf0-f48.google.com [209.85.215.48]) by dpdk.org (Postfix) with ESMTP id AABD6C30A for ; Wed, 22 Jun 2016 10:19:08 +0200 (CEST) Received: by mail-lf0-f48.google.com with SMTP id f6so65251318lfg.0 for ; Wed, 22 Jun 2016 01:19:08 -0700 (PDT) In-Reply-To: <57690F01.6020600@semihalf.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" Note that if we remove rte_eth_dev_get_reg_length() then it will break all of the drivers that implement it. Shall I remove it all leave it and modify only ethtool to use rte_eth_dev_get_regs() to get reg size? In the end the drivers will have to implement the part of setting the size in reg_info struct. rte_eth_dev_get_regs() itself wouldn't change at all. Or do you have different opinion? On 21.06.2016 11:55, Zyta Szpak wrote: > OK, I will do the v4. > > On 17.06.2016 12:20, Thomas Monjalon wrote: >> 2016-06-13 16:51, Remy Horton: >>> On 12/06/2016 15:51, Zyta Szpak wrote: >>>> I would prefer having only one function rte_eth_dev_get_regs() >>>> which returns length and width if data is NULL. >>>> The first call is a parameter request before buffer allocation, >>>> and the second call fills the buffer. >>>> >>>> We can deprecate the old API and introduce this new one. >>>> >>>> Opinions? >>>> >>>> In my opinion as it is now it works fine. Gathering all parameters in >>>> one callback might be a good idea if the maintainer also agrees to >>>> that >>>> because as I mentioned, it interferes. >>> From my perspective changing rte_eth_dev_get_regs() isn't a >>> problem, as >>> it isn't used directly rather than through rte_ethtool_get_regs().. >> Zyta, would you like to make a v4? >