From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <ferruh.yigit@intel.com>
Received: from mga09.intel.com (mga09.intel.com [134.134.136.24])
 by dpdk.org (Postfix) with ESMTP id 19411199B5
 for <dev@dpdk.org>; Thu, 14 Sep 2017 18:25:51 +0200 (CEST)
Received: from fmsmga006.fm.intel.com ([10.253.24.20])
 by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;
 14 Sep 2017 09:25:50 -0700
X-ExtLoop1: 1
X-IronPort-AV: E=Sophos;i="5.42,393,1500966000"; d="scan'208";a="151886471"
Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.57])
 ([10.237.220.57])
 by fmsmga006.fm.intel.com with ESMTP; 14 Sep 2017 09:25:49 -0700
To: Ravi Kumar <ravi1.kumar@amd.com>, dev@dpdk.org
References: <1505324838-25734-1-git-send-email-ravi1.kumar@amd.com>
 <1505324838-25734-2-git-send-email-ravi1.kumar@amd.com>
From: Ferruh Yigit <ferruh.yigit@intel.com>
Message-ID: <e5a52273-5b8c-1789-8611-82a16f29777a@intel.com>
Date: Thu, 14 Sep 2017 17:25:49 +0100
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101
 Thunderbird/52.3.0
MIME-Version: 1.0
In-Reply-To: <1505324838-25734-2-git-send-email-ravi1.kumar@amd.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
Subject: Re: [dpdk-dev] [PATCH 2/4] net/axgbe : Add PMD support for AMD XGBE
 Ethernet
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <http://dpdk.org/ml/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://dpdk.org/ml/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <http://dpdk.org/ml/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
X-List-Received-Date: Thu, 14 Sep 2017 16:25:52 -0000

On 9/13/2017 6:47 PM, Ravi Kumar wrote:
> Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
<...>

> +#
> +# Export include files
> +#
> +SYMLINK-y-include += axgbe_ethdev.h
> +SYMLINK-y-include += axgbe_rxtx.h
> +SYMLINK-y-include += axgbe_common.h
> +SYMLINK-y-include += axgbe_phy.h

Are these need to be public header? If not just delete above lines.

> +
> +# this lib depends upon:
> +DEPDIRS-$(CONFIG_RTE_LIBRTE_AXGBE_PMD) += lib/librte_eal
> +DEPDIRS-$(CONFIG_RTE_LIBRTE_AXGBE_PMD) += lib/librte_mbuf
> +DEPDIRS-$(CONFIG_RTE_LIBRTE_AXGBE_PMD) += lib/librte_mempool
> +DEPDIRS-$(CONFIG_RTE_LIBRTE_AXGBE_PMD) += lib/librte_ether
> +DEPDIRS-$(CONFIG_RTE_LIBRTE_AXGBE_PMD) += lib/librte_kvargs

No more required, above drivers/net/Makefile update already does the
work, this can be removed.

<...>

> +#define min_t(type, x, y) ({                    \
> +	type __min1 = (x);                      \
> +	type __min2 = (y);                      \
> +	__min1 < __min2 ? __min1 : __min2; })
> +
> +#define max_t(type, x, y) ({                    \
> +	type __max1 = (x);                      \
> +	type __max2 = (y);                      \
> +	__max1 > __max2 ? __max1 : __max2; })

You can use RTE_MIN, RTE_MAX

> +
> +#define AXGBE_REG_WRITE(val, reg) do { \
> +	(*((volatile uint32_t *) (reg))) = val; \
> +} while (0)
> +
> +static inline uint32_t ioread32(uint64_t addr)
> +{

You can use rte equvalent functions, rte_read32 or rte_read32_relaxed
please check rte_io.h

<...>

> +	pci_dev = RTE_DEV_TO_PCI(eth_dev->device);
> +	pdata->pci_dev = pci_dev;
> +	rte_eth_copy_pci_info(eth_dev, pci_dev);

This should be already done by rte_eth_dev_pci_generic_probe()

<...>