[dpdk-dev,v3,20/40] drivers: enable compilation of DPAA Mempool driver

Message ID 20170823141213.25476-21-shreyansh.jain@nxp.com (mailing list archive)
State Superseded, archived
Headers

Checks

Context Check Description
ci/Intel-compilation success Compilation OK
ci/checkpatch success coding style OK

Commit Message

Shreyansh Jain Aug. 23, 2017, 2:11 p.m. UTC
  This patch also adds configuration necessary for compilation of DPAA
Mempool driver into the DPAA specific config file.
CONFIG_RTE_MBUF_DEFAULT_MEMPOOL_OPS=dpaa is also configured to allow
applications to use DPAA mempool as default.

Signed-off-by: Shreyansh Jain <shreyansh.jain@nxp.com>
---
 config/common_base                       | 1 +
 config/defconfig_arm64-dpaa-linuxapp-gcc | 5 +++++
 drivers/mempool/Makefile                 | 2 ++
 3 files changed, 8 insertions(+)
  

Comments

Thomas Monjalon Sept. 21, 2017, 9:55 p.m. UTC | #1
23/08/2017 16:11, Shreyansh Jain:
> +CONFIG_RTE_LIBRTE_DPAA_MEMPOOL_DEBUG=n

Please could you try to remove this kind of option?
We are going to remove them from DPDK.

For control path, no need of removing logs at compilation time.
For data path, compilation of logs is controlled by CONFIG_RTE_LOG_DP_LEVEL.
For enabling/disabling logs at runtime in the component,
there is the dynamic log types.
  
Shreyansh Jain Sept. 22, 2017, 6:35 a.m. UTC | #2
On Friday 22 September 2017 03:25 AM, Thomas Monjalon wrote:
> 23/08/2017 16:11, Shreyansh Jain:
>> +CONFIG_RTE_LIBRTE_DPAA_MEMPOOL_DEBUG=n
> 
> Please could you try to remove this kind of option?
> We are going to remove them from DPDK.

OK. I will revisit and remove which are not impacting the performance.

> 
> For control path, no need of removing logs at compilation time.
> For data path, compilation of logs is controlled by CONFIG_RTE_LOG_DP_LEVEL.
> For enabling/disabling logs at runtime in the component,
> there is the dynamic log types.
> 

I had already introduced dynamic log types for DPAA1. There weren't much 
examples for me to identify 'best practice'. I preferred this toggling 
so that I can be clear about when debugging is truly disabled.
  

Patch

diff --git a/config/common_base b/config/common_base
index 2bb2269..e4a9d6d 100644
--- a/config/common_base
+++ b/config/common_base
@@ -305,6 +305,7 @@  CONFIG_RTE_LIBRTE_LIO_DEBUG_REGS=n
 
 # NXP DPAA Bus
 CONFIG_RTE_LIBRTE_DPAA_BUS=n
+CONFIG_RTE_LIBRTE_DPAA_MEMPOOL=n
 
 #
 # Compile NXP DPAA2 FSL-MC Bus
diff --git a/config/defconfig_arm64-dpaa-linuxapp-gcc b/config/defconfig_arm64-dpaa-linuxapp-gcc
index 110042c..d91249f 100644
--- a/config/defconfig_arm64-dpaa-linuxapp-gcc
+++ b/config/defconfig_arm64-dpaa-linuxapp-gcc
@@ -43,3 +43,8 @@  CONFIG_RTE_LIBRTE_DPAA_BUS=y
 CONFIG_RTE_LIBRTE_DPAA_DEBUG_BUS=n
 CONFIG_RTE_LIBRTE_DPAA_DEBUG_INIT=n
 CONFIG_RTE_LIBRTE_DPAA_DEBUG_DRIVER=n
+
+# NXP DPAA Mempool
+CONFIG_RTE_LIBRTE_DPAA_MEMPOOL=y
+CONFIG_RTE_LIBRTE_DPAA_MEMPOOL_DEBUG=n
+CONFIG_RTE_MBUF_DEFAULT_MEMPOOL_OPS="dpaa"
diff --git a/drivers/mempool/Makefile b/drivers/mempool/Makefile
index efd55f2..bfc5f00 100644
--- a/drivers/mempool/Makefile
+++ b/drivers/mempool/Makefile
@@ -32,6 +32,8 @@  include $(RTE_SDK)/mk/rte.vars.mk
 
 core-libs := librte_eal librte_mempool librte_ring
 
+DIRS-$(CONFIG_RTE_LIBRTE_DPAA_MEMPOOL) += dpaa
+DEPDIRS-dpaa = $(core-libs)
 DIRS-$(CONFIG_RTE_LIBRTE_DPAA2_MEMPOOL) += dpaa2
 DEPDIRS-dpaa2 = $(core-libs)
 DIRS-$(CONFIG_RTE_DRIVER_MEMPOOL_RING) += ring