dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Create kern folder for Linux kernel modules
@ 2017-12-22  5:57 Hemant Agrawal
  2017-12-22  8:43 ` Thomas Monjalon
  2017-12-26  6:46 ` [PATCH v2] kernel folder for Linux and BSD modules Hemant Agrawal
  0 siblings, 2 replies; 24+ messages in thread
From: Hemant Agrawal @ 2017-12-22  5:57 UTC (permalink / raw)
  To: dev, thomas; +Cc: ferruh.yigit

This patch moves the Linux kernel modules code to a common place.
 - Separate the kernel module code from user space code.
 - The GPL-2.0 licensed code is separated from the BSD-3 licensed userspace
   code

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
 GNUmakefile                                                      | 2 +-
 kern/Makefile                                                    | 9 +++++++++
 {lib/librte_eal/linuxapp => kern}/igb_uio/Makefile               | 0
 {lib/librte_eal/linuxapp => kern}/igb_uio/compat.h               | 0
 {lib/librte_eal/linuxapp => kern}/igb_uio/igb_uio.c              | 0
 {lib/librte_eal/linuxapp => kern}/kni/Makefile                   | 0
 {lib/librte_eal/linuxapp => kern}/kni/compat.h                   | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/README             | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_82575.c  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_82575.h  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_api.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_api.h    | 0
 .../librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_defines.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_hw.h     | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_i210.c   | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_i210.h   | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mac.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mac.h    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_manage.c | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_manage.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mbx.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mbx.h    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_nvm.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_nvm.h    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_osdep.h  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_phy.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_phy.h    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_regs.h   | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb.h          | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_ethtool.c  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_main.c     | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_param.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_regtest.h  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_vmdq.c     | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_vmdq.h     | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/kcompat.h      | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe.h      | 0
 .../librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82598.c | 0
 .../librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82598.h | 0
 .../librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82599.c | 0
 .../librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82599.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_api.c  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_api.h  | 0
 .../linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_common.c           | 0
 .../linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_common.h           | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_dcb.h  | 0
 .../linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_ethtool.c          | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_fcoe.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_main.c | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_mbx.h  | 0
 .../librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_osdep.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_phy.c  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_phy.h  | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_type.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_x540.c | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_x540.h | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/kcompat.c    | 0
 {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/kcompat.h    | 0
 {lib/librte_eal/linuxapp => kern}/kni/kni_dev.h                  | 0
 {lib/librte_eal/linuxapp => kern}/kni/kni_ethtool.c              | 0
 {lib/librte_eal/linuxapp => kern}/kni/kni_fifo.h                 | 0
 {lib/librte_eal/linuxapp => kern}/kni/kni_misc.c                 | 0
 {lib/librte_eal/linuxapp => kern}/kni/kni_net.c                  | 0
 lib/librte_eal/linuxapp/Makefile                                 | 2 --
 64 files changed, 10 insertions(+), 3 deletions(-)
 create mode 100644 kern/Makefile
 rename {lib/librte_eal/linuxapp => kern}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kern}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kern}/kni/kni_net.c (100%)

diff --git a/GNUmakefile b/GNUmakefile
index 45b7fbb..59a30f4 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -40,7 +40,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib drivers app kern
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/kern/Makefile b/kern/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kern/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kern/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kern/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kern/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kern/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kern/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kern/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kern/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kern/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kern/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kern/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kern/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kern/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kern/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kern/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kern/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kern/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kern/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kern/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kern/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kern/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kern/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kern/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kern/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kern/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kern/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kern/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kern/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kern/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kern/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kern/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kern/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kern/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kern/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kern/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kern/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kern/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kern/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kern/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kern/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kern/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kern/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kern/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kern/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kern/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kern/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kern/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kern/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kern/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kern/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kern/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kern/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kern/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kern/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kern/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kern/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kern/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kern/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kern/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kern/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kern/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kern/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kern/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kern/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kern/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kern/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kern/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kern/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kern/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kern/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kern/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kern/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kern/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kern/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kern/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kern/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kern/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kern/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kern/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kern/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kern/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kern/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kern/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kern/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kern/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kern/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kern/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kern/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kern/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kern/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kern/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kern/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kern/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kern/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kern/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kern/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kern/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kern/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kern/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kern/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kern/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kern/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kern/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kern/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kern/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kern/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kern/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kern/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kern/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kern/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kern/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kern/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kern/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kern/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kern/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kern/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kern/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kern/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kern/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kern/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kern/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kern/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kern/kni/kni_net.c
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index 2ebdf31..5e100fb 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -32,8 +32,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 include $(RTE_SDK)/mk/rte.subdir.mk
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22  5:57 [PATCH] Create kern folder for Linux kernel modules Hemant Agrawal
@ 2017-12-22  8:43 ` Thomas Monjalon
  2017-12-22 10:04   ` Hemant Agrawal
  2017-12-26  6:46 ` [PATCH v2] kernel folder for Linux and BSD modules Hemant Agrawal
  1 sibling, 1 reply; 24+ messages in thread
From: Thomas Monjalon @ 2017-12-22  8:43 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: dev, ferruh.yigit

Hi,

22/12/2017 06:57, Hemant Agrawal:
> This patch moves the Linux kernel modules code to a common place.
>  - Separate the kernel module code from user space code.
>  - The GPL-2.0 licensed code is separated from the BSD-3 licensed userspace
>    code

What is the benefit of separate things by license?
These modules are Linux modules, so they should be in the linuxapp dir.
There are also some kernel modules in the bsdapp directory.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22  8:43 ` Thomas Monjalon
@ 2017-12-22 10:04   ` Hemant Agrawal
  2017-12-22 11:38     ` Thomas Monjalon
  2017-12-22 13:05     ` Burakov, Anatoly
  0 siblings, 2 replies; 24+ messages in thread
From: Hemant Agrawal @ 2017-12-22 10:04 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: dev, ferruh.yigit

On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
> Hi,
>
> 22/12/2017 06:57, Hemant Agrawal:
>> This patch moves the Linux kernel modules code to a common place.
>>  - Separate the kernel module code from user space code.
>>  - The GPL-2.0 licensed code is separated from the BSD-3 licensed userspace
>>    code
>
> What is the benefit of separate things by license?

The separation makes it easy to identify and check the license.

Any patch introducing new file in *non-kern* folders shall not be 
GPL-2.0 licensed.  Or GPL-2.0 license is allowed only for kern folder.

> These modules are Linux modules, so they should be in the linuxapp dir.


This is a cleaner separation w.r.t userspace/kernel space code.
*kern* is a better placefolder for LKMs.

Also eal is not getting overloaded.

linuxapp is part of librte_eal.  KNI is not related to EAL, but still 
the kni kernel code is added to librte_eal under linuxapp.


> There are also some kernel modules in the bsdapp directory.

We can move them as well.

>
>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 10:04   ` Hemant Agrawal
@ 2017-12-22 11:38     ` Thomas Monjalon
  2017-12-22 13:59       ` Wiles, Keith
  2017-12-22 14:28       ` Van Haaren, Harry
  2017-12-22 13:05     ` Burakov, Anatoly
  1 sibling, 2 replies; 24+ messages in thread
From: Thomas Monjalon @ 2017-12-22 11:38 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: dev, ferruh.yigit

22/12/2017 11:04, Hemant Agrawal:
> On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
> > Hi,
> >
> > 22/12/2017 06:57, Hemant Agrawal:
> >> This patch moves the Linux kernel modules code to a common place.
> >>  - Separate the kernel module code from user space code.
> >>  - The GPL-2.0 licensed code is separated from the BSD-3 licensed userspace
> >>    code
> >
> > What is the benefit of separate things by license?
> 
> The separation makes it easy to identify and check the license.
> 
> Any patch introducing new file in *non-kern* folders shall not be 
> GPL-2.0 licensed.  Or GPL-2.0 license is allowed only for kern folder.

The kernel modules are in DPDK only for historical reasons.
We should get rid of them, and rely only on upstream modules.

And it should be allowed to have kernel-related files elsewhere.
Examples: GPL tools or BPF code.

> > These modules are Linux modules, so they should be in the linuxapp dir.
> 
> 
> This is a cleaner separation w.r.t userspace/kernel space code.
> *kern* is a better placefolder for LKMs.

I prefer "kernel" name.

> Also eal is not getting overloaded.
> 
> linuxapp is part of librte_eal.  KNI is not related to EAL, but still 
> the kni kernel code is added to librte_eal under linuxapp.

Yes it makes sense.

More opinions/votes?

> > There are also some kernel modules in the bsdapp directory.
> 
> We can move them as well.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 10:04   ` Hemant Agrawal
  2017-12-22 11:38     ` Thomas Monjalon
@ 2017-12-22 13:05     ` Burakov, Anatoly
  1 sibling, 0 replies; 24+ messages in thread
From: Burakov, Anatoly @ 2017-12-22 13:05 UTC (permalink / raw)
  To: dev

On 22-Dec-17 10:04 AM, Hemant Agrawal wrote:
> On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
>> Hi,
>>
>> 22/12/2017 06:57, Hemant Agrawal:
>>> This patch moves the Linux kernel modules code to a common place.
>>>  - Separate the kernel module code from user space code.
>>>  - The GPL-2.0 licensed code is separated from the BSD-3 licensed 
>>> userspace
>>>    code
>>
>> What is the benefit of separate things by license?
> 
> The separation makes it easy to identify and check the license.
> 
> Any patch introducing new file in *non-kern* folders shall not be 
> GPL-2.0 licensed.  Or GPL-2.0 license is allowed only for kern folder.

The latter is better since BSD kernel modules are not GPL-licensed. So, 
anything in the kern/kernel dir is not *necessarily* GPL-licensed, but 
anything *outside* kern/kernel dir is *necessarily not* GPL-licensed.

-- 
Thanks,
Anatoly

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 11:38     ` Thomas Monjalon
@ 2017-12-22 13:59       ` Wiles, Keith
  2017-12-22 14:17         ` Thomas Monjalon
  2017-12-22 14:28       ` Van Haaren, Harry
  1 sibling, 1 reply; 24+ messages in thread
From: Wiles, Keith @ 2017-12-22 13:59 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Hemant Agrawal, dev, Yigit, Ferruh



> On Dec 22, 2017, at 5:38 AM, Thomas Monjalon <thomas@monjalon.net> wrote:
> 
> 22/12/2017 11:04, Hemant Agrawal:
>> On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
>>> Hi,
>>> 
>>> 22/12/2017 06:57, Hemant Agrawal:
>>>> This patch moves the Linux kernel modules code to a common place.
>>>> - Separate the kernel module code from user space code.
>>>> - The GPL-2.0 licensed code is separated from the BSD-3 licensed userspace
>>>>   code
>>> 
>>> What is the benefit of separate things by license?
>> 
>> The separation makes it easy to identify and check the license.
>> 
>> Any patch introducing new file in *non-kern* folders shall not be 
>> GPL-2.0 licensed.  Or GPL-2.0 license is allowed only for kern folder.
> 
> The kernel modules are in DPDK only for historical reasons.
> We should get rid of them, and rely only on upstream modules.
> 
> And it should be allowed to have kernel-related files elsewhere.
> Examples: GPL tools or BPF code.
> 
>>> These modules are Linux modules, so they should be in the linuxapp dir.
>> 
>> 
>> This is a cleaner separation w.r.t userspace/kernel space code.
>> *kern* is a better placefolder for LKMs.
> 
> I prefer "kernel" name.

The name should be related to Linux in some way, like linux_kern or linux_kernel or linux_modules (this is the one I prefer) this way it make it clear which OS they are designed for.

> 
>> Also eal is not getting overloaded.
>> 
>> linuxapp is part of librte_eal.  KNI is not related to EAL, but still 
>> the kni kernel code is added to librte_eal under linuxapp.
> 
> Yes it makes sense.
> 
> More opinions/votes?
> 
>>> There are also some kernel modules in the bsdapp directory.
>> 
>> We can move them as well.

Regards,
Keith

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 13:59       ` Wiles, Keith
@ 2017-12-22 14:17         ` Thomas Monjalon
  2017-12-22 14:51           ` Wiles, Keith
  0 siblings, 1 reply; 24+ messages in thread
From: Thomas Monjalon @ 2017-12-22 14:17 UTC (permalink / raw)
  To: Wiles, Keith; +Cc: Hemant Agrawal, dev, Yigit, Ferruh

22/12/2017 14:59, Wiles, Keith:
> 
> > On Dec 22, 2017, at 5:38 AM, Thomas Monjalon <thomas@monjalon.net> wrote:
> > 
> > 22/12/2017 11:04, Hemant Agrawal:
> >> On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
> >>> These modules are Linux modules, so they should be in the linuxapp dir.
> >> 
> >> 
> >> This is a cleaner separation w.r.t userspace/kernel space code.
> >> *kern* is a better placefolder for LKMs.
> > 
> > I prefer "kernel" name.
> 
> The name should be related to Linux in some way, like linux_kern or linux_kernel or linux_modules (this is the one I prefer) this way it make it clear which OS they are designed for.

If such top-level directory is created, the BSD modules must be moved there too.
That's why "kernel/" or "kernel/linux/" is appropriate.

> >> Also eal is not getting overloaded.
> >> 
> >> linuxapp is part of librte_eal.  KNI is not related to EAL, but still 
> >> the kni kernel code is added to librte_eal under linuxapp.
> > 
> > Yes it makes sense.
> > 
> > More opinions/votes?
> > 
> >>> There are also some kernel modules in the bsdapp directory.
> >> 
> >> We can move them as well.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 11:38     ` Thomas Monjalon
  2017-12-22 13:59       ` Wiles, Keith
@ 2017-12-22 14:28       ` Van Haaren, Harry
  1 sibling, 0 replies; 24+ messages in thread
From: Van Haaren, Harry @ 2017-12-22 14:28 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: dev, Yigit, Ferruh, Hemant Agrawal

> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Thomas Monjalon
> Sent: Friday, December 22, 2017 11:38 AM
> To: Hemant Agrawal <hemant.agrawal@nxp.com>
> Cc: dev@dpdk.org; Yigit, Ferruh <ferruh.yigit@intel.com>
> Subject: Re: [dpdk-dev] [PATCH] Create kern folder for Linux kernel modules
> 
> 22/12/2017 11:04, Hemant Agrawal:
> > On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
> > > Hi,
> > >
> > > 22/12/2017 06:57, Hemant Agrawal:
> > >> This patch moves the Linux kernel modules code to a common place.
> > >>  - Separate the kernel module code from user space code.
> > >>  - The GPL-2.0 licensed code is separated from the BSD-3 licensed
> userspace
> > >>    code
> > >
> > > What is the benefit of separate things by license?
> >
> > The separation makes it easy to identify and check the license.
> >
> > Any patch introducing new file in *non-kern* folders shall not be
> > GPL-2.0 licensed.  Or GPL-2.0 license is allowed only for kern folder.
> 
> The kernel modules are in DPDK only for historical reasons.
> We should get rid of them, and rely only on upstream modules.
> 
> And it should be allowed to have kernel-related files elsewhere.
> Examples: GPL tools or BPF code.
> 
> > > These modules are Linux modules, so they should be in the linuxapp dir.
> >
> >
> > This is a cleaner separation w.r.t userspace/kernel space code.
> > *kern* is a better placefolder for LKMs.
> 
> I prefer "kernel" name.
> 
> > Also eal is not getting overloaded.
> >
> > linuxapp is part of librte_eal.  KNI is not related to EAL, but still
> > the kni kernel code is added to librte_eal under linuxapp.
> 
> Yes it makes sense.
> 
> More opinions/votes?


No strong opinion on moving source code around here... but:

We should be careful that the build system leaves the .ko and other files in the same place as before as moving the build output may break automated deployments of other projects that use DPDK.

We've accidentally broken things before, for example moving scripts/ to usertools/ broke automation in OpenStack IIRC.


> > > There are also some kernel modules in the bsdapp directory.
> >
> > We can move them as well.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 14:17         ` Thomas Monjalon
@ 2017-12-22 14:51           ` Wiles, Keith
  2017-12-22 16:25             ` Hemant Agrawal
  0 siblings, 1 reply; 24+ messages in thread
From: Wiles, Keith @ 2017-12-22 14:51 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Hemant Agrawal, dev, Yigit, Ferruh



> On Dec 22, 2017, at 8:17 AM, Thomas Monjalon <thomas@monjalon.net> wrote:
> 
> 22/12/2017 14:59, Wiles, Keith:
>> 
>>> On Dec 22, 2017, at 5:38 AM, Thomas Monjalon <thomas@monjalon.net> wrote:
>>> 
>>> 22/12/2017 11:04, Hemant Agrawal:
>>>> On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
>>>>> These modules are Linux modules, so they should be in the linuxapp dir.
>>>> 
>>>> 
>>>> This is a cleaner separation w.r.t userspace/kernel space code.
>>>> *kern* is a better placefolder for LKMs.
>>> 
>>> I prefer "kernel" name.
>> 
>> The name should be related to Linux in some way, like linux_kern or linux_kernel or linux_modules (this is the one I prefer) this way it make it clear which OS they are designed for.
> 
> If such top-level directory is created, the BSD modules must be moved there too.
> That's why "kernel/" or "kernel/linux/" is appropriate.

OK seems reasonable, what about kernel/{freebsd,Linux, …}/modules/(module-name e.g. kni, igb_uio, nic_uio, …)

Kernel is misleading IMO, but I can live with it as long as we break down the different kernel related items. This is why I add modules in the path, as we could have other OSes like Windows with items that are not modules or VMs or containers…

I can live with kernel/{freebsd, linux, …}/{igb_uio, kni, nic_uio, ..}  but I would like to make sure it does not change in the future with adding windows.

> 
>>>> Also eal is not getting overloaded.
>>>> 
>>>> linuxapp is part of librte_eal.  KNI is not related to EAL, but still 
>>>> the kni kernel code is added to librte_eal under linuxapp.
>>> 
>>> Yes it makes sense.
>>> 
>>> More opinions/votes?
>>> 
>>>>> There are also some kernel modules in the bsdapp directory.
>>>> 
>>>> We can move them as well.
> 

Regards,
Keith


^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH] Create kern folder for Linux kernel modules
  2017-12-22 14:51           ` Wiles, Keith
@ 2017-12-22 16:25             ` Hemant Agrawal
  0 siblings, 0 replies; 24+ messages in thread
From: Hemant Agrawal @ 2017-12-22 16:25 UTC (permalink / raw)
  To: Wiles, Keith, Thomas Monjalon; +Cc: dev, Yigit, Ferruh

On 12/22/2017 8:21 PM, Wiles, Keith wrote:
>
>
>> On Dec 22, 2017, at 8:17 AM, Thomas Monjalon <thomas@monjalon.net> wrote:
>>
>> 22/12/2017 14:59, Wiles, Keith:
>>>
>>>> On Dec 22, 2017, at 5:38 AM, Thomas Monjalon <thomas@monjalon.net> wrote:
>>>>
>>>> 22/12/2017 11:04, Hemant Agrawal:
>>>>> On 12/22/2017 2:13 PM, Thomas Monjalon wrote:
>>>>>> These modules are Linux modules, so they should be in the linuxapp dir.
>>>>>
>>>>>
>>>>> This is a cleaner separation w.r.t userspace/kernel space code.
>>>>> *kern* is a better placefolder for LKMs.
>>>>
>>>> I prefer "kernel" name.
>>>
>>> The name should be related to Linux in some way, like linux_kern or linux_kernel or linux_modules (this is the one I prefer) this way it make it clear which OS they are designed for.
>>
>> If such top-level directory is created, the BSD modules must be moved there too.
>> That's why "kernel/" or "kernel/linux/" is appropriate.
>
> OK seems reasonable, what about kernel/{freebsd,Linux, …}/modules/(module-name e.g. kni, igb_uio, nic_uio, …)
>
> Kernel is misleading IMO, but I can live with it as long as we break down the different kernel related items. This is why I add modules in the path, as we could have other OSes like Windows with items that are not modules or VMs or containers…
>
> I can live with kernel/{freebsd, linux, …}/{igb_uio, kni, nic_uio, ..}  but I would like to make sure it does not change in the future with adding windows.

Your suggestion seems reasonable.

I am not sure about windows.
May be some working on DPDK-on-windows can comment

>
>>
>>>>> Also eal is not getting overloaded.
>>>>>
>>>>> linuxapp is part of librte_eal.  KNI is not related to EAL, but still
>>>>> the kni kernel code is added to librte_eal under linuxapp.
>>>>
>>>> Yes it makes sense.
>>>>
>>>> More opinions/votes?
>>>>
>>>>>> There are also some kernel modules in the bsdapp directory.
>>>>>
>>>>> We can move them as well.
>>
>
> Regards,
> Keith
>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* [PATCH v2] kernel folder for Linux and BSD modules
  2017-12-22  5:57 [PATCH] Create kern folder for Linux kernel modules Hemant Agrawal
  2017-12-22  8:43 ` Thomas Monjalon
@ 2017-12-26  6:46 ` Hemant Agrawal
  2017-12-26  8:10   ` Tiwei Bie
  2017-12-26  8:58   ` [PATCH v3] " Hemant Agrawal
  1 sibling, 2 replies; 24+ messages in thread
From: Hemant Agrawal @ 2017-12-26  6:46 UTC (permalink / raw)
  To: dev, thomas; +Cc: ferruh.yigit, keith.wiles

This patch moves the kernel modules code from EAL to a common place.
 - Separate the kernel module code from user space code.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
 GNUmakefile                                                      | 2 +-
 MAINTAINERS                                                      | 6 +++---
 kernel/Makefile                                                  | 9 +++++++++
 kernel/freebsd/Makefile                                          | 8 ++++++++
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile    | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile       | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c      | 0
 kernel/linux/Makefile                                            | 9 +++++++++
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h        | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h          | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c          | 0
 lib/librte_eal/bsdapp/Makefile                                   | 1 -
 lib/librte_eal/linuxapp/Makefile                                 | 2 --
 71 files changed, 30 insertions(+), 7 deletions(-)
 create mode 100644 kernel/Makefile
 create mode 100644 kernel/freebsd/Makefile
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c (100%)
 create mode 100644 kernel/linux/Makefile
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c (100%)

diff --git a/GNUmakefile b/GNUmakefile
index 45b7fbb..104d672 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -40,7 +40,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib drivers app kernel
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/MAINTAINERS b/MAINTAINERS
index 9a2c2fb..b7cb66f 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -194,7 +194,7 @@ F: doc/guides/linux_gsg/
 
 Linux UIO
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/igb_uio/
+F: kernel/linux/igb_uio/
 F: drivers/bus/pci/linux/*uio*
 
 Linux VFIO
@@ -214,7 +214,7 @@ F: lib/librte_eal/bsdapp/contigmem/
 
 FreeBSD UIO
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/nic_uio/
+F: kernel/freebsd/nic_uio/
 
 
 Core Libraries
@@ -324,7 +324,7 @@ F: doc/guides/nics/features/bonding.ini
 
 Linux KNI
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/kni/
+F: kernel/linux/kni/
 F: lib/librte_kni/
 F: doc/guides/prog_guide/kernel_nic_interface.rst
 F: test/test/test_kni.c
diff --git a/kernel/Makefile b/kernel/Makefile
new file mode 100644
index 0000000..8948d04
--- /dev/null
+++ b/kernel/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += linux
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += freebsd
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/kernel/freebsd/Makefile b/kernel/freebsd/Makefile
new file mode 100644
index 0000000..c293bb6
--- /dev/null
+++ b/kernel/freebsd/Makefile
@@ -0,0 +1,8 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/bsdapp/nic_uio/BSDmakefile b/kernel/freebsd/nic_uio/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/BSDmakefile
rename to kernel/freebsd/nic_uio/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/Makefile b/kernel/freebsd/nic_uio/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/Makefile
rename to kernel/freebsd/nic_uio/Makefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/nic_uio.c b/kernel/freebsd/nic_uio/nic_uio.c
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/nic_uio.c
rename to kernel/freebsd/nic_uio/nic_uio.c
diff --git a/kernel/linux/Makefile b/kernel/linux/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kernel/linux/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kernel/linux/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kernel/linux/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kernel/linux/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kernel/linux/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kernel/linux/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kernel/linux/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kernel/linux/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kernel/linux/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kernel/linux/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kernel/linux/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kernel/linux/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kernel/linux/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kernel/linux/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kernel/linux/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kernel/linux/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kernel/linux/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kernel/linux/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kernel/linux/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kernel/linux/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kernel/linux/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kernel/linux/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kernel/linux/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kernel/linux/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kernel/linux/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kernel/linux/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kernel/linux/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kernel/linux/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kernel/linux/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kernel/linux/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kernel/linux/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kernel/linux/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kernel/linux/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kernel/linux/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kernel/linux/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kernel/linux/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kernel/linux/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kernel/linux/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kernel/linux/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kernel/linux/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kernel/linux/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kernel/linux/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kernel/linux/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kernel/linux/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kernel/linux/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kernel/linux/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kernel/linux/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kernel/linux/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kernel/linux/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kernel/linux/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kernel/linux/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kernel/linux/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kernel/linux/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kernel/linux/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kernel/linux/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kernel/linux/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kernel/linux/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kernel/linux/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kernel/linux/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kernel/linux/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kernel/linux/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kernel/linux/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kernel/linux/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kernel/linux/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kernel/linux/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kernel/linux/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kernel/linux/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kernel/linux/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kernel/linux/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kernel/linux/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kernel/linux/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kernel/linux/kni/kni_net.c
diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
index 0e6e2be..474e9c1 100644
--- a/lib/librte_eal/bsdapp/Makefile
+++ b/lib/librte_eal/bsdapp/Makefile
@@ -33,6 +33,5 @@ include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
 
 include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index 2ebdf31..5e100fb 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -32,8 +32,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 include $(RTE_SDK)/mk/rte.subdir.mk
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: [PATCH v2] kernel folder for Linux and BSD modules
  2017-12-26  6:46 ` [PATCH v2] kernel folder for Linux and BSD modules Hemant Agrawal
@ 2017-12-26  8:10   ` Tiwei Bie
  2017-12-26  8:50     ` Hemant Agrawal
  2017-12-26  8:58   ` [PATCH v3] " Hemant Agrawal
  1 sibling, 1 reply; 24+ messages in thread
From: Tiwei Bie @ 2017-12-26  8:10 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: dev, thomas, ferruh.yigit, keith.wiles

On Tue, Dec 26, 2017 at 12:16:53PM +0530, Hemant Agrawal wrote:
> This patch moves the kernel modules code from EAL to a common place.
>  - Separate the kernel module code from user space code.
> 
> Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
> ---
[...]
> diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
> index 0e6e2be..474e9c1 100644
> --- a/lib/librte_eal/bsdapp/Makefile
> +++ b/lib/librte_eal/bsdapp/Makefile
> @@ -33,6 +33,5 @@ include $(RTE_SDK)/mk/rte.vars.mk
>  
>  DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
>  DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
> -DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
>  

Just FYI, contigmem is also a kernel module.

Best regards,
Tiwei Bie

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH v2] kernel folder for Linux and BSD modules
  2017-12-26  8:10   ` Tiwei Bie
@ 2017-12-26  8:50     ` Hemant Agrawal
  0 siblings, 0 replies; 24+ messages in thread
From: Hemant Agrawal @ 2017-12-26  8:50 UTC (permalink / raw)
  To: Tiwei Bie; +Cc: dev, thomas, ferruh.yigit, keith.wiles

On 12/26/2017 1:40 PM, Tiwei Bie wrote:
> On Tue, Dec 26, 2017 at 12:16:53PM +0530, Hemant Agrawal wrote:
>> This patch moves the kernel modules code from EAL to a common place.
>>  - Separate the kernel module code from user space code.
>>
>> Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
>> ---
> [...]
>> diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
>> index 0e6e2be..474e9c1 100644
>> --- a/lib/librte_eal/bsdapp/Makefile
>> +++ b/lib/librte_eal/bsdapp/Makefile
>> @@ -33,6 +33,5 @@ include $(RTE_SDK)/mk/rte.vars.mk
>>
>>  DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
>>  DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
>> -DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
>>
>
> Just FYI, contigmem is also a kernel module.

Thanks! I will send v3

^ permalink raw reply	[flat|nested] 24+ messages in thread

* [PATCH v3] kernel folder for Linux and BSD modules
  2017-12-26  6:46 ` [PATCH v2] kernel folder for Linux and BSD modules Hemant Agrawal
  2017-12-26  8:10   ` Tiwei Bie
@ 2017-12-26  8:58   ` Hemant Agrawal
  2018-01-10  6:46     ` [PATCH v4] " Hemant Agrawal
  1 sibling, 1 reply; 24+ messages in thread
From: Hemant Agrawal @ 2017-12-26  8:58 UTC (permalink / raw)
  To: dev, thomas; +Cc: ferruh.yigit, keith.wiles

This patch moves the kernel modules code from EAL to a common place.
 - Separate the kernel module code from user space code.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
v3: move contigmem from bsdapp
v2: rename kern to kernel, add freebsd modules as well

 GNUmakefile                                                      | 2 +-
 MAINTAINERS                                                      | 6 +++---
 kernel/Makefile                                                  | 9 +++++++++
 kernel/freebsd/Makefile                                          | 9 +++++++++
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile  | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile     | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c  | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile    | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile       | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c      | 0
 kernel/linux/Makefile                                            | 9 +++++++++
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h        | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h          | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c          | 0
 lib/librte_eal/bsdapp/Makefile                                   | 2 --
 lib/librte_eal/linuxapp/Makefile                                 | 2 --
 74 files changed, 31 insertions(+), 8 deletions(-)
 create mode 100644 kernel/Makefile
 create mode 100644 kernel/freebsd/Makefile
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c (100%)
 create mode 100644 kernel/linux/Makefile
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c (100%)

diff --git a/GNUmakefile b/GNUmakefile
index 45b7fbb..104d672 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -40,7 +40,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib drivers app kernel
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/MAINTAINERS b/MAINTAINERS
index 9a2c2fb..b7cb66f 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -194,7 +194,7 @@ F: doc/guides/linux_gsg/
 
 Linux UIO
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/igb_uio/
+F: kernel/linux/igb_uio/
 F: drivers/bus/pci/linux/*uio*
 
 Linux VFIO
@@ -214,7 +214,7 @@ F: lib/librte_eal/bsdapp/contigmem/
 
 FreeBSD UIO
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/nic_uio/
+F: kernel/freebsd/nic_uio/
 
 
 Core Libraries
@@ -324,7 +324,7 @@ F: doc/guides/nics/features/bonding.ini
 
 Linux KNI
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/kni/
+F: kernel/linux/kni/
 F: lib/librte_kni/
 F: doc/guides/prog_guide/kernel_nic_interface.rst
 F: test/test/test_kni.c
diff --git a/kernel/Makefile b/kernel/Makefile
new file mode 100644
index 0000000..8948d04
--- /dev/null
+++ b/kernel/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += linux
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += freebsd
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/kernel/freebsd/Makefile b/kernel/freebsd/Makefile
new file mode 100644
index 0000000..c93d7a6
--- /dev/null
+++ b/kernel/freebsd/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/bsdapp/contigmem/BSDmakefile b/kernel/freebsd/contigmem/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/BSDmakefile
rename to kernel/freebsd/contigmem/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/contigmem/Makefile b/kernel/freebsd/contigmem/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/Makefile
rename to kernel/freebsd/contigmem/Makefile
diff --git a/lib/librte_eal/bsdapp/contigmem/contigmem.c b/kernel/freebsd/contigmem/contigmem.c
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/contigmem.c
rename to kernel/freebsd/contigmem/contigmem.c
diff --git a/lib/librte_eal/bsdapp/nic_uio/BSDmakefile b/kernel/freebsd/nic_uio/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/BSDmakefile
rename to kernel/freebsd/nic_uio/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/Makefile b/kernel/freebsd/nic_uio/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/Makefile
rename to kernel/freebsd/nic_uio/Makefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/nic_uio.c b/kernel/freebsd/nic_uio/nic_uio.c
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/nic_uio.c
rename to kernel/freebsd/nic_uio/nic_uio.c
diff --git a/kernel/linux/Makefile b/kernel/linux/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kernel/linux/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kernel/linux/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kernel/linux/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kernel/linux/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kernel/linux/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kernel/linux/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kernel/linux/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kernel/linux/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kernel/linux/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kernel/linux/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kernel/linux/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kernel/linux/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kernel/linux/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kernel/linux/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kernel/linux/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kernel/linux/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kernel/linux/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kernel/linux/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kernel/linux/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kernel/linux/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kernel/linux/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kernel/linux/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kernel/linux/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kernel/linux/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kernel/linux/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kernel/linux/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kernel/linux/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kernel/linux/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kernel/linux/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kernel/linux/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kernel/linux/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kernel/linux/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kernel/linux/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kernel/linux/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kernel/linux/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kernel/linux/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kernel/linux/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kernel/linux/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kernel/linux/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kernel/linux/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kernel/linux/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kernel/linux/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kernel/linux/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kernel/linux/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kernel/linux/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kernel/linux/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kernel/linux/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kernel/linux/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kernel/linux/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kernel/linux/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kernel/linux/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kernel/linux/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kernel/linux/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kernel/linux/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kernel/linux/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kernel/linux/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kernel/linux/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kernel/linux/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kernel/linux/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kernel/linux/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kernel/linux/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kernel/linux/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kernel/linux/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kernel/linux/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kernel/linux/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kernel/linux/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kernel/linux/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kernel/linux/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kernel/linux/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kernel/linux/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kernel/linux/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kernel/linux/kni/kni_net.c
diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
index 0e6e2be..b01124b 100644
--- a/lib/librte_eal/bsdapp/Makefile
+++ b/lib/librte_eal/bsdapp/Makefile
@@ -32,7 +32,5 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
 
 include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index 2ebdf31..5e100fb 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -32,8 +32,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 include $(RTE_SDK)/mk/rte.subdir.mk
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH v4] kernel folder for Linux and BSD modules
  2017-12-26  8:58   ` [PATCH v3] " Hemant Agrawal
@ 2018-01-10  6:46     ` Hemant Agrawal
  2018-01-10 11:04       ` Richardson, Bruce
  2018-01-12 15:00       ` [PATCH v5] " Hemant Agrawal
  0 siblings, 2 replies; 24+ messages in thread
From: Hemant Agrawal @ 2018-01-10  6:46 UTC (permalink / raw)
  To: dev, thomas; +Cc: ferruh.yigit

This patch moves the kernel modules code from EAL to a common place.
 - Separate the kernel module code from user space code.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
v4: update the path in MAINTAINERS
v3: move contigmem from bsdapp
v2: rename kern to kernel, add freebsd modules as well

 GNUmakefile                                                      | 2 +-
 MAINTAINERS                                                      | 8 ++++----
 kernel/Makefile                                                  | 9 +++++++++
 kernel/freebsd/Makefile                                          | 9 +++++++++
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile  | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile     | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c  | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile    | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile       | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c      | 0
 kernel/linux/Makefile                                            | 9 +++++++++
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h        | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h          | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c          | 0
 lib/librte_eal/bsdapp/Makefile                                   | 2 --
 lib/librte_eal/linuxapp/Makefile                                 | 2 --
 74 files changed, 32 insertions(+), 9 deletions(-)
 create mode 100644 kernel/Makefile
 create mode 100644 kernel/freebsd/Makefile
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c (100%)
 create mode 100644 kernel/linux/Makefile
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c (100%)

diff --git a/GNUmakefile b/GNUmakefile
index d07fef0..671df05 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -12,7 +12,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib drivers app kernel
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/MAINTAINERS b/MAINTAINERS
index b51c2d0..1a44e07 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -195,7 +195,7 @@ F: doc/guides/linux_gsg/
 
 Linux UIO
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/igb_uio/
+F: kernel/linux/igb_uio/
 F: drivers/bus/pci/linux/*uio*
 
 Linux VFIO
@@ -211,11 +211,11 @@ F: doc/guides/freebsd_gsg/
 
 FreeBSD contigmem
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/contigmem/
+F: kernel/freebsd/contigmem/
 
 FreeBSD UIO
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/nic_uio/
+F: kernel/freebsd/nic_uio/
 
 
 Core Libraries
@@ -325,7 +325,7 @@ F: doc/guides/nics/features/bonding.ini
 
 Linux KNI
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/kni/
+F: kernel/linux/kni/
 F: lib/librte_kni/
 F: doc/guides/prog_guide/kernel_nic_interface.rst
 F: test/test/test_kni.c
diff --git a/kernel/Makefile b/kernel/Makefile
new file mode 100644
index 0000000..8948d04
--- /dev/null
+++ b/kernel/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += linux
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += freebsd
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/kernel/freebsd/Makefile b/kernel/freebsd/Makefile
new file mode 100644
index 0000000..c93d7a6
--- /dev/null
+++ b/kernel/freebsd/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/bsdapp/contigmem/BSDmakefile b/kernel/freebsd/contigmem/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/BSDmakefile
rename to kernel/freebsd/contigmem/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/contigmem/Makefile b/kernel/freebsd/contigmem/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/Makefile
rename to kernel/freebsd/contigmem/Makefile
diff --git a/lib/librte_eal/bsdapp/contigmem/contigmem.c b/kernel/freebsd/contigmem/contigmem.c
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/contigmem.c
rename to kernel/freebsd/contigmem/contigmem.c
diff --git a/lib/librte_eal/bsdapp/nic_uio/BSDmakefile b/kernel/freebsd/nic_uio/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/BSDmakefile
rename to kernel/freebsd/nic_uio/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/Makefile b/kernel/freebsd/nic_uio/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/Makefile
rename to kernel/freebsd/nic_uio/Makefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/nic_uio.c b/kernel/freebsd/nic_uio/nic_uio.c
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/nic_uio.c
rename to kernel/freebsd/nic_uio/nic_uio.c
diff --git a/kernel/linux/Makefile b/kernel/linux/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kernel/linux/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kernel/linux/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kernel/linux/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kernel/linux/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kernel/linux/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kernel/linux/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kernel/linux/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kernel/linux/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kernel/linux/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kernel/linux/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kernel/linux/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kernel/linux/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kernel/linux/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kernel/linux/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kernel/linux/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kernel/linux/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kernel/linux/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kernel/linux/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kernel/linux/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kernel/linux/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kernel/linux/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kernel/linux/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kernel/linux/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kernel/linux/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kernel/linux/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kernel/linux/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kernel/linux/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kernel/linux/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kernel/linux/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kernel/linux/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kernel/linux/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kernel/linux/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kernel/linux/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kernel/linux/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kernel/linux/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kernel/linux/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kernel/linux/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kernel/linux/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kernel/linux/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kernel/linux/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kernel/linux/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kernel/linux/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kernel/linux/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kernel/linux/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kernel/linux/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kernel/linux/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kernel/linux/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kernel/linux/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kernel/linux/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kernel/linux/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kernel/linux/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kernel/linux/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kernel/linux/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kernel/linux/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kernel/linux/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kernel/linux/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kernel/linux/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kernel/linux/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kernel/linux/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kernel/linux/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kernel/linux/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kernel/linux/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kernel/linux/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kernel/linux/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kernel/linux/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kernel/linux/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kernel/linux/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kernel/linux/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kernel/linux/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kernel/linux/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kernel/linux/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kernel/linux/kni/kni_net.c
diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
index 9d8e247..5b06b21 100644
--- a/lib/librte_eal/bsdapp/Makefile
+++ b/lib/librte_eal/bsdapp/Makefile
@@ -4,7 +4,5 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
 
 include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index 7e94e91..d3e30fd 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -4,8 +4,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 include $(RTE_SDK)/mk/rte.subdir.mk
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: [PATCH v4] kernel folder for Linux and BSD modules
  2018-01-10  6:46     ` [PATCH v4] " Hemant Agrawal
@ 2018-01-10 11:04       ` Richardson, Bruce
  2018-01-12 15:00       ` [PATCH v5] " Hemant Agrawal
  1 sibling, 0 replies; 24+ messages in thread
From: Richardson, Bruce @ 2018-01-10 11:04 UTC (permalink / raw)
  To: Hemant Agrawal, dev, thomas; +Cc: Yigit, Ferruh

> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Hemant Agrawal
> Sent: Wednesday, January 10, 2018 6:46 AM
> To: dev@dpdk.org; thomas@monjalon.net
> Cc: Yigit, Ferruh
> Subject: [dpdk-dev] [PATCH v4] kernel folder for Linux and BSD modules
> 
> This patch moves the kernel modules code from EAL to a common place.
>  - Separate the kernel module code from user space code.
> 
> Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
> ---
> v4: update the path in MAINTAINERS
> v3: move contigmem from bsdapp
> v2: rename kern to kernel, add freebsd modules as well
> 
Ran test builds on FreeBSD and modules still compile ok.

One minor comment is that I don't think "kernel" should go last on the list of subdirs, but should probably go between lib and drivers, with app being the last thing.

Tested-by: Bruce Richardson <bruce.richardson@intel.com>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* [PATCH v5] kernel folder for Linux and BSD modules
  2018-01-10  6:46     ` [PATCH v4] " Hemant Agrawal
  2018-01-10 11:04       ` Richardson, Bruce
@ 2018-01-12 15:00       ` Hemant Agrawal
  2018-02-21  8:09         ` [PATCH v6] " Hemant Agrawal
  1 sibling, 1 reply; 24+ messages in thread
From: Hemant Agrawal @ 2018-01-12 15:00 UTC (permalink / raw)
  To: dev, thomas; +Cc: bruce.richardson

This patch moves the kernel modules code from EAL to a common place.
 - Separate the kernel module code from user space code.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Tested-by: Bruce Richardson <bruce.richardson@intel.com>
---
v5: rearrange kernel compliation as per Bruce's suggestion
v4: update the path in MAINTAINERS
v3: move contigmem from bsdapp
v2: rename kern to kernel, add freebsd modules as well

 GNUmakefile                                                      | 2 +-
 MAINTAINERS                                                      | 8 ++++----
 kernel/Makefile                                                  | 9 +++++++++
 kernel/freebsd/Makefile                                          | 9 +++++++++
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile  | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile     | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c  | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile    | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile       | 0
 {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c      | 0
 kernel/linux/Makefile                                            | 9 +++++++++
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h           | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h       | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h       | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h         | 0
 .../linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h          | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h   | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c  | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h    | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h      | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h     | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c        | 0
 .../linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h        | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h          | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c      | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c         | 0
 {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c          | 0
 lib/librte_eal/bsdapp/Makefile                                   | 2 --
 lib/librte_eal/linuxapp/Makefile                                 | 2 --
 74 files changed, 32 insertions(+), 9 deletions(-)
 create mode 100644 kernel/Makefile
 create mode 100644 kernel/freebsd/Makefile
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c (100%)
 create mode 100644 kernel/linux/Makefile
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c (100%)

diff --git a/GNUmakefile b/GNUmakefile
index 45b7fbb..2a383d5 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -40,7 +40,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib kernel drivers app
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/MAINTAINERS b/MAINTAINERS
index 9a2c2fb..f870281 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -194,7 +194,7 @@ F: doc/guides/linux_gsg/
 
 Linux UIO
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/igb_uio/
+F: kernel/linux/igb_uio/
 F: drivers/bus/pci/linux/*uio*
 
 Linux VFIO
@@ -210,11 +210,11 @@ F: doc/guides/freebsd_gsg/
 
 FreeBSD contigmem
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/contigmem/
+F: kernel/freebsd/contigmem/
 
 FreeBSD UIO
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/nic_uio/
+F: kernel/freebsd/nic_uio/
 
 
 Core Libraries
@@ -324,7 +324,7 @@ F: doc/guides/nics/features/bonding.ini
 
 Linux KNI
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/kni/
+F: kernel/linux/kni/
 F: lib/librte_kni/
 F: doc/guides/prog_guide/kernel_nic_interface.rst
 F: test/test/test_kni.c
diff --git a/kernel/Makefile b/kernel/Makefile
new file mode 100644
index 0000000..8948d04
--- /dev/null
+++ b/kernel/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += linux
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += freebsd
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/kernel/freebsd/Makefile b/kernel/freebsd/Makefile
new file mode 100644
index 0000000..c93d7a6
--- /dev/null
+++ b/kernel/freebsd/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/bsdapp/contigmem/BSDmakefile b/kernel/freebsd/contigmem/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/BSDmakefile
rename to kernel/freebsd/contigmem/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/contigmem/Makefile b/kernel/freebsd/contigmem/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/Makefile
rename to kernel/freebsd/contigmem/Makefile
diff --git a/lib/librte_eal/bsdapp/contigmem/contigmem.c b/kernel/freebsd/contigmem/contigmem.c
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/contigmem.c
rename to kernel/freebsd/contigmem/contigmem.c
diff --git a/lib/librte_eal/bsdapp/nic_uio/BSDmakefile b/kernel/freebsd/nic_uio/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/BSDmakefile
rename to kernel/freebsd/nic_uio/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/Makefile b/kernel/freebsd/nic_uio/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/Makefile
rename to kernel/freebsd/nic_uio/Makefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/nic_uio.c b/kernel/freebsd/nic_uio/nic_uio.c
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/nic_uio.c
rename to kernel/freebsd/nic_uio/nic_uio.c
diff --git a/kernel/linux/Makefile b/kernel/linux/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kernel/linux/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kernel/linux/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kernel/linux/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kernel/linux/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kernel/linux/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kernel/linux/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kernel/linux/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kernel/linux/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kernel/linux/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kernel/linux/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kernel/linux/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kernel/linux/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kernel/linux/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kernel/linux/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kernel/linux/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kernel/linux/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kernel/linux/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kernel/linux/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kernel/linux/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kernel/linux/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kernel/linux/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kernel/linux/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kernel/linux/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kernel/linux/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kernel/linux/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kernel/linux/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kernel/linux/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kernel/linux/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kernel/linux/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kernel/linux/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kernel/linux/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kernel/linux/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kernel/linux/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kernel/linux/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kernel/linux/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kernel/linux/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kernel/linux/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kernel/linux/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kernel/linux/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kernel/linux/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kernel/linux/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kernel/linux/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kernel/linux/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kernel/linux/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kernel/linux/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kernel/linux/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kernel/linux/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kernel/linux/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kernel/linux/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kernel/linux/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kernel/linux/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kernel/linux/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kernel/linux/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kernel/linux/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kernel/linux/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kernel/linux/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kernel/linux/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kernel/linux/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kernel/linux/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kernel/linux/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kernel/linux/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kernel/linux/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kernel/linux/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kernel/linux/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kernel/linux/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kernel/linux/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kernel/linux/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kernel/linux/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kernel/linux/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kernel/linux/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kernel/linux/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kernel/linux/kni/kni_net.c
diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
index 0e6e2be..b01124b 100644
--- a/lib/librte_eal/bsdapp/Makefile
+++ b/lib/librte_eal/bsdapp/Makefile
@@ -32,7 +32,5 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
 
 include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index 2ebdf31..5e100fb 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -32,8 +32,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 include $(RTE_SDK)/mk/rte.subdir.mk
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH v6] kernel folder for Linux and BSD modules
  2018-01-12 15:00       ` [PATCH v5] " Hemant Agrawal
@ 2018-02-21  8:09         ` Hemant Agrawal
  2018-02-21 10:56           ` Bruce Richardson
  2018-02-22  6:09           ` [PATCH v7] " Hemant Agrawal
  0 siblings, 2 replies; 24+ messages in thread
From: Hemant Agrawal @ 2018-02-21  8:09 UTC (permalink / raw)
  To: dev, thomas; +Cc: bruce.richardson

This patch moves the kernel modules code from EAL to a common place.
 - Separate the kernel module code from user space code.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Tested-by: Bruce Richardson <bruce.richardson@intel.com>
---
v6: added meson build support
v5: rearrange kernel compliation as per Bruce's suggestion
v4: update the path in MAINTAINERS
v3: move contigmem from bsdapp
v2: rename kern to kernel, add freebsd modules as well

 GNUmakefile                                        |  2 +-
 MAINTAINERS                                        |  8 ++--
 kernel/Makefile                                    |  9 +++++
 kernel/freebsd/BSDmakefile.meson                   | 43 ++++++++++++++++++++
 kernel/freebsd/Makefile                            |  9 +++++
 .../freebsd}/contigmem/BSDmakefile                 |  0
 .../bsdapp => kernel/freebsd}/contigmem/Makefile   |  0
 .../freebsd}/contigmem/contigmem.c                 |  0
 .../freebsd}/contigmem/meson.build                 |  0
 .../bsdapp => kernel/freebsd}/nic_uio/BSDmakefile  |  0
 .../bsdapp => kernel/freebsd}/nic_uio/Makefile     |  0
 .../bsdapp => kernel/freebsd}/nic_uio/meson.build  |  0
 .../bsdapp => kernel/freebsd}/nic_uio/nic_uio.c    |  0
 kernel/linux/Makefile                              |  9 +++++
 .../linuxapp => kernel/linux}/igb_uio/Kbuild       |  0
 .../linuxapp => kernel/linux}/igb_uio/Makefile     |  0
 .../linuxapp => kernel/linux}/igb_uio/compat.h     |  0
 .../linuxapp => kernel/linux}/igb_uio/igb_uio.c    |  0
 .../linuxapp => kernel/linux}/igb_uio/meson.build  |  2 +-
 .../linuxapp => kernel/linux}/kni/Makefile         |  0
 .../linuxapp => kernel/linux}/kni/compat.h         |  0
 .../linuxapp => kernel/linux}/kni/ethtool/README   |  0
 .../linux}/kni/ethtool/igb/e1000_82575.c           |  0
 .../linux}/kni/ethtool/igb/e1000_82575.h           |  0
 .../linux}/kni/ethtool/igb/e1000_api.c             |  0
 .../linux}/kni/ethtool/igb/e1000_api.h             |  0
 .../linux}/kni/ethtool/igb/e1000_defines.h         |  0
 .../linux}/kni/ethtool/igb/e1000_hw.h              |  0
 .../linux}/kni/ethtool/igb/e1000_i210.c            |  0
 .../linux}/kni/ethtool/igb/e1000_i210.h            |  0
 .../linux}/kni/ethtool/igb/e1000_mac.c             |  0
 .../linux}/kni/ethtool/igb/e1000_mac.h             |  0
 .../linux}/kni/ethtool/igb/e1000_manage.c          |  0
 .../linux}/kni/ethtool/igb/e1000_manage.h          |  0
 .../linux}/kni/ethtool/igb/e1000_mbx.c             |  0
 .../linux}/kni/ethtool/igb/e1000_mbx.h             |  0
 .../linux}/kni/ethtool/igb/e1000_nvm.c             |  0
 .../linux}/kni/ethtool/igb/e1000_nvm.h             |  0
 .../linux}/kni/ethtool/igb/e1000_osdep.h           |  0
 .../linux}/kni/ethtool/igb/e1000_phy.c             |  0
 .../linux}/kni/ethtool/igb/e1000_phy.h             |  0
 .../linux}/kni/ethtool/igb/e1000_regs.h            |  0
 .../linux}/kni/ethtool/igb/igb.h                   |  0
 .../linux}/kni/ethtool/igb/igb_ethtool.c           |  0
 .../linux}/kni/ethtool/igb/igb_main.c              |  0
 .../linux}/kni/ethtool/igb/igb_param.c             |  0
 .../linux}/kni/ethtool/igb/igb_regtest.h           |  0
 .../linux}/kni/ethtool/igb/igb_vmdq.c              |  0
 .../linux}/kni/ethtool/igb/igb_vmdq.h              |  0
 .../linux}/kni/ethtool/igb/kcompat.h               |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe.h               |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82598.c         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82598.h         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82599.c         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82599.h         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_api.c           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_api.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_common.c        |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_common.h        |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_dcb.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c       |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_main.c          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_mbx.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_osdep.h         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_phy.c           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_phy.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_type.h          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_x540.c          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_x540.h          |  0
 .../linux}/kni/ethtool/ixgbe/kcompat.c             |  0
 .../linux}/kni/ethtool/ixgbe/kcompat.h             |  0
 .../linuxapp => kernel/linux}/kni/kni_dev.h        |  0
 .../linuxapp => kernel/linux}/kni/kni_ethtool.c    |  0
 .../linuxapp => kernel/linux}/kni/kni_fifo.h       |  0
 .../linuxapp => kernel/linux}/kni/kni_misc.c       |  0
 .../linuxapp => kernel/linux}/kni/kni_net.c        |  0
 kernel/meson.build                                 | 47 ++++++++++++++++++++++
 lib/librte_eal/bsdapp/Makefile                     |  2 -
 lib/librte_eal/linuxapp/Makefile                   |  2 -
 lib/librte_eal/meson.build                         | 22 ----------
 meson.build                                        |  1 +
 82 files changed, 124 insertions(+), 32 deletions(-)
 create mode 100644 kernel/Makefile
 create mode 100644 kernel/freebsd/BSDmakefile.meson
 create mode 100644 kernel/freebsd/Makefile
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/meson.build (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/meson.build (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c (100%)
 create mode 100644 kernel/linux/Makefile
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Kbuild (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/meson.build (93%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c (100%)
 create mode 100644 kernel/meson.build

diff --git a/GNUmakefile b/GNUmakefile
index d07fef0..ae80720 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -12,7 +12,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib kernel drivers app
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/MAINTAINERS b/MAINTAINERS
index a646ca3..2ecb75b 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -209,7 +209,7 @@ F: doc/guides/linux_gsg/
 
 Linux UIO
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/igb_uio/
+F: kernel/linux/igb_uio/
 F: drivers/bus/pci/linux/*uio*
 
 Linux VFIO
@@ -225,11 +225,11 @@ F: doc/guides/freebsd_gsg/
 
 FreeBSD contigmem
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/contigmem/
+F: kernel/freebsd/contigmem/
 
 FreeBSD UIO
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/nic_uio/
+F: kernel/freebsd/nic_uio/
 
 
 Core Libraries
@@ -359,7 +359,7 @@ F: doc/guides/nics/features/bonding.ini
 
 Linux KNI
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/kni/
+F: kernel/linux/kni/
 F: lib/librte_kni/
 F: doc/guides/prog_guide/kernel_nic_interface.rst
 F: test/test/test_kni.c
diff --git a/kernel/Makefile b/kernel/Makefile
new file mode 100644
index 0000000..8948d04
--- /dev/null
+++ b/kernel/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += linux
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += freebsd
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/kernel/freebsd/BSDmakefile.meson b/kernel/freebsd/BSDmakefile.meson
new file mode 100644
index 0000000..42f5b2b
--- /dev/null
+++ b/kernel/freebsd/BSDmakefile.meson
@@ -0,0 +1,43 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation. All rights reserved.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+
+# makefile for building kernel modules using meson
+# takes parameters from the environment
+
+# source file is passed via KMOD_SRC as full path, we only use final
+# component of it, as VPATH is used to find actual file, so as to
+# have the .o files placed in the build, not source directory
+VPATH = ${KMOD_SRC:H}
+SRCS = ${KMOD_SRC:T} device_if.h bus_if.h pci_if.h
+CFLAGS += $(KMOD_CFLAGS)
+
+.include <bsd.kmod.mk>
diff --git a/kernel/freebsd/Makefile b/kernel/freebsd/Makefile
new file mode 100644
index 0000000..c93d7a6
--- /dev/null
+++ b/kernel/freebsd/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/bsdapp/contigmem/BSDmakefile b/kernel/freebsd/contigmem/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/BSDmakefile
rename to kernel/freebsd/contigmem/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/contigmem/Makefile b/kernel/freebsd/contigmem/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/Makefile
rename to kernel/freebsd/contigmem/Makefile
diff --git a/lib/librte_eal/bsdapp/contigmem/contigmem.c b/kernel/freebsd/contigmem/contigmem.c
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/contigmem.c
rename to kernel/freebsd/contigmem/contigmem.c
diff --git a/lib/librte_eal/bsdapp/contigmem/meson.build b/kernel/freebsd/contigmem/meson.build
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/meson.build
rename to kernel/freebsd/contigmem/meson.build
diff --git a/lib/librte_eal/bsdapp/nic_uio/BSDmakefile b/kernel/freebsd/nic_uio/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/BSDmakefile
rename to kernel/freebsd/nic_uio/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/Makefile b/kernel/freebsd/nic_uio/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/Makefile
rename to kernel/freebsd/nic_uio/Makefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/meson.build b/kernel/freebsd/nic_uio/meson.build
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/meson.build
rename to kernel/freebsd/nic_uio/meson.build
diff --git a/lib/librte_eal/bsdapp/nic_uio/nic_uio.c b/kernel/freebsd/nic_uio/nic_uio.c
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/nic_uio.c
rename to kernel/freebsd/nic_uio/nic_uio.c
diff --git a/kernel/linux/Makefile b/kernel/linux/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kernel/linux/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Kbuild b/kernel/linux/igb_uio/Kbuild
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Kbuild
rename to kernel/linux/igb_uio/Kbuild
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kernel/linux/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kernel/linux/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kernel/linux/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kernel/linux/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kernel/linux/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kernel/linux/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/igb_uio/meson.build b/kernel/linux/igb_uio/meson.build
similarity index 93%
rename from lib/librte_eal/linuxapp/igb_uio/meson.build
rename to kernel/linux/igb_uio/meson.build
index 257ef63..356f4ab 100644
--- a/lib/librte_eal/linuxapp/igb_uio/meson.build
+++ b/kernel/linux/igb_uio/meson.build
@@ -18,7 +18,7 @@ custom_target('igb_uio',
 		'M=' + meson.current_build_dir(),
 		'src=' + meson.current_source_dir(),
 		'EXTRA_CFLAGS=-I' + meson.current_source_dir() +
-			'/../../common/include',
+			'/../../../lib/librte_eal/common/include',
 		'modules'],
 	depends: mkfile,
 	build_by_default: get_option('enable_kmods'))
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kernel/linux/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kernel/linux/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kernel/linux/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kernel/linux/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kernel/linux/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kernel/linux/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kernel/linux/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kernel/linux/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kernel/linux/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kernel/linux/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kernel/linux/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kernel/linux/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kernel/linux/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kernel/linux/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kernel/linux/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kernel/linux/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kernel/linux/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kernel/linux/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kernel/linux/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kernel/linux/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kernel/linux/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kernel/linux/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kernel/linux/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kernel/linux/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kernel/linux/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kernel/linux/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kernel/linux/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kernel/linux/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kernel/linux/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kernel/linux/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kernel/linux/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kernel/linux/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kernel/linux/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kernel/linux/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kernel/linux/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kernel/linux/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kernel/linux/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kernel/linux/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kernel/linux/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kernel/linux/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kernel/linux/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kernel/linux/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kernel/linux/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kernel/linux/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kernel/linux/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kernel/linux/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kernel/linux/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kernel/linux/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kernel/linux/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kernel/linux/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kernel/linux/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kernel/linux/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kernel/linux/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kernel/linux/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kernel/linux/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kernel/linux/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kernel/linux/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kernel/linux/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kernel/linux/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kernel/linux/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kernel/linux/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kernel/linux/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kernel/linux/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kernel/linux/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kernel/linux/kni/kni_net.c
diff --git a/kernel/meson.build b/kernel/meson.build
new file mode 100644
index 0000000..a5d5df7
--- /dev/null
+++ b/kernel/meson.build
@@ -0,0 +1,47 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2017 Intel Corporation
+
+# Initially pull in common settings
+#eal_inc = [global_inc]
+#subdir('common') # defines common_sources, common_objs, etc.
+
+# Now do OS/exec-env specific settings, including building kernel modules
+# The <exec-env>/eal/meson.build file should define env_sources, etc.
+if host_machine.system() == 'linux'
+	dpdk_conf.set('RTE_EXEC_ENV_LINUXAPP', 1)
+	subdir('linux/igb_uio')
+
+elif host_machine.system() == 'freebsd'
+	dpdk_conf.set('RTE_EXEC_ENV_BSDAPP', 1)
+	subdir('freebsd')
+	kmods = ['contigmem', 'nic_uio']
+
+	# for building kernel modules, we use kernel build system using make, as
+	# with Linux. We have a skeleton BSDmakefile, which pulls many of its
+	# values from the environment. Each module only has a single source file
+	# right now, which allows us to simplify things. We pull in the sourcer
+	# files from the individual meson.build files, and then use a custom
+	# target to call make, passing in the values as env parameters.
+	kmod_cflags = ['-I' + meson.build_root(),
+			'-I' + join_paths(meson.source_root(), 'config'),
+			'-include rte_config.h']
+	foreach k:kmods
+		subdir(join_paths('bsdapp', k))
+		custom_target(k,
+			input: [files('bsdapp/BSDmakefile.meson'), sources],
+			output: k + '.ko',
+			command: ['make', '-f', '@INPUT0@',
+				'KMOD_SRC=@INPUT1@',
+				'KMOD=' + k,
+				'KMOD_CFLAGS=' + ' '.join(kmod_cflags)],
+			build_by_default: get_option('enable_kmods'))
+	endforeach
+else
+	error('unsupported system type @0@'.format(hostmachine.system()))
+endif
+
+cflags += '-D_GNU_SOURCE'
+sources = common_sources + env_sources
+objs = common_objs + env_objs
+headers = common_headers + env_headers
+includes = eal_inc
diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
index 9d8e247..5b06b21 100644
--- a/lib/librte_eal/bsdapp/Makefile
+++ b/lib/librte_eal/bsdapp/Makefile
@@ -4,7 +4,5 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
 
 include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index aa52a01..a0fffa9 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -4,8 +4,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 CFLAGS += -DALLOW_EXPERIMENTAL_API
diff --git a/lib/librte_eal/meson.build b/lib/librte_eal/meson.build
index d9ba385..15d1c6a 100644
--- a/lib/librte_eal/meson.build
+++ b/lib/librte_eal/meson.build
@@ -12,33 +12,11 @@ subdir('common') # defines common_sources, common_objs, etc.
 if host_machine.system() == 'linux'
 	dpdk_conf.set('RTE_EXEC_ENV_LINUXAPP', 1)
 	subdir('linuxapp/eal')
-	subdir('linuxapp/igb_uio')
 
 elif host_machine.system() == 'freebsd'
 	dpdk_conf.set('RTE_EXEC_ENV_BSDAPP', 1)
 	subdir('bsdapp/eal')
-	kmods = ['contigmem', 'nic_uio']
 
-	# for building kernel modules, we use kernel build system using make, as
-	# with Linux. We have a skeleton BSDmakefile, which pulls many of its
-	# values from the environment. Each module only has a single source file
-	# right now, which allows us to simplify things. We pull in the sourcer
-	# files from the individual meson.build files, and then use a custom
-	# target to call make, passing in the values as env parameters.
-	kmod_cflags = ['-I' + meson.build_root(),
-			'-I' + join_paths(meson.source_root(), 'config'),
-			'-include rte_config.h']
-	foreach k:kmods
-		subdir(join_paths('bsdapp', k))
-		custom_target(k,
-			input: [files('bsdapp/BSDmakefile.meson'), sources],
-			output: k + '.ko',
-			command: ['make', '-f', '@INPUT0@',
-				'KMOD_SRC=@INPUT1@',
-				'KMOD=' + k,
-				'KMOD_CFLAGS=' + ' '.join(kmod_cflags)],
-			build_by_default: get_option('enable_kmods'))
-	endforeach
 else
 	error('unsupported system type @0@'.format(hostmachine.system()))
 endif
diff --git a/meson.build b/meson.build
index 0d99313..cc16595 100644
--- a/meson.build
+++ b/meson.build
@@ -26,6 +26,7 @@ subdir('config')
 
 # build libs and drivers
 subdir('lib')
+subdir('kernel')
 subdir('buildtools')
 subdir('drivers')
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: [PATCH v6] kernel folder for Linux and BSD modules
  2018-02-21  8:09         ` [PATCH v6] " Hemant Agrawal
@ 2018-02-21 10:56           ` Bruce Richardson
  2018-02-22  6:09           ` [PATCH v7] " Hemant Agrawal
  1 sibling, 0 replies; 24+ messages in thread
From: Bruce Richardson @ 2018-02-21 10:56 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: dev, thomas

On Wed, Feb 21, 2018 at 01:39:31PM +0530, Hemant Agrawal wrote:
> This patch moves the kernel modules code from EAL to a common place.
>  - Separate the kernel module code from user space code.
> 
> Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
> Tested-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> v6: added meson build support
> v5: rearrange kernel compliation as per Bruce's suggestion
> v4: update the path in MAINTAINERS
> v3: move contigmem from bsdapp
> v2: rename kern to kernel, add freebsd modules as well
> 
Hi Hemant,

from testing on FreeBSD, I believe these are the changes needed to allow
compilation with meson there. Nothing too drastic - mainly fix up the
folder names, and skip the subdir into the higher-level "freebsd" folder.

/Bruce

diff --git a/kernel/meson.build b/kernel/meson.build
index a5d5df7dd..697c419b6 100644
--- a/kernel/meson.build
+++ b/kernel/meson.build
@@ -13,7 +13,6 @@ if host_machine.system() == 'linux'

 elif host_machine.system() == 'freebsd'
        dpdk_conf.set('RTE_EXEC_ENV_BSDAPP', 1)
-       subdir('freebsd')
        kmods = ['contigmem', 'nic_uio']

        # for building kernel modules, we use kernel build system using make, as
@@ -26,9 +25,9 @@ elif host_machine.system() == 'freebsd'
                        '-I' + join_paths(meson.source_root(), 'config'),
                        '-include rte_config.h']
        foreach k:kmods
-               subdir(join_paths('bsdapp', k))
+               subdir(join_paths('freebsd', k))
                custom_target(k,
-                       input: [files('bsdapp/BSDmakefile.meson'), sources],
+                       input: [files('freebsd/BSDmakefile.meson'), sources],
                        output: k + '.ko',
                        command: ['make', '-f', '@INPUT0@',
                                'KMOD_SRC=@INPUT1@',

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH v7] kernel folder for Linux and BSD modules
  2018-02-21  8:09         ` [PATCH v6] " Hemant Agrawal
  2018-02-21 10:56           ` Bruce Richardson
@ 2018-02-22  6:09           ` Hemant Agrawal
  2018-03-21 18:42             ` Thomas Monjalon
  2018-03-22 16:27             ` Thomas Monjalon
  1 sibling, 2 replies; 24+ messages in thread
From: Hemant Agrawal @ 2018-02-22  6:09 UTC (permalink / raw)
  To: dev, bruce.richardson; +Cc: thomas

This patch moves the kernel modules code from EAL to a common place.
 - Separate the kernel module code from user space code.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Tested-by: Bruce Richardson <bruce.richardson@intel.com>
---
v7: fix freebsd build support
v6: added meson build support
v5: rearrange kernel compliation as per Bruce's suggestion
v4: update the path in MAINTAINERS
v3: move contigmem from bsdapp
v2: rename kern to kernel, add freebsd modules as well

 GNUmakefile                                        |  2 +-
 MAINTAINERS                                        |  8 ++--
 kernel/Makefile                                    |  9 +++++
 kernel/freebsd/BSDmakefile.meson                   | 43 ++++++++++++++++++++
 kernel/freebsd/Makefile                            |  9 +++++
 .../freebsd}/contigmem/BSDmakefile                 |  0
 .../bsdapp => kernel/freebsd}/contigmem/Makefile   |  0
 .../freebsd}/contigmem/contigmem.c                 |  0
 .../freebsd}/contigmem/meson.build                 |  0
 .../bsdapp => kernel/freebsd}/nic_uio/BSDmakefile  |  0
 .../bsdapp => kernel/freebsd}/nic_uio/Makefile     |  0
 .../bsdapp => kernel/freebsd}/nic_uio/meson.build  |  0
 .../bsdapp => kernel/freebsd}/nic_uio/nic_uio.c    |  0
 kernel/linux/Makefile                              |  9 +++++
 .../linuxapp => kernel/linux}/igb_uio/Kbuild       |  0
 .../linuxapp => kernel/linux}/igb_uio/Makefile     |  0
 .../linuxapp => kernel/linux}/igb_uio/compat.h     |  0
 .../linuxapp => kernel/linux}/igb_uio/igb_uio.c    |  0
 .../linuxapp => kernel/linux}/igb_uio/meson.build  |  2 +-
 .../linuxapp => kernel/linux}/kni/Makefile         |  0
 .../linuxapp => kernel/linux}/kni/compat.h         |  0
 .../linuxapp => kernel/linux}/kni/ethtool/README   |  0
 .../linux}/kni/ethtool/igb/e1000_82575.c           |  0
 .../linux}/kni/ethtool/igb/e1000_82575.h           |  0
 .../linux}/kni/ethtool/igb/e1000_api.c             |  0
 .../linux}/kni/ethtool/igb/e1000_api.h             |  0
 .../linux}/kni/ethtool/igb/e1000_defines.h         |  0
 .../linux}/kni/ethtool/igb/e1000_hw.h              |  0
 .../linux}/kni/ethtool/igb/e1000_i210.c            |  0
 .../linux}/kni/ethtool/igb/e1000_i210.h            |  0
 .../linux}/kni/ethtool/igb/e1000_mac.c             |  0
 .../linux}/kni/ethtool/igb/e1000_mac.h             |  0
 .../linux}/kni/ethtool/igb/e1000_manage.c          |  0
 .../linux}/kni/ethtool/igb/e1000_manage.h          |  0
 .../linux}/kni/ethtool/igb/e1000_mbx.c             |  0
 .../linux}/kni/ethtool/igb/e1000_mbx.h             |  0
 .../linux}/kni/ethtool/igb/e1000_nvm.c             |  0
 .../linux}/kni/ethtool/igb/e1000_nvm.h             |  0
 .../linux}/kni/ethtool/igb/e1000_osdep.h           |  0
 .../linux}/kni/ethtool/igb/e1000_phy.c             |  0
 .../linux}/kni/ethtool/igb/e1000_phy.h             |  0
 .../linux}/kni/ethtool/igb/e1000_regs.h            |  0
 .../linux}/kni/ethtool/igb/igb.h                   |  0
 .../linux}/kni/ethtool/igb/igb_ethtool.c           |  0
 .../linux}/kni/ethtool/igb/igb_main.c              |  0
 .../linux}/kni/ethtool/igb/igb_param.c             |  0
 .../linux}/kni/ethtool/igb/igb_regtest.h           |  0
 .../linux}/kni/ethtool/igb/igb_vmdq.c              |  0
 .../linux}/kni/ethtool/igb/igb_vmdq.h              |  0
 .../linux}/kni/ethtool/igb/kcompat.h               |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe.h               |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82598.c         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82598.h         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82599.c         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_82599.h         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_api.c           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_api.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_common.c        |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_common.h        |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_dcb.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c       |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_main.c          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_mbx.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_osdep.h         |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_phy.c           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_phy.h           |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_type.h          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_x540.c          |  0
 .../linux}/kni/ethtool/ixgbe/ixgbe_x540.h          |  0
 .../linux}/kni/ethtool/ixgbe/kcompat.c             |  0
 .../linux}/kni/ethtool/ixgbe/kcompat.h             |  0
 .../linuxapp => kernel/linux}/kni/kni_dev.h        |  0
 .../linuxapp => kernel/linux}/kni/kni_ethtool.c    |  0
 .../linuxapp => kernel/linux}/kni/kni_fifo.h       |  0
 .../linuxapp => kernel/linux}/kni/kni_misc.c       |  0
 .../linuxapp => kernel/linux}/kni/kni_net.c        |  0
 kernel/meson.build                                 | 46 ++++++++++++++++++++++
 lib/librte_eal/bsdapp/Makefile                     |  2 -
 lib/librte_eal/linuxapp/Makefile                   |  2 -
 lib/librte_eal/meson.build                         | 22 -----------
 meson.build                                        |  1 +
 82 files changed, 123 insertions(+), 32 deletions(-)
 create mode 100644 kernel/Makefile
 create mode 100644 kernel/freebsd/BSDmakefile.meson
 create mode 100644 kernel/freebsd/Makefile
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/contigmem.c (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/contigmem/meson.build (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/BSDmakefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/Makefile (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/meson.build (100%)
 rename {lib/librte_eal/bsdapp => kernel/freebsd}/nic_uio/nic_uio.c (100%)
 create mode 100644 kernel/linux/Makefile
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Kbuild (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/igb_uio.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/igb_uio/meson.build (93%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/Makefile (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/compat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/README (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_82575.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_defines.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_hw.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_i210.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mac.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_manage.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_nvm.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/e1000_regs.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_param.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_regtest.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/igb_vmdq.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/igb/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82598.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_82599.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_api.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_common.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_dcb.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_fcoe.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_main.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_mbx.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_osdep.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_phy.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_type.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/ixgbe_x540.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/ethtool/ixgbe/kcompat.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_dev.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_ethtool.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_fifo.h (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_misc.c (100%)
 rename {lib/librte_eal/linuxapp => kernel/linux}/kni/kni_net.c (100%)
 create mode 100644 kernel/meson.build

diff --git a/GNUmakefile b/GNUmakefile
index d07fef0..ae80720 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -12,7 +12,7 @@ export RTE_SDK
 # directory list
 #
 
-ROOTDIRS-y := buildtools lib drivers app
+ROOTDIRS-y := buildtools lib kernel drivers app
 ROOTDIRS-  := test
 
 include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/MAINTAINERS b/MAINTAINERS
index a646ca3..2ecb75b 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -209,7 +209,7 @@ F: doc/guides/linux_gsg/
 
 Linux UIO
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/igb_uio/
+F: kernel/linux/igb_uio/
 F: drivers/bus/pci/linux/*uio*
 
 Linux VFIO
@@ -225,11 +225,11 @@ F: doc/guides/freebsd_gsg/
 
 FreeBSD contigmem
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/contigmem/
+F: kernel/freebsd/contigmem/
 
 FreeBSD UIO
 M: Bruce Richardson <bruce.richardson@intel.com>
-F: lib/librte_eal/bsdapp/nic_uio/
+F: kernel/freebsd/nic_uio/
 
 
 Core Libraries
@@ -359,7 +359,7 @@ F: doc/guides/nics/features/bonding.ini
 
 Linux KNI
 M: Ferruh Yigit <ferruh.yigit@intel.com>
-F: lib/librte_eal/linuxapp/kni/
+F: kernel/linux/kni/
 F: lib/librte_kni/
 F: doc/guides/prog_guide/kernel_nic_interface.rst
 F: test/test/test_kni.c
diff --git a/kernel/Makefile b/kernel/Makefile
new file mode 100644
index 0000000..8948d04
--- /dev/null
+++ b/kernel/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += linux
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += freebsd
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/kernel/freebsd/BSDmakefile.meson b/kernel/freebsd/BSDmakefile.meson
new file mode 100644
index 0000000..42f5b2b
--- /dev/null
+++ b/kernel/freebsd/BSDmakefile.meson
@@ -0,0 +1,43 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation. All rights reserved.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+
+# makefile for building kernel modules using meson
+# takes parameters from the environment
+
+# source file is passed via KMOD_SRC as full path, we only use final
+# component of it, as VPATH is used to find actual file, so as to
+# have the .o files placed in the build, not source directory
+VPATH = ${KMOD_SRC:H}
+SRCS = ${KMOD_SRC:T} device_if.h bus_if.h pci_if.h
+CFLAGS += $(KMOD_CFLAGS)
+
+.include <bsd.kmod.mk>
diff --git a/kernel/freebsd/Makefile b/kernel/freebsd/Makefile
new file mode 100644
index 0000000..c93d7a6
--- /dev/null
+++ b/kernel/freebsd/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
+DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/bsdapp/contigmem/BSDmakefile b/kernel/freebsd/contigmem/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/BSDmakefile
rename to kernel/freebsd/contigmem/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/contigmem/Makefile b/kernel/freebsd/contigmem/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/Makefile
rename to kernel/freebsd/contigmem/Makefile
diff --git a/lib/librte_eal/bsdapp/contigmem/contigmem.c b/kernel/freebsd/contigmem/contigmem.c
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/contigmem.c
rename to kernel/freebsd/contigmem/contigmem.c
diff --git a/lib/librte_eal/bsdapp/contigmem/meson.build b/kernel/freebsd/contigmem/meson.build
similarity index 100%
rename from lib/librte_eal/bsdapp/contigmem/meson.build
rename to kernel/freebsd/contigmem/meson.build
diff --git a/lib/librte_eal/bsdapp/nic_uio/BSDmakefile b/kernel/freebsd/nic_uio/BSDmakefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/BSDmakefile
rename to kernel/freebsd/nic_uio/BSDmakefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/Makefile b/kernel/freebsd/nic_uio/Makefile
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/Makefile
rename to kernel/freebsd/nic_uio/Makefile
diff --git a/lib/librte_eal/bsdapp/nic_uio/meson.build b/kernel/freebsd/nic_uio/meson.build
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/meson.build
rename to kernel/freebsd/nic_uio/meson.build
diff --git a/lib/librte_eal/bsdapp/nic_uio/nic_uio.c b/kernel/freebsd/nic_uio/nic_uio.c
similarity index 100%
rename from lib/librte_eal/bsdapp/nic_uio/nic_uio.c
rename to kernel/freebsd/nic_uio/nic_uio.c
diff --git a/kernel/linux/Makefile b/kernel/linux/Makefile
new file mode 100644
index 0000000..c2c45a3
--- /dev/null
+++ b/kernel/linux/Makefile
@@ -0,0 +1,9 @@
+# SPDX-License-Identifier: GPL-2.0
+# Copyright 2017 NXP
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
+DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/igb_uio/Kbuild b/kernel/linux/igb_uio/Kbuild
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Kbuild
rename to kernel/linux/igb_uio/Kbuild
diff --git a/lib/librte_eal/linuxapp/igb_uio/Makefile b/kernel/linux/igb_uio/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/Makefile
rename to kernel/linux/igb_uio/Makefile
diff --git a/lib/librte_eal/linuxapp/igb_uio/compat.h b/kernel/linux/igb_uio/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/compat.h
rename to kernel/linux/igb_uio/compat.h
diff --git a/lib/librte_eal/linuxapp/igb_uio/igb_uio.c b/kernel/linux/igb_uio/igb_uio.c
similarity index 100%
rename from lib/librte_eal/linuxapp/igb_uio/igb_uio.c
rename to kernel/linux/igb_uio/igb_uio.c
diff --git a/lib/librte_eal/linuxapp/igb_uio/meson.build b/kernel/linux/igb_uio/meson.build
similarity index 93%
rename from lib/librte_eal/linuxapp/igb_uio/meson.build
rename to kernel/linux/igb_uio/meson.build
index 257ef63..356f4ab 100644
--- a/lib/librte_eal/linuxapp/igb_uio/meson.build
+++ b/kernel/linux/igb_uio/meson.build
@@ -18,7 +18,7 @@ custom_target('igb_uio',
 		'M=' + meson.current_build_dir(),
 		'src=' + meson.current_source_dir(),
 		'EXTRA_CFLAGS=-I' + meson.current_source_dir() +
-			'/../../common/include',
+			'/../../../lib/librte_eal/common/include',
 		'modules'],
 	depends: mkfile,
 	build_by_default: get_option('enable_kmods'))
diff --git a/lib/librte_eal/linuxapp/kni/Makefile b/kernel/linux/kni/Makefile
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/Makefile
rename to kernel/linux/kni/Makefile
diff --git a/lib/librte_eal/linuxapp/kni/compat.h b/kernel/linux/kni/compat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/compat.h
rename to kernel/linux/kni/compat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/README b/kernel/linux/kni/ethtool/README
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/README
rename to kernel/linux/kni/ethtool/README
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c b/kernel/linux/kni/ethtool/igb/e1000_82575.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.c
rename to kernel/linux/kni/ethtool/igb/e1000_82575.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h b/kernel/linux/kni/ethtool/igb/e1000_82575.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_82575.h
rename to kernel/linux/kni/ethtool/igb/e1000_82575.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c b/kernel/linux/kni/ethtool/igb/e1000_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.c
rename to kernel/linux/kni/ethtool/igb/e1000_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h b/kernel/linux/kni/ethtool/igb/e1000_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_api.h
rename to kernel/linux/kni/ethtool/igb/e1000_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h b/kernel/linux/kni/ethtool/igb/e1000_defines.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_defines.h
rename to kernel/linux/kni/ethtool/igb/e1000_defines.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h b/kernel/linux/kni/ethtool/igb/e1000_hw.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_hw.h
rename to kernel/linux/kni/ethtool/igb/e1000_hw.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c b/kernel/linux/kni/ethtool/igb/e1000_i210.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.c
rename to kernel/linux/kni/ethtool/igb/e1000_i210.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h b/kernel/linux/kni/ethtool/igb/e1000_i210.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_i210.h
rename to kernel/linux/kni/ethtool/igb/e1000_i210.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c b/kernel/linux/kni/ethtool/igb/e1000_mac.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.c
rename to kernel/linux/kni/ethtool/igb/e1000_mac.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h b/kernel/linux/kni/ethtool/igb/e1000_mac.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mac.h
rename to kernel/linux/kni/ethtool/igb/e1000_mac.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c b/kernel/linux/kni/ethtool/igb/e1000_manage.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.c
rename to kernel/linux/kni/ethtool/igb/e1000_manage.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h b/kernel/linux/kni/ethtool/igb/e1000_manage.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_manage.h
rename to kernel/linux/kni/ethtool/igb/e1000_manage.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c b/kernel/linux/kni/ethtool/igb/e1000_mbx.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.c
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h b/kernel/linux/kni/ethtool/igb/e1000_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_mbx.h
rename to kernel/linux/kni/ethtool/igb/e1000_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c b/kernel/linux/kni/ethtool/igb/e1000_nvm.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.c
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h b/kernel/linux/kni/ethtool/igb/e1000_nvm.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_nvm.h
rename to kernel/linux/kni/ethtool/igb/e1000_nvm.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h b/kernel/linux/kni/ethtool/igb/e1000_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_osdep.h
rename to kernel/linux/kni/ethtool/igb/e1000_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c
rename to kernel/linux/kni/ethtool/igb/e1000_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h b/kernel/linux/kni/ethtool/igb/e1000_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.h
rename to kernel/linux/kni/ethtool/igb/e1000_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h b/kernel/linux/kni/ethtool/igb/e1000_regs.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_regs.h
rename to kernel/linux/kni/ethtool/igb/e1000_regs.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h b/kernel/linux/kni/ethtool/igb/igb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb.h
rename to kernel/linux/kni/ethtool/igb/igb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/kernel/linux/kni/ethtool/igb/igb_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
rename to kernel/linux/kni/ethtool/igb/igb_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c
rename to kernel/linux/kni/ethtool/igb/igb_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c b/kernel/linux/kni/ethtool/igb/igb_param.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_param.c
rename to kernel/linux/kni/ethtool/igb/igb_param.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h b/kernel/linux/kni/ethtool/igb/igb_regtest.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_regtest.h
rename to kernel/linux/kni/ethtool/igb/igb_regtest.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c b/kernel/linux/kni/ethtool/igb/igb_vmdq.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.c
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h b/kernel/linux/kni/ethtool/igb/igb_vmdq.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/igb_vmdq.h
rename to kernel/linux/kni/ethtool/igb/igb_vmdq.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/kernel/linux/kni/ethtool/igb/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
rename to kernel/linux/kni/ethtool/igb/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82598.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82598.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_api.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_api.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_common.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_common.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_dcb.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_dcb.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_fcoe.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_fcoe.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_main.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_main.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_mbx.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_mbx.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_osdep.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_osdep.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_phy.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_phy.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_type.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_type.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.c
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h b/kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_x540.h
rename to kernel/linux/kni/ethtool/ixgbe/ixgbe_x540.h
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c b/kernel/linux/kni/ethtool/ixgbe/kcompat.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.c
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.c
diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h b/kernel/linux/kni/ethtool/ixgbe/kcompat.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/ethtool/ixgbe/kcompat.h
rename to kernel/linux/kni/ethtool/ixgbe/kcompat.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h b/kernel/linux/kni/kni_dev.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_dev.h
rename to kernel/linux/kni/kni_dev.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_ethtool.c b/kernel/linux/kni/kni_ethtool.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_ethtool.c
rename to kernel/linux/kni/kni_ethtool.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_fifo.h b/kernel/linux/kni/kni_fifo.h
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_fifo.h
rename to kernel/linux/kni/kni_fifo.h
diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_misc.c
rename to kernel/linux/kni/kni_misc.c
diff --git a/lib/librte_eal/linuxapp/kni/kni_net.c b/kernel/linux/kni/kni_net.c
similarity index 100%
rename from lib/librte_eal/linuxapp/kni/kni_net.c
rename to kernel/linux/kni/kni_net.c
diff --git a/kernel/meson.build b/kernel/meson.build
new file mode 100644
index 0000000..697c419
--- /dev/null
+++ b/kernel/meson.build
@@ -0,0 +1,46 @@
+# SPDX-License-Identifier: BSD-3-Clause
+# Copyright(c) 2017 Intel Corporation
+
+# Initially pull in common settings
+#eal_inc = [global_inc]
+#subdir('common') # defines common_sources, common_objs, etc.
+
+# Now do OS/exec-env specific settings, including building kernel modules
+# The <exec-env>/eal/meson.build file should define env_sources, etc.
+if host_machine.system() == 'linux'
+	dpdk_conf.set('RTE_EXEC_ENV_LINUXAPP', 1)
+	subdir('linux/igb_uio')
+
+elif host_machine.system() == 'freebsd'
+	dpdk_conf.set('RTE_EXEC_ENV_BSDAPP', 1)
+	kmods = ['contigmem', 'nic_uio']
+
+	# for building kernel modules, we use kernel build system using make, as
+	# with Linux. We have a skeleton BSDmakefile, which pulls many of its
+	# values from the environment. Each module only has a single source file
+	# right now, which allows us to simplify things. We pull in the sourcer
+	# files from the individual meson.build files, and then use a custom
+	# target to call make, passing in the values as env parameters.
+	kmod_cflags = ['-I' + meson.build_root(),
+			'-I' + join_paths(meson.source_root(), 'config'),
+			'-include rte_config.h']
+	foreach k:kmods
+		subdir(join_paths('freebsd', k))
+		custom_target(k,
+			input: [files('freebsd/BSDmakefile.meson'), sources],
+			output: k + '.ko',
+			command: ['make', '-f', '@INPUT0@',
+				'KMOD_SRC=@INPUT1@',
+				'KMOD=' + k,
+				'KMOD_CFLAGS=' + ' '.join(kmod_cflags)],
+			build_by_default: get_option('enable_kmods'))
+	endforeach
+else
+	error('unsupported system type @0@'.format(hostmachine.system()))
+endif
+
+cflags += '-D_GNU_SOURCE'
+sources = common_sources + env_sources
+objs = common_objs + env_objs
+headers = common_headers + env_headers
+includes = eal_inc
diff --git a/lib/librte_eal/bsdapp/Makefile b/lib/librte_eal/bsdapp/Makefile
index 9d8e247..5b06b21 100644
--- a/lib/librte_eal/bsdapp/Makefile
+++ b/lib/librte_eal/bsdapp/Makefile
@@ -4,7 +4,5 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += eal
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += contigmem
-DIRS-$(CONFIG_RTE_EXEC_ENV_BSDAPP) += nic_uio
 
 include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/lib/librte_eal/linuxapp/Makefile b/lib/librte_eal/linuxapp/Makefile
index aa52a01..a0fffa9 100644
--- a/lib/librte_eal/linuxapp/Makefile
+++ b/lib/librte_eal/linuxapp/Makefile
@@ -4,8 +4,6 @@
 include $(RTE_SDK)/mk/rte.vars.mk
 
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += eal
-DIRS-$(CONFIG_RTE_EAL_IGB_UIO) += igb_uio
-DIRS-$(CONFIG_RTE_KNI_KMOD) += kni
 DEPDIRS-kni := eal
 
 CFLAGS += -DALLOW_EXPERIMENTAL_API
diff --git a/lib/librte_eal/meson.build b/lib/librte_eal/meson.build
index d9ba385..15d1c6a 100644
--- a/lib/librte_eal/meson.build
+++ b/lib/librte_eal/meson.build
@@ -12,33 +12,11 @@ subdir('common') # defines common_sources, common_objs, etc.
 if host_machine.system() == 'linux'
 	dpdk_conf.set('RTE_EXEC_ENV_LINUXAPP', 1)
 	subdir('linuxapp/eal')
-	subdir('linuxapp/igb_uio')
 
 elif host_machine.system() == 'freebsd'
 	dpdk_conf.set('RTE_EXEC_ENV_BSDAPP', 1)
 	subdir('bsdapp/eal')
-	kmods = ['contigmem', 'nic_uio']
 
-	# for building kernel modules, we use kernel build system using make, as
-	# with Linux. We have a skeleton BSDmakefile, which pulls many of its
-	# values from the environment. Each module only has a single source file
-	# right now, which allows us to simplify things. We pull in the sourcer
-	# files from the individual meson.build files, and then use a custom
-	# target to call make, passing in the values as env parameters.
-	kmod_cflags = ['-I' + meson.build_root(),
-			'-I' + join_paths(meson.source_root(), 'config'),
-			'-include rte_config.h']
-	foreach k:kmods
-		subdir(join_paths('bsdapp', k))
-		custom_target(k,
-			input: [files('bsdapp/BSDmakefile.meson'), sources],
-			output: k + '.ko',
-			command: ['make', '-f', '@INPUT0@',
-				'KMOD_SRC=@INPUT1@',
-				'KMOD=' + k,
-				'KMOD_CFLAGS=' + ' '.join(kmod_cflags)],
-			build_by_default: get_option('enable_kmods'))
-	endforeach
 else
 	error('unsupported system type @0@'.format(hostmachine.system()))
 endif
diff --git a/meson.build b/meson.build
index 0d99313..cc16595 100644
--- a/meson.build
+++ b/meson.build
@@ -26,6 +26,7 @@ subdir('config')
 
 # build libs and drivers
 subdir('lib')
+subdir('kernel')
 subdir('buildtools')
 subdir('drivers')
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: [PATCH v7] kernel folder for Linux and BSD modules
  2018-02-22  6:09           ` [PATCH v7] " Hemant Agrawal
@ 2018-03-21 18:42             ` Thomas Monjalon
  2018-03-22 10:27               ` Bruce Richardson
  2018-03-22 16:27             ` Thomas Monjalon
  1 sibling, 1 reply; 24+ messages in thread
From: Thomas Monjalon @ 2018-03-21 18:42 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: dev, bruce.richardson

Hi,

About the title, please start with a verb:
	move kernel modules directories

22/02/2018 07:09, Hemant Agrawal:
> --- /dev/null
> +++ b/kernel/freebsd/BSDmakefile.meson
> @@ -0,0 +1,43 @@
> +#   BSD LICENSE
> +#
> +#   Copyright(c) 2017 Intel Corporation. All rights reserved.
> +#   All rights reserved.
> +#
> +#   Redistribution and use in source and binary forms, with or without
> +#   modification, are permitted provided that the following conditions
> +#   are met:

Why not SPDX here?
Is it copied from somewhere else?

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH v7] kernel folder for Linux and BSD modules
  2018-03-21 18:42             ` Thomas Monjalon
@ 2018-03-22 10:27               ` Bruce Richardson
  2018-03-22 10:48                 ` Thomas Monjalon
  0 siblings, 1 reply; 24+ messages in thread
From: Bruce Richardson @ 2018-03-22 10:27 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Hemant Agrawal, dev

On Wed, Mar 21, 2018 at 07:42:55PM +0100, Thomas Monjalon wrote:
> Hi,
> 
> About the title, please start with a verb:
> 	move kernel modules directories
> 
> 22/02/2018 07:09, Hemant Agrawal:
> > --- /dev/null
> > +++ b/kernel/freebsd/BSDmakefile.meson
> > @@ -0,0 +1,43 @@
> > +#   BSD LICENSE
> > +#
> > +#   Copyright(c) 2017 Intel Corporation. All rights reserved.
> > +#   All rights reserved.
> > +#
> > +#   Redistribution and use in source and binary forms, with or without
> > +#   modification, are permitted provided that the following conditions
> > +#   are met:
> 
> Why not SPDX here?
> Is it copied from somewhere else?
> 
Yes, it's copied, and the change to the license tag was missed previously.
It can be done as part of this patch, or else we can do a separate patch
for it if you prefer.

/Bruce

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH v7] kernel folder for Linux and BSD modules
  2018-03-22 10:27               ` Bruce Richardson
@ 2018-03-22 10:48                 ` Thomas Monjalon
  0 siblings, 0 replies; 24+ messages in thread
From: Thomas Monjalon @ 2018-03-22 10:48 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: Hemant Agrawal, dev

22/03/2018 11:27, Bruce Richardson:
> On Wed, Mar 21, 2018 at 07:42:55PM +0100, Thomas Monjalon wrote:
> > Hi,
> > 
> > About the title, please start with a verb:
> > 	move kernel modules directories
> > 
> > 22/02/2018 07:09, Hemant Agrawal:
> > > --- /dev/null
> > > +++ b/kernel/freebsd/BSDmakefile.meson
> > > @@ -0,0 +1,43 @@
> > > +#   BSD LICENSE
> > > +#
> > > +#   Copyright(c) 2017 Intel Corporation. All rights reserved.
> > > +#   All rights reserved.
> > > +#
> > > +#   Redistribution and use in source and binary forms, with or without
> > > +#   modification, are permitted provided that the following conditions
> > > +#   are met:
> > 
> > Why not SPDX here?
> > Is it copied from somewhere else?
> > 
> Yes, it's copied, and the change to the license tag was missed previously.
> It can be done as part of this patch, or else we can do a separate patch
> for it if you prefer.

OK, so let's fix it after this patch is applied.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH v7] kernel folder for Linux and BSD modules
  2018-02-22  6:09           ` [PATCH v7] " Hemant Agrawal
  2018-03-21 18:42             ` Thomas Monjalon
@ 2018-03-22 16:27             ` Thomas Monjalon
  1 sibling, 0 replies; 24+ messages in thread
From: Thomas Monjalon @ 2018-03-22 16:27 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: dev, bruce.richardson

22/02/2018 07:09, Hemant Agrawal:
> This patch moves the kernel modules code from EAL to a common place.
>  - Separate the kernel module code from user space code.
> 
> Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
> Tested-by: Bruce Richardson <bruce.richardson@intel.com>

Applied, thanks

^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2018-03-22 16:28 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-22  5:57 [PATCH] Create kern folder for Linux kernel modules Hemant Agrawal
2017-12-22  8:43 ` Thomas Monjalon
2017-12-22 10:04   ` Hemant Agrawal
2017-12-22 11:38     ` Thomas Monjalon
2017-12-22 13:59       ` Wiles, Keith
2017-12-22 14:17         ` Thomas Monjalon
2017-12-22 14:51           ` Wiles, Keith
2017-12-22 16:25             ` Hemant Agrawal
2017-12-22 14:28       ` Van Haaren, Harry
2017-12-22 13:05     ` Burakov, Anatoly
2017-12-26  6:46 ` [PATCH v2] kernel folder for Linux and BSD modules Hemant Agrawal
2017-12-26  8:10   ` Tiwei Bie
2017-12-26  8:50     ` Hemant Agrawal
2017-12-26  8:58   ` [PATCH v3] " Hemant Agrawal
2018-01-10  6:46     ` [PATCH v4] " Hemant Agrawal
2018-01-10 11:04       ` Richardson, Bruce
2018-01-12 15:00       ` [PATCH v5] " Hemant Agrawal
2018-02-21  8:09         ` [PATCH v6] " Hemant Agrawal
2018-02-21 10:56           ` Bruce Richardson
2018-02-22  6:09           ` [PATCH v7] " Hemant Agrawal
2018-03-21 18:42             ` Thomas Monjalon
2018-03-22 10:27               ` Bruce Richardson
2018-03-22 10:48                 ` Thomas Monjalon
2018-03-22 16:27             ` Thomas Monjalon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).