summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Richardson <bruce.richardson@intel.com>2015-05-15 16:56:46 +0100
committerThomas Monjalon <thomas.monjalon@6wind.com>2015-05-22 15:51:38 +0200
commit980ed498eb1dd0dc671e6796cbc9d3138250d0d9 (patch)
tree70aa714729336bb5e5e4839832107ee34bed2bd5
parent641a81b2744ec9ba77ae5bac70023911ffc40297 (diff)
downloaddpdk-980ed498eb1dd0dc671e6796cbc9d3138250d0d9.zip
dpdk-980ed498eb1dd0dc671e6796cbc9d3138250d0d9.tar.gz
dpdk-980ed498eb1dd0dc671e6796cbc9d3138250d0d9.tar.xz
drivers: create new directory
Add a new top-level "drivers" directory to which all PMDs will be moved for easier maintenance of both lib folder and drivers themselves. This new directory is a dependency of all the apps in the app folder, so the makefiles for each app are updated. To the new top-level directory add a "net" subdirectory to classify more specifically our existing PMDs as ethernet drivers Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Acked-by: John McNamara <john.mcnamara@intel.com> [Thomas: fix dependencies and merge several patches] Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
-rw-r--r--GNUmakefile4
-rw-r--r--app/test-pipeline/Makefile4
-rw-r--r--app/test-pmd/Makefile4
-rw-r--r--app/test/Makefile4
-rw-r--r--doc/guides/linux_gsg/build_dpdk.rst8
-rw-r--r--doc/guides/prog_guide/source_org.rst12
-rw-r--r--drivers/Makefile36
-rw-r--r--drivers/net/Makefile36
8 files changed, 97 insertions, 11 deletions
diff --git a/GNUmakefile b/GNUmakefile
index d04c20b..b59e4b6 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -1,6 +1,6 @@
# BSD LICENSE
#
-# Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
+# Copyright(c) 2010-2015 Intel Corporation. All rights reserved.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@@ -40,6 +40,6 @@ export RTE_SDK
# directory list
#
-ROOTDIRS-y := lib app
+ROOTDIRS-y := lib drivers app
include $(RTE_SDK)/mk/rte.sdkroot.mk
diff --git a/app/test-pipeline/Makefile b/app/test-pipeline/Makefile
index aa6df0c..4bab6dc 100644
--- a/app/test-pipeline/Makefile
+++ b/app/test-pipeline/Makefile
@@ -1,6 +1,6 @@
# BSD LICENSE
#
-# Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
+# Copyright(c) 2010-2015 Intel Corporation. All rights reserved.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@@ -57,7 +57,7 @@ SRCS-y += pipeline_lpm_ipv6.c
SRCS-$(CONFIG_RTE_LIBRTE_ACL) += pipeline_acl.c
# this application needs libraries first
-DEPDIRS-y += lib
+DEPDIRS-y += lib drivers
include $(RTE_SDK)/mk/rte.app.mk
diff --git a/app/test-pmd/Makefile b/app/test-pmd/Makefile
index dcf26f4..72426f3 100644
--- a/app/test-pmd/Makefile
+++ b/app/test-pmd/Makefile
@@ -1,6 +1,6 @@
# BSD LICENSE
#
-# Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
+# Copyright(c) 2010-2015 Intel Corporation. All rights reserved.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@@ -66,7 +66,7 @@ endif
CFLAGS_cmdline.o := -D_GNU_SOURCE
# this application needs libraries first
-DEPDIRS-y += lib
+DEPDIRS-y += lib drivers
include $(RTE_SDK)/mk/rte.app.mk
diff --git a/app/test/Makefile b/app/test/Makefile
index 4aca77c..3c777bf 100644
--- a/app/test/Makefile
+++ b/app/test/Makefile
@@ -1,6 +1,6 @@
# BSD LICENSE
#
-# Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
+# Copyright(c) 2010-2015 Intel Corporation. All rights reserved.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@@ -159,7 +159,7 @@ endif
endif
# this application needs libraries first
-DEPDIRS-y += lib
+DEPDIRS-y += lib drivers
# Link against shared libraries when needed
ifeq ($(CONFIG_RTE_LIBRTE_PMD_BOND),y)
diff --git a/doc/guides/linux_gsg/build_dpdk.rst b/doc/guides/linux_gsg/build_dpdk.rst
index e3a0b46..2680e66 100644
--- a/doc/guides/linux_gsg/build_dpdk.rst
+++ b/doc/guides/linux_gsg/build_dpdk.rst
@@ -45,12 +45,14 @@ First, uncompress the archive and move to the uncompressed DPDK source directory
user@host:~$ unzip DPDK-<version>.zip
user@host:~$ cd DPDK-<version>
user@host:~/DPDK-<version>$ ls
- app/ config/ examples/ lib/ LICENSE.GPL LICENSE.LGPL Makefile mk/ scripts/ tools/
+ app/ config/ drivers/ examples/ lib/ LICENSE.GPL LICENSE.LGPL Makefile mk/ scripts/ tools/
The DPDK is composed of several directories:
* lib: Source code of DPDK libraries
+* drivers: Source code of DPDK poll-mode drivers
+
* app: Source code of DPDK applications (automatic tests)
* examples: Source code of DPDK application examples
@@ -153,9 +155,9 @@ In addition, the make clean command can be used to remove any existing compiled
Browsing the Installed DPDK Environment Target
----------------------------------------------
-Once a target is created it contains all libraries and header files for the DPDK environment that are required to build customer applications.
+Once a target is created it contains all libraries, including poll-mode drivers, and header files for the DPDK environment that are required to build customer applications.
In addition, the test and testpmd applications are built under the build/app directory, which may be used for testing.
-A kmod directory is also present that contains kernel modules which may be loaded if needed:
+A kmod directory is also present that contains kernel modules which may be loaded if needed.
.. code-block:: console
diff --git a/doc/guides/prog_guide/source_org.rst b/doc/guides/prog_guide/source_org.rst
index 1bce0b8..269a0bc 100644
--- a/doc/guides/prog_guide/source_org.rst
+++ b/doc/guides/prog_guide/source_org.rst
@@ -95,6 +95,18 @@ The lib directory contains::
+-- librte_sched # QoS scheduler and dropper library
+-- librte_timer # timer library
+Drivers
+-------
+
+Drivers are special libraries which provide poll-mode driver implementations for
+devices - either hardware devices or pseudo/virtual devices. They are contained
+in the "drivers" subdirectory, classified by type, and each compiles to a
+library with the format "librte_pmd_X.a" where "X" is the driver name.
+
+The drivers directory has a net subdirectory which contains::
+
+ drivers/net
+
Applications
------------
diff --git a/drivers/Makefile b/drivers/Makefile
new file mode 100644
index 0000000..b60eb5e
--- /dev/null
+++ b/drivers/Makefile
@@ -0,0 +1,36 @@
+# BSD LICENSE
+#
+# Copyright(c) 2010-2015 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.
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+DIRS-y += net
+
+include $(RTE_SDK)/mk/rte.subdir.mk
diff --git a/drivers/net/Makefile b/drivers/net/Makefile
new file mode 100644
index 0000000..600a55a
--- /dev/null
+++ b/drivers/net/Makefile
@@ -0,0 +1,36 @@
+# BSD LICENSE
+#
+# Copyright(c) 2010-2015 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.
+
+include $(RTE_SDK)/mk/rte.vars.mk
+
+
+include $(RTE_SDK)/mk/rte.sharelib.mk
+include $(RTE_SDK)/mk/rte.subdir.mk