From patchwork Wed Jul 11 14:14:09 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Rybchenko X-Patchwork-Id: 42880 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BDFAE1B5D3; Wed, 11 Jul 2018 16:14:35 +0200 (CEST) Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [148.163.129.52]) by dpdk.org (Postfix) with ESMTP id 3F37E1B5AA for ; Wed, 11 Jul 2018 16:14:29 +0200 (CEST) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (webmail.solarflare.com [12.187.104.26]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1-us3.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id 29B4A60005D; Wed, 11 Jul 2018 14:14:28 +0000 (UTC) Received: from sfocexch01r.SolarFlarecom.com (10.20.40.34) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Wed, 11 Jul 2018 07:14:25 -0700 Received: from ocex03.SolarFlarecom.com (10.20.40.36) by sfocexch01r.SolarFlarecom.com (10.20.40.34) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Wed, 11 Jul 2018 07:14:24 -0700 Received: from opal.uk.solarflarecom.com (10.17.10.1) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1044.25 via Frontend Transport; Wed, 11 Jul 2018 07:14:23 -0700 Received: from ukv-loginhost.uk.solarflarecom.com (ukv-loginhost.uk.solarflarecom.com [10.17.10.39]) by opal.uk.solarflarecom.com (8.13.8/8.13.8) with ESMTP id w6BEEMww021498; Wed, 11 Jul 2018 15:14:22 +0100 Received: from ukv-loginhost.uk.solarflarecom.com (localhost [127.0.0.1]) by ukv-loginhost.uk.solarflarecom.com (Postfix) with ESMTP id 6A9E916546C; Wed, 11 Jul 2018 15:14:22 +0100 (BST) From: Andrew Rybchenko To: CC: Thomas Monjalon Date: Wed, 11 Jul 2018 15:14:09 +0100 Message-ID: <1531318450-3942-3-git-send-email-arybchenko@solarflare.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1531318450-3942-1-git-send-email-arybchenko@solarflare.com> References: <1531318450-3942-1-git-send-email-arybchenko@solarflare.com> MIME-Version: 1.0 X-MDID: 1531318468-ZjFUWdZYoeYX Subject: [dpdk-dev] [PATCH 2/3] ethdev: deprecate attach and detach functions X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" These functions are buggy from the very beginning and should not be used. Generic EAL hotplug mechanisms should be used instead. Signed-off-by: Andrew Rybchenko --- app/test-pmd/Makefile | 1 + app/test-pmd/meson.build | 1 + doc/guides/rel_notes/deprecation.rst | 7 +++++++ lib/librte_ethdev/rte_ethdev.h | 2 ++ 4 files changed, 11 insertions(+) diff --git a/app/test-pmd/Makefile b/app/test-pmd/Makefile index a5a827bbd..ae9897510 100644 --- a/app/test-pmd/Makefile +++ b/app/test-pmd/Makefile @@ -13,6 +13,7 @@ APP = testpmd CFLAGS += -DALLOW_EXPERIMENTAL_API CFLAGS += -O3 CFLAGS += $(WERROR_FLAGS) +CFLAGS += -Wno-deprecated-declarations # # all source are stored in SRCS-y diff --git a/app/test-pmd/meson.build b/app/test-pmd/meson.build index 4c9fbbfda..861e157ea 100644 --- a/app/test-pmd/meson.build +++ b/app/test-pmd/meson.build @@ -4,6 +4,7 @@ # override default name to drop the hyphen name = 'testpmd' allow_experimental_apis = true +cflags += '-Wno-deprecated-declarations' sources = files('cmdline.c', 'cmdline_flow.c', 'cmdline_mtr.c', diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index 8df41cb6a..fc3bf1a0b 100644 --- a/doc/guides/rel_notes/deprecation.rst +++ b/doc/guides/rel_notes/deprecation.rst @@ -72,6 +72,13 @@ Deprecation Notices Target release for removal of the legacy API will be defined once most PMDs have switched to rte_flow. +* ethdev: In v18.11 ``rte_eth_dev_attach()`` and ``rte_eth_dev_detach()`` + will be removed. + Hotplug functions ``rte_eal_hotplug_add()`` and ``rte_eal_hotplug_remove()`` + should be used instread. + Function ``rte_eth_dev_get_port_by_name()`` may be used to find + identifier of the added port. + * pdump: As we changed to use generic IPC, some changes in APIs and structure are expected in subsequent release. diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h index f5f593b31..46c569a7f 100644 --- a/lib/librte_ethdev/rte_ethdev.h +++ b/lib/librte_ethdev/rte_ethdev.h @@ -1433,6 +1433,7 @@ uint16_t __rte_experimental rte_eth_dev_count_total(void); * @return * 0 on success and port_id is filled, negative on error */ +__rte_deprecated int rte_eth_dev_attach(const char *devargs, uint16_t *port_id); /** @@ -1448,6 +1449,7 @@ int rte_eth_dev_attach(const char *devargs, uint16_t *port_id); * @return * 0 on success and devname is filled, negative on error */ +__rte_deprecated int rte_eth_dev_detach(uint16_t port_id, char *devname); /**