diff mbox series

[2.0,v2,6/6] linux-gen: pktio: remove duplicate pktio_ops subsystem implementation

Message ID 1508857207-23099-7-git-send-email-odpbot@yandex.ru
State New
Headers show
Series [2.0,v2,1/6] linux-dpdk: pktio: dpdk: build dpdk pktio based on configuration option | expand

Commit Message

Github ODP bot Oct. 24, 2017, 3 p.m. UTC
From: Bogdan Pricope <bogdan.pricope@linaro.org>


Remove duplicate pktio_ops subsystem implementation

Signed-off-by: Bogdan Pricope <bogdan.pricope@linaro.org>

---
/** Email created from pull request 255 (bogdanPricope:2_0_pktio_sub_unif_pr)
 ** https://github.com/Linaro/odp/pull/255
 ** Patch: https://github.com/Linaro/odp/pull/255.patch
 ** Base sha: d37aa7f1c0480273fb0ccfded44a13e3e5a8e42f
 ** Merge commit sha: 7ba6d7f0e026041bb48d6d90f02d9b556020c337
 **/
 platform/linux-dpdk/Makefile.am          |  2 +-
 platform/linux-dpdk/pktio/subsystem.c    | 39 --------------------------------
 platform/linux-generic/pktio/subsystem.c |  2 ++
 3 files changed, 3 insertions(+), 40 deletions(-)
 delete mode 100644 platform/linux-dpdk/pktio/subsystem.c
diff mbox series

Patch

diff --git a/platform/linux-dpdk/Makefile.am b/platform/linux-dpdk/Makefile.am
index c99cfaa1c..e2a0249df 100644
--- a/platform/linux-dpdk/Makefile.am
+++ b/platform/linux-dpdk/Makefile.am
@@ -251,7 +251,7 @@  __LIB__libodp_dpdk_la_SOURCES = \
 			   ../linux-generic/odp_name_table.c \
 			   odp_packet.c \
 			   pktio/dpdk.c \
-			   pktio/subsystem.c \
+			   ../linux-generic/pktio/subsystem.c \
 			   odp_packet_flags.c \
 			   ../linux-generic/odp_packet_io.c \
 			   ../linux-generic/pktio/loopback.c \
diff --git a/platform/linux-dpdk/pktio/subsystem.c b/platform/linux-dpdk/pktio/subsystem.c
deleted file mode 100644
index ab99db0d5..000000000
--- a/platform/linux-dpdk/pktio/subsystem.c
+++ /dev/null
@@ -1,39 +0,0 @@ 
-/* Copyright (c) 2017, ARM Limited. All rights reserved.
- *
- * Copyright (c) 2017, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier: BSD-3-Clause
- */
-
-#include <config.h>
-
-#include <odp_debug_internal.h>
-#include <odp_packet_io_internal.h>
-
-#define SUBSYSTEM_VERSION 0x00010000UL
-ODP_SUBSYSTEM_DEFINE(pktio_ops, "packet IO operations", SUBSYSTEM_VERSION);
-
-/* Instantiate init and term functions */
-ODP_SUBSYSTEM_FOREACH_TEMPLATE(pktio_ops, init_global, ODP_ERR)
-ODP_SUBSYSTEM_FOREACH_TEMPLATE(pktio_ops, init_local, ODP_ERR)
-ODP_SUBSYSTEM_FOREACH_TEMPLATE(pktio_ops, term_global, ODP_ABORT)
-
-/* Temporary variable to enable link modules,
- * will remove in Makefile scheme changes.
- */
-#ifdef ODP_PKTIO_DPDK
-extern int enable_link_dpdk_pktio_ops;
-#endif
-extern int enable_link_loopback_pktio_ops;
-
-ODP_SUBSYSTEM_CONSTRUCTOR(pktio_ops)
-{
-	odp_subsystem_constructor(pktio_ops);
-
-	/* Further initialization per subsystem */
-#ifdef ODP_PKTIO_DPDK
-	enable_link_dpdk_pktio_ops = 1;
-#endif
-	enable_link_loopback_pktio_ops = 1;
-}
diff --git a/platform/linux-generic/pktio/subsystem.c b/platform/linux-generic/pktio/subsystem.c
index d26c152c3..a3b36c144 100644
--- a/platform/linux-generic/pktio/subsystem.c
+++ b/platform/linux-generic/pktio/subsystem.c
@@ -6,6 +6,8 @@ 
  * SPDX-License-Identifier: BSD-3-Clause
  */
 
+#include <config.h>
+
 #include <odp_debug_internal.h>
 #include <odp_packet_io_internal.h>