From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Hemminger Subject: Re: [PATCH v2 03/16] fm10k: Add a new func to initialize all parameters Date: Thu, 22 Oct 2015 08:57:54 -0700 Message-ID: <20151022085754.17478c99@xeon-e3> References: <1443531824-22767-2-git-send-email-jing.d.chen@intel.com> <1445507104-22563-1-git-send-email-jing.d.chen@intel.com> <1445507104-22563-4-git-send-email-jing.d.chen@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org To: "Chen Jing D(Mark)" Return-path: Received: from mail-pa0-f45.google.com (mail-pa0-f45.google.com [209.85.220.45]) by dpdk.org (Postfix) with ESMTP id 9A5A6C3A0 for ; Thu, 22 Oct 2015 17:57:45 +0200 (CEST) Received: by pabrc13 with SMTP id rc13so89957273pab.0 for ; Thu, 22 Oct 2015 08:57:45 -0700 (PDT) In-Reply-To: <1445507104-22563-4-git-send-email-jing.d.chen@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, 22 Oct 2015 17:44:51 +0800 "Chen Jing D(Mark)" wrote: > +static void > +fm10k_params_init(struct rte_eth_dev *dev) > +{ > + struct fm10k_hw *hw = FM10K_DEV_PRIVATE_TO_HW(dev->data->dev_private); > + struct fm10k_dev_info *info = FM10K_DEV_PRIVATE_TO_INFO(dev); > + /* Inialize bus info. Normally we would call fm10k_get_bus_info(), but > + * there is no way to get link status without reading BAR4. Until this > + * works, assume we have maximum bandwidth. > + * @todo - fix bus info Minor nit. I would prefer that DPDK follow current Linux kernel style which is to always have a blank line after declarations. This improves readability. I.e: static void fm10k_params_init(struct rte_eth_dev *dev) { struct fm10k_hw *hw = FM10K_DEV_PRIVATE_TO_HW(dev->data->dev_private); struct fm10k_dev_info *info = FM10K_DEV_PRIVATE_TO_INFO(dev); /* Inialize bus info. Normally we would call fm10k_get_bus_info(), but * there is no way to get link status without reading BAR4. Until this * works, assume we have maximum bandwidth. * @todo - fix bus info