* [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions
2015-06-15 16:51 [dpdk-dev] [PATCH 0/3 v2] remove code marked as deprecated in 2.0 Stephen Hemminger
@ 2015-06-15 16:51 ` Stephen Hemminger
2015-06-16 13:52 ` Bruce Richardson
2015-06-15 16:51 ` [dpdk-dev] [PATCH 2/3] kni: " Stephen Hemminger
` (2 subsequent siblings)
3 siblings, 1 reply; 18+ messages in thread
From: Stephen Hemminger @ 2015-06-15 16:51 UTC (permalink / raw)
To: dev; +Cc: Stephen Hemminger
From: Stephen Hemminger <shemming@brocade.com>
These were deprecated in 2.0 so remove them from 2.1
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/ring/rte_eth_ring.c | 55 -------------------------------
drivers/net/ring/rte_eth_ring_version.map | 4 +--
2 files changed, 1 insertion(+), 58 deletions(-)
diff --git a/drivers/net/ring/rte_eth_ring.c b/drivers/net/ring/rte_eth_ring.c
index 6832f01..3dd96ca 100644
--- a/drivers/net/ring/rte_eth_ring.c
+++ b/drivers/net/ring/rte_eth_ring.c
@@ -390,61 +390,6 @@ eth_dev_ring_create(const char *name, const unsigned numa_node,
return 0;
}
-
-static int
-eth_dev_ring_pair_create(const char *name, const unsigned numa_node,
- enum dev_action action)
-{
- /* rx and tx are so-called from point of view of first port.
- * They are inverted from the point of view of second port
- */
- struct rte_ring *rx[RTE_PMD_RING_MAX_RX_RINGS];
- struct rte_ring *tx[RTE_PMD_RING_MAX_TX_RINGS];
- unsigned i;
- char rx_rng_name[RTE_RING_NAMESIZE];
- char tx_rng_name[RTE_RING_NAMESIZE];
- unsigned num_rings = RTE_MIN(RTE_PMD_RING_MAX_RX_RINGS,
- RTE_PMD_RING_MAX_TX_RINGS);
-
- for (i = 0; i < num_rings; i++) {
- snprintf(rx_rng_name, sizeof(rx_rng_name), "ETH_RX%u_%s", i, name);
- rx[i] = (action == DEV_CREATE) ?
- rte_ring_create(rx_rng_name, 1024, numa_node,
- RING_F_SP_ENQ|RING_F_SC_DEQ) :
- rte_ring_lookup(rx_rng_name);
- if (rx[i] == NULL)
- return -1;
- snprintf(tx_rng_name, sizeof(tx_rng_name), "ETH_TX%u_%s", i, name);
- tx[i] = (action == DEV_CREATE) ?
- rte_ring_create(tx_rng_name, 1024, numa_node,
- RING_F_SP_ENQ|RING_F_SC_DEQ):
- rte_ring_lookup(tx_rng_name);
- if (tx[i] == NULL)
- return -1;
- }
-
- if (rte_eth_from_rings(rx_rng_name, rx, num_rings, tx, num_rings,
- numa_node) || rte_eth_from_rings(tx_rng_name, tx, num_rings, rx,
- num_rings, numa_node))
- return -1;
-
- return 0;
-}
-
-int
-rte_eth_ring_pair_create(const char *name, const unsigned numa_node)
-{
- RTE_LOG(WARNING, PMD, "rte_eth_ring_pair_create is deprecated\n");
- return eth_dev_ring_pair_create(name, numa_node, DEV_CREATE);
-}
-
-int
-rte_eth_ring_pair_attach(const char *name, const unsigned numa_node)
-{
- RTE_LOG(WARNING, PMD, "rte_eth_ring_pair_attach is deprecated\n");
- return eth_dev_ring_pair_create(name, numa_node, DEV_ATTACH);
-}
-
struct node_action_pair {
char name[PATH_MAX];
unsigned node;
diff --git a/drivers/net/ring/rte_eth_ring_version.map b/drivers/net/ring/rte_eth_ring_version.map
index 8ad107d..5ee55d9 100644
--- a/drivers/net/ring/rte_eth_ring_version.map
+++ b/drivers/net/ring/rte_eth_ring_version.map
@@ -1,9 +1,7 @@
-DPDK_2.0 {
+DPDK_2.1 {
global:
rte_eth_from_rings;
- rte_eth_ring_pair_attach;
- rte_eth_ring_pair_create;
local: *;
};
--
2.1.4
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions
2015-06-15 16:51 ` [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions Stephen Hemminger
@ 2015-06-16 13:52 ` Bruce Richardson
2015-06-16 23:05 ` Stephen Hemminger
0 siblings, 1 reply; 18+ messages in thread
From: Bruce Richardson @ 2015-06-16 13:52 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev, Stephen Hemminger
On Mon, Jun 15, 2015 at 09:51:11AM -0700, Stephen Hemminger wrote:
> From: Stephen Hemminger <shemming@brocade.com>
>
> These were deprecated in 2.0 so remove them from 2.1
>
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
> drivers/net/ring/rte_eth_ring.c | 55 -------------------------------
> drivers/net/ring/rte_eth_ring_version.map | 4 +--
> 2 files changed, 1 insertion(+), 58 deletions(-)
>
[..snip..]
> diff --git a/drivers/net/ring/rte_eth_ring_version.map b/drivers/net/ring/rte_eth_ring_version.map
> index 8ad107d..5ee55d9 100644
> --- a/drivers/net/ring/rte_eth_ring_version.map
> +++ b/drivers/net/ring/rte_eth_ring_version.map
> @@ -1,9 +1,7 @@
> -DPDK_2.0 {
> +DPDK_2.1 {
> global:
>
> rte_eth_from_rings;
> - rte_eth_ring_pair_attach;
> - rte_eth_ring_pair_create;
>
> local: *;
> };
[ABI newbie question] Is this how deprecating a fn is done? We no longer have any DPDK_2.0
version listings in the .map file?
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions
2015-06-16 13:52 ` Bruce Richardson
@ 2015-06-16 23:05 ` Stephen Hemminger
2015-06-16 23:37 ` Thomas Monjalon
[not found] ` <2d83a4d8845f4daa90f0ccafbed918e3@BRMWP-EXMB11.corp.brocade.com>
0 siblings, 2 replies; 18+ messages in thread
From: Stephen Hemminger @ 2015-06-16 23:05 UTC (permalink / raw)
To: Bruce Richardson; +Cc: dev, Stephen Hemminger
On Tue, 16 Jun 2015 14:52:16 +0100
Bruce Richardson <bruce.richardson@intel.com> wrote:
> On Mon, Jun 15, 2015 at 09:51:11AM -0700, Stephen Hemminger wrote:
> > From: Stephen Hemminger <shemming@brocade.com>
> >
> > These were deprecated in 2.0 so remove them from 2.1
> >
> > Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> > ---
> > drivers/net/ring/rte_eth_ring.c | 55 -------------------------------
> > drivers/net/ring/rte_eth_ring_version.map | 4 +--
> > 2 files changed, 1 insertion(+), 58 deletions(-)
> >
> [..snip..]
> > diff --git a/drivers/net/ring/rte_eth_ring_version.map b/drivers/net/ring/rte_eth_ring_version.map
> > index 8ad107d..5ee55d9 100644
> > --- a/drivers/net/ring/rte_eth_ring_version.map
> > +++ b/drivers/net/ring/rte_eth_ring_version.map
> > @@ -1,9 +1,7 @@
> > -DPDK_2.0 {
> > +DPDK_2.1 {
> > global:
> >
> > rte_eth_from_rings;
> > - rte_eth_ring_pair_attach;
> > - rte_eth_ring_pair_create;
> >
> > local: *;
> > };
>
> [ABI newbie question] Is this how deprecating a fn is done? We no longer have any DPDK_2.0
> version listings in the .map file?
Notice the version # changed as well, so linker will generate a new version.
The function was marked deprecated in last version.
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions
2015-06-16 23:05 ` Stephen Hemminger
@ 2015-06-16 23:37 ` Thomas Monjalon
[not found] ` <2d83a4d8845f4daa90f0ccafbed918e3@BRMWP-EXMB11.corp.brocade.com>
1 sibling, 0 replies; 18+ messages in thread
From: Thomas Monjalon @ 2015-06-16 23:37 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev, Stephen Hemminger
2015-06-16 16:05, Stephen Hemminger:
> On Tue, 16 Jun 2015 14:52:16 +0100
> Bruce Richardson <bruce.richardson@intel.com> wrote:
>
> > On Mon, Jun 15, 2015 at 09:51:11AM -0700, Stephen Hemminger wrote:
> > > From: Stephen Hemminger <shemming@brocade.com>
> > >
> > > These were deprecated in 2.0 so remove them from 2.1
> > >
> > > Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> > > ---
> > > drivers/net/ring/rte_eth_ring.c | 55 -------------------------------
> > > drivers/net/ring/rte_eth_ring_version.map | 4 +--
> > > 2 files changed, 1 insertion(+), 58 deletions(-)
> > >
> > [..snip..]
> > > diff --git a/drivers/net/ring/rte_eth_ring_version.map b/drivers/net/ring/rte_eth_ring_version.map
> > > index 8ad107d..5ee55d9 100644
> > > --- a/drivers/net/ring/rte_eth_ring_version.map
> > > +++ b/drivers/net/ring/rte_eth_ring_version.map
> > > @@ -1,9 +1,7 @@
> > > -DPDK_2.0 {
> > > +DPDK_2.1 {
> > > global:
> > >
> > > rte_eth_from_rings;
> > > - rte_eth_ring_pair_attach;
> > > - rte_eth_ring_pair_create;
> > >
> > > local: *;
> > > };
> >
> > [ABI newbie question] Is this how deprecating a fn is done? We no longer have any DPDK_2.0
> > version listings in the .map file?
>
> Notice the version # changed as well, so linker will generate a new version.
> The function was marked deprecated in last version.
What happens if you load the 2.1 lib with an app built for 2.0?
Shouldn't we keep the DPDK_2.0 block?
^ permalink raw reply [flat|nested] 18+ messages in thread
[parent not found: <2d83a4d8845f4daa90f0ccafbed918e3@BRMWP-EXMB11.corp.brocade.com>]
* Re: [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions
[not found] ` <2d83a4d8845f4daa90f0ccafbed918e3@BRMWP-EXMB11.corp.brocade.com>
@ 2015-06-17 0:39 ` Stephen Hemminger
2015-06-17 7:29 ` Panu Matilainen
0 siblings, 1 reply; 18+ messages in thread
From: Stephen Hemminger @ 2015-06-17 0:39 UTC (permalink / raw)
To: Thomas Monjalon; +Cc: dev, Stephen Hemminger
On Tue, 16 Jun 2015 23:37:32 +0000
Thomas Monjalon <thomas.monjalon@6wind.com> wrote:
> 2015-06-16 16:05, Stephen Hemminger:
> > On Tue, 16 Jun 2015 14:52:16 +0100
> > Bruce Richardson <bruce.richardson@intel.com> wrote:
> >
> > > On Mon, Jun 15, 2015 at 09:51:11AM -0700, Stephen Hemminger wrote:
> > > > From: Stephen Hemminger <shemming@brocade.com>
> > > >
> > > > These were deprecated in 2.0 so remove them from 2.1
> > > >
> > > > Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> > > > ---
> > > > drivers/net/ring/rte_eth_ring.c | 55 -------------------------------
> > > > drivers/net/ring/rte_eth_ring_version.map | 4 +--
> > > > 2 files changed, 1 insertion(+), 58 deletions(-)
> > > >
> > > [..snip..]
> > > > diff --git a/drivers/net/ring/rte_eth_ring_version.map b/drivers/net/ring/rte_eth_ring_version.map
> > > > index 8ad107d..5ee55d9 100644
> > > > --- a/drivers/net/ring/rte_eth_ring_version.map
> > > > +++ b/drivers/net/ring/rte_eth_ring_version.map
> > > > @@ -1,9 +1,7 @@
> > > > -DPDK_2.0 {
> > > > +DPDK_2.1 {
> > > > global:
> > > >
> > > > rte_eth_from_rings;
> > > > - rte_eth_ring_pair_attach;
> > > > - rte_eth_ring_pair_create;
> > > >
> > > > local: *;
> > > > };
> > >
> > > [ABI newbie question] Is this how deprecating a fn is done? We no longer have any DPDK_2.0
> > > version listings in the .map file?
> >
> > Notice the version # changed as well, so linker will generate a new version.
> > The function was marked deprecated in last version.
>
> What happens if you load the 2.1 lib with an app built for 2.0?
> Shouldn't we keep the DPDK_2.0 block?
What happens is that build process makes a new version of DPDK package
with a new version number. This version can co-exist on same system with
old library (depends on library packaging).
Old library will have old functions, and old application will
use old library. New applications will be have new so version and get the
new library.
http://unix.stackexchange.com/questions/475/how-do-so-shared-object-numbers-work
If we didn't do this, nothing could ever really be removed!
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions
2015-06-17 0:39 ` Stephen Hemminger
@ 2015-06-17 7:29 ` Panu Matilainen
0 siblings, 0 replies; 18+ messages in thread
From: Panu Matilainen @ 2015-06-17 7:29 UTC (permalink / raw)
To: Stephen Hemminger, Thomas Monjalon; +Cc: dev, Stephen Hemminger
On 06/17/2015 03:39 AM, Stephen Hemminger wrote:
> On Tue, 16 Jun 2015 23:37:32 +0000
> Thomas Monjalon <thomas.monjalon@6wind.com> wrote:
>
>> 2015-06-16 16:05, Stephen Hemminger:
>>> On Tue, 16 Jun 2015 14:52:16 +0100
>>> Bruce Richardson <bruce.richardson@intel.com> wrote:
>>>
>>>> On Mon, Jun 15, 2015 at 09:51:11AM -0700, Stephen Hemminger wrote:
>>>>> From: Stephen Hemminger <shemming@brocade.com>
>>>>>
>>>>> These were deprecated in 2.0 so remove them from 2.1
>>>>>
>>>>> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
>>>>> ---
>>>>> drivers/net/ring/rte_eth_ring.c | 55 -------------------------------
>>>>> drivers/net/ring/rte_eth_ring_version.map | 4 +--
>>>>> 2 files changed, 1 insertion(+), 58 deletions(-)
>>>>>
>>>> [..snip..]
>>>>> diff --git a/drivers/net/ring/rte_eth_ring_version.map b/drivers/net/ring/rte_eth_ring_version.map
>>>>> index 8ad107d..5ee55d9 100644
>>>>> --- a/drivers/net/ring/rte_eth_ring_version.map
>>>>> +++ b/drivers/net/ring/rte_eth_ring_version.map
>>>>> @@ -1,9 +1,7 @@
>>>>> -DPDK_2.0 {
>>>>> +DPDK_2.1 {
>>>>> global:
>>>>>
>>>>> rte_eth_from_rings;
>>>>> - rte_eth_ring_pair_attach;
>>>>> - rte_eth_ring_pair_create;
>>>>>
>>>>> local: *;
>>>>> };
>>>>
>>>> [ABI newbie question] Is this how deprecating a fn is done? We no longer have any DPDK_2.0
>>>> version listings in the .map file?
>>>
>>> Notice the version # changed as well, so linker will generate a new version.
>>> The function was marked deprecated in last version.
>>
>> What happens if you load the 2.1 lib with an app built for 2.0?
>> Shouldn't we keep the DPDK_2.0 block?
>
> What happens is that build process makes a new version of DPDK package
> with a new version number. This version can co-exist on same system with
> old library (depends on library packaging).
> Old library will have old functions, and old application will
> use old library. New applications will be have new so version and get the
> new library.
>
> http://unix.stackexchange.com/questions/475/how-do-so-shared-object-numbers-work
>
> If we didn't do this, nothing could ever really be removed!
Yes, soname bump is required when symbols are removed.
However that doesn't change the version the remaining symbols were
introduced, eg rte_eth_from_rings() in this case, so AIUI you should
leave the DPDK_2.0 {} block version alone. If new symbols get added in
2.1 then a new DPDK_2.1 block needs to be added for those.
- Panu -
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions
2015-06-15 16:51 [dpdk-dev] [PATCH 0/3 v2] remove code marked as deprecated in 2.0 Stephen Hemminger
2015-06-15 16:51 ` [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions Stephen Hemminger
@ 2015-06-15 16:51 ` Stephen Hemminger
2015-06-15 16:51 ` [dpdk-dev] [PATCH 3/3] acl: mark " Stephen Hemminger
2015-08-16 22:51 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
3 siblings, 0 replies; 18+ messages in thread
From: Stephen Hemminger @ 2015-06-15 16:51 UTC (permalink / raw)
To: dev; +Cc: Stephen Hemminger
From: Stephen Hemminger <shemming@brocade.com>
These functions were tagged as deprecated in 2.0 so they can be
removed in 2.1
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Helin Zhang <helin.zhang@intel.com>
---
v2 - remove doc and version map references
app/test/Makefile | 6 ---
app/test/test_kni.c | 36 -----------------
doc/guides/prog_guide/kernel_nic_interface.rst | 2 -
lib/librte_kni/rte_kni.c | 50 ------------------------
lib/librte_kni/rte_kni.h | 54 --------------------------
lib/librte_kni/rte_kni_version.map | 4 +-
6 files changed, 1 insertion(+), 151 deletions(-)
diff --git a/app/test/Makefile b/app/test/Makefile
index 3c777bf..81bd226 100644
--- a/app/test/Makefile
+++ b/app/test/Makefile
@@ -142,12 +142,6 @@ SRCS-$(CONFIG_RTE_LIBRTE_KVARGS) += test_kvargs.c
CFLAGS += -O3
CFLAGS += $(WERROR_FLAGS)
-# Disable warnings of deprecated-declarations in test_kni.c
-ifeq ($(CC), icc)
-CFLAGS_test_kni.o += -wd1478
-else
-CFLAGS_test_kni.o += -Wno-deprecated-declarations
-endif
CFLAGS += -D_GNU_SOURCE
# Disable VTA for memcpy test
diff --git a/app/test/test_kni.c b/app/test/test_kni.c
index 506b543..9dad988 100644
--- a/app/test/test_kni.c
+++ b/app/test/test_kni.c
@@ -398,17 +398,6 @@ test_kni_processing(uint8_t port_id, struct rte_mempool *mp)
printf("fail to create kni\n");
return -1;
}
- if (rte_kni_get_port_id(kni) != port_id) {
- printf("fail to get port id\n");
- ret = -1;
- goto fail_kni;
- }
-
- if (rte_kni_info_get(RTE_MAX_ETHPORTS)) {
- printf("Unexpectedly get a KNI successfully\n");
- ret = -1;
- goto fail_kni;
- }
test_kni_ctx = kni;
test_kni_processing_flag = 0;
@@ -591,14 +580,6 @@ test_kni(void)
goto fail;
}
- /* test of getting port id according to NULL kni context */
- if (rte_kni_get_port_id(NULL) < RTE_MAX_ETHPORTS) {
- ret = -1;
- printf("unexpectedly get port id successfully by NULL kni "
- "pointer\n");
- goto fail;
- }
-
/* test of releasing NULL kni context */
ret = rte_kni_release(NULL);
if (ret == 0) {
@@ -645,23 +626,6 @@ test_kni(void)
goto fail;
}
- /* test the interface of creating a KNI, for backward compatibility */
- memset(&ops, 0, sizeof(ops));
- ops = kni_ops;
- kni = rte_kni_create(port_id, MAX_PACKET_SZ, mp, &ops);
- if (!kni) {
- ret = -1;
- printf("Fail to create a KNI device for port %d\n", port_id);
- goto fail;
- }
-
- ret = rte_kni_release(kni);
- if (ret < 0) {
- printf("Fail to release a KNI device\n");
- goto fail;
- }
-
- ret = 0;
fail:
rte_eth_dev_stop(port_id);
diff --git a/doc/guides/prog_guide/kernel_nic_interface.rst b/doc/guides/prog_guide/kernel_nic_interface.rst
index fb12d43..54a7cad 100644
--- a/doc/guides/prog_guide/kernel_nic_interface.rst
+++ b/doc/guides/prog_guide/kernel_nic_interface.rst
@@ -100,8 +100,6 @@ Refer to rte_kni_common.h in the DPDK source code for more details.
The physical addresses will be re-mapped into the kernel address space and stored in separate KNI contexts.
-Once KNI interfaces are created, the KNI context information can be queried by calling the rte_kni_info_get() function.
-
The KNI interfaces can be deleted by a DPDK application dynamically after being created.
Furthermore, all those KNI interfaces not deleted will be deleted on the release operation
of the miscellaneous device (when the DPDK application is closed).
diff --git a/lib/librte_kni/rte_kni.c b/lib/librte_kni/rte_kni.c
index 4e70fa0..f9bd9c1 100644
--- a/lib/librte_kni/rte_kni.c
+++ b/lib/librte_kni/rte_kni.c
@@ -305,31 +305,6 @@ kni_fail:
max_kni_ifaces);
}
-/* It is deprecated and just for backward compatibility */
-struct rte_kni *
-rte_kni_create(uint8_t port_id,
- unsigned mbuf_size,
- struct rte_mempool *pktmbuf_pool,
- struct rte_kni_ops *ops)
-{
- struct rte_kni_conf conf;
- struct rte_eth_dev_info info;
-
- memset(&info, 0, sizeof(info));
- memset(&conf, 0, sizeof(conf));
- rte_eth_dev_info_get(port_id, &info);
-
- snprintf(conf.name, sizeof(conf.name), "vEth%u", port_id);
- conf.addr = info.pci_dev->addr;
- conf.id = info.pci_dev->id;
- conf.group_id = (uint16_t)port_id;
- conf.mbuf_size = mbuf_size;
-
- /* Save the port id for request handling */
- ops->port_id = port_id;
-
- return rte_kni_alloc(pktmbuf_pool, &conf, ops);
-}
struct rte_kni *
rte_kni_alloc(struct rte_mempool *pktmbuf_pool,
@@ -644,16 +619,6 @@ kni_allocate_mbufs(struct rte_kni *kni)
}
}
-/* It is deprecated and just for backward compatibility */
-uint8_t
-rte_kni_get_port_id(struct rte_kni *kni)
-{
- if (!kni)
- return ~0x0;
-
- return kni->ops.port_id;
-}
-
struct rte_kni *
rte_kni_get(const char *name)
{
@@ -674,21 +639,6 @@ rte_kni_get(const char *name)
return NULL;
}
-/*
- * It is deprecated and just for backward compatibility.
- */
-struct rte_kni *
-rte_kni_info_get(uint8_t port_id)
-{
- char name[RTE_MEMZONE_NAMESIZE];
-
- if (port_id >= RTE_MAX_ETHPORTS)
- return NULL;
-
- snprintf(name, RTE_MEMZONE_NAMESIZE, "vEth%u", port_id);
-
- return rte_kni_get(name);
-}
static enum kni_ops_status
kni_check_request_register(struct rte_kni_ops *ops)
diff --git a/lib/librte_kni/rte_kni.h b/lib/librte_kni/rte_kni.h
index 603e2cd..f65ce24 100644
--- a/lib/librte_kni/rte_kni.h
+++ b/lib/librte_kni/rte_kni.h
@@ -129,30 +129,6 @@ extern struct rte_kni *rte_kni_alloc(struct rte_mempool *pktmbuf_pool,
struct rte_kni_ops *ops);
/**
- * It create a KNI device for specific port.
- *
- * Note: It is deprecated and just for backward compatibility.
- *
- * @param port_id
- * Port ID.
- * @param mbuf_size
- * mbuf size.
- * @param pktmbuf_pool
- * The mempool for allocting mbufs for packets.
- * @param ops
- * The pointer to the callbacks for the KNI kernel requests.
- *
- * @return
- * - The pointer to the context of a KNI interface.
- * - NULL indicate error.
- */
-extern struct rte_kni *rte_kni_create(uint8_t port_id,
- unsigned mbuf_size,
- struct rte_mempool *pktmbuf_pool,
- struct rte_kni_ops *ops) \
- __attribute__ ((deprecated));
-
-/**
* Release KNI interface according to the context. It will also release the
* paired KNI interface in kernel space. All processing on the specific KNI
* context need to be stopped before calling this interface.
@@ -221,21 +197,6 @@ extern unsigned rte_kni_tx_burst(struct rte_kni *kni,
struct rte_mbuf **mbufs, unsigned num);
/**
- * Get the port id from KNI interface.
- *
- * Note: It is deprecated and just for backward compatibility.
- *
- * @param kni
- * The KNI interface context.
- *
- * @return
- * On success: The port id.
- * On failure: ~0x0
- */
-extern uint8_t rte_kni_get_port_id(struct rte_kni *kni) \
- __attribute__ ((deprecated));
-
-/**
* Get the KNI context of its name.
*
* @param name
@@ -248,21 +209,6 @@ extern uint8_t rte_kni_get_port_id(struct rte_kni *kni) \
extern struct rte_kni *rte_kni_get(const char *name);
/**
- * Get the KNI context of the specific port.
- *
- * Note: It is deprecated and just for backward compatibility.
- *
- * @param port_id
- * the port id.
- *
- * @return
- * On success: Pointer to KNI interface.
- * On failure: NULL
- */
-extern struct rte_kni *rte_kni_info_get(uint8_t port_id) \
- __attribute__ ((deprecated));
-
-/**
* Register KNI request handling for a specified port,and it can
* be called by master process or slave process.
*
diff --git a/lib/librte_kni/rte_kni_version.map b/lib/librte_kni/rte_kni_version.map
index b0bbf4d..a065305 100644
--- a/lib/librte_kni/rte_kni_version.map
+++ b/lib/librte_kni/rte_kni_version.map
@@ -1,13 +1,11 @@
-DPDK_2.0 {
+DPDK_2.1 {
global:
rte_kni_alloc;
rte_kni_close;
rte_kni_create;
rte_kni_get;
- rte_kni_get_port_id;
rte_kni_handle_request;
- rte_kni_info_get;
rte_kni_init;
rte_kni_register_handlers;
rte_kni_release;
--
2.1.4
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 3/3] acl: mark deprecated functions
2015-06-15 16:51 [dpdk-dev] [PATCH 0/3 v2] remove code marked as deprecated in 2.0 Stephen Hemminger
2015-06-15 16:51 ` [dpdk-dev] [PATCH 1/3] pmd_ring: remove deprecated functions Stephen Hemminger
2015-06-15 16:51 ` [dpdk-dev] [PATCH 2/3] kni: " Stephen Hemminger
@ 2015-06-15 16:51 ` Stephen Hemminger
2015-06-17 7:59 ` Panu Matilainen
2015-08-16 22:51 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
3 siblings, 1 reply; 18+ messages in thread
From: Stephen Hemminger @ 2015-06-15 16:51 UTC (permalink / raw)
To: dev; +Cc: Stephen Hemminger
From: Stephen Hemminger <shemming@brocade.com>
To allow for compatiablity with later releases, any functions
to be removed should be marked as deprecated for one release.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
app/test/Makefile | 8 +++++++-
lib/librte_acl/rte_acl.h | 4 ++--
2 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/app/test/Makefile b/app/test/Makefile
index 81bd226..061a83d 100644
--- a/app/test/Makefile
+++ b/app/test/Makefile
@@ -141,9 +141,15 @@ SRCS-$(CONFIG_RTE_LIBRTE_KVARGS) += test_kvargs.c
CFLAGS += -O3
CFLAGS += $(WERROR_FLAGS)
-
CFLAGS += -D_GNU_SOURCE
+# Disable warnings of deprecated-declarations in test_acl.c
+ifeq ($(CC), icc)
+CFLAGS_test_acl.o += -wd1478
+else
+CFLAGS_test_acl.o += -Wno-deprecated-declarations
+endif
+
# Disable VTA for memcpy test
ifeq ($(CC), gcc)
ifeq ($(shell test $(GCC_VERSION) -ge 44 && echo 1), 1)
diff --git a/lib/librte_acl/rte_acl.h b/lib/librte_acl/rte_acl.h
index 3a93730..0c32df0 100644
--- a/lib/librte_acl/rte_acl.h
+++ b/lib/librte_acl/rte_acl.h
@@ -456,7 +456,7 @@ enum {
int
rte_acl_ipv4vlan_add_rules(struct rte_acl_ctx *ctx,
const struct rte_acl_ipv4vlan_rule *rules,
- uint32_t num);
+ uint32_t num) __attribute__((deprecated));
/**
* Analyze set of ipv4vlan rules and build required internal
@@ -478,7 +478,7 @@ rte_acl_ipv4vlan_add_rules(struct rte_acl_ctx *ctx,
int
rte_acl_ipv4vlan_build(struct rte_acl_ctx *ctx,
const uint32_t layout[RTE_ACL_IPV4VLAN_NUM],
- uint32_t num_categories);
+ uint32_t num_categories) __attribute__((deprecated));
#ifdef __cplusplus
--
2.1.4
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 3/3] acl: mark deprecated functions
2015-06-15 16:51 ` [dpdk-dev] [PATCH 3/3] acl: mark " Stephen Hemminger
@ 2015-06-17 7:59 ` Panu Matilainen
0 siblings, 0 replies; 18+ messages in thread
From: Panu Matilainen @ 2015-06-17 7:59 UTC (permalink / raw)
To: Stephen Hemminger, dev; +Cc: Stephen Hemminger
On 06/15/2015 07:51 PM, Stephen Hemminger wrote:
> From: Stephen Hemminger <shemming@brocade.com>
>
> To allow for compatiablity with later releases, any functions
> to be removed should be marked as deprecated for one release.
>
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
[...]
> diff --git a/lib/librte_acl/rte_acl.h b/lib/librte_acl/rte_acl.h
> index 3a93730..0c32df0 100644
> --- a/lib/librte_acl/rte_acl.h
> +++ b/lib/librte_acl/rte_acl.h
> @@ -456,7 +456,7 @@ enum {
> int
> rte_acl_ipv4vlan_add_rules(struct rte_acl_ctx *ctx,
> const struct rte_acl_ipv4vlan_rule *rules,
> - uint32_t num);
> + uint32_t num) __attribute__((deprecated));
>
> /**
> * Analyze set of ipv4vlan rules and build required internal
> @@ -478,7 +478,7 @@ rte_acl_ipv4vlan_add_rules(struct rte_acl_ctx *ctx,
> int
> rte_acl_ipv4vlan_build(struct rte_acl_ctx *ctx,
> const uint32_t layout[RTE_ACL_IPV4VLAN_NUM],
> - uint32_t num_categories);
> + uint32_t num_categories) __attribute__((deprecated));
>
>
> #ifdef __cplusplus
>
I've no objections to the patch as such, but I think the ABI policy is
asking all deprecation notices to be added to the "Deprecation Notices"
section in the policy document itself.
That said, the average developer is MUCH likelier to notice the compiler
warning from these than a deprecation notice in some "who reads those"
document :) Perhaps we could generate a list of functions marked for
removal for the ABI policy document automatically based on the
deprecated attributes.
- Panu -
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated
2015-06-15 16:51 [dpdk-dev] [PATCH 0/3 v2] remove code marked as deprecated in 2.0 Stephen Hemminger
` (2 preceding siblings ...)
2015-06-15 16:51 ` [dpdk-dev] [PATCH 3/3] acl: mark " Stephen Hemminger
@ 2015-08-16 22:51 ` Thomas Monjalon
2015-08-16 22:51 ` [dpdk-dev] [PATCH 1/3] doc: announce legacy 7-tuple acl rule removal Thomas Monjalon
` (3 more replies)
3 siblings, 4 replies; 18+ messages in thread
From: Thomas Monjalon @ 2015-08-16 22:51 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev
As suugested by Stephen, some functions are marked as deprecated in the code
and should now be removed.
Let's follow the deprecation process and announce it in the release notes.
Thomas Monjalon (3):
doc: announce legacy 7-tuple acl rule removal
doc: announce removal of kni functions using port id
doc: announce ring PMD functions removal
doc/guides/rel_notes/deprecation.rst | 10 ++++++++++
1 file changed, 10 insertions(+)
--
2.4.2
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 1/3] doc: announce legacy 7-tuple acl rule removal
2015-08-16 22:51 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
@ 2015-08-16 22:51 ` Thomas Monjalon
2015-08-16 22:51 ` [dpdk-dev] [PATCH 2/3] doc: announce removal of kni functions using port id Thomas Monjalon
` (2 subsequent siblings)
3 siblings, 0 replies; 18+ messages in thread
From: Thomas Monjalon @ 2015-08-16 22:51 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev
These functions are marked as deprecated for a long time.
As suggested in this patch, it should be removed:
http://dpdk.org/ml/archives/dev/2015-June/019255.html
Suggested-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
---
doc/guides/rel_notes/deprecation.rst | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst
index 8365981..a9a12c6 100644
--- a/doc/guides/rel_notes/deprecation.rst
+++ b/doc/guides/rel_notes/deprecation.rst
@@ -71,6 +71,10 @@ Deprecation Notices
* The scheduler statistics structure will change to allow keeping track of
RED actions.
+* librte_acl: The structure rte_acl_ipv4vlan_rule is deprecated and should
+ be removed as well as the associated functions rte_acl_ipv4vlan_add_rules
+ and rte_acl_ipv4vlan_build.
+
* librte_cfgfile: In order to allow for longer names and values,
the value of macros CFG_NAME_LEN and CFG_NAME_VAL will be increased.
Most likely, the new values will be 64 and 256, respectively.
--
2.4.2
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 2/3] doc: announce removal of kni functions using port id
2015-08-16 22:51 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
2015-08-16 22:51 ` [dpdk-dev] [PATCH 1/3] doc: announce legacy 7-tuple acl rule removal Thomas Monjalon
@ 2015-08-16 22:51 ` Thomas Monjalon
2015-08-16 22:51 ` [dpdk-dev] [PATCH 3/3] doc: announce ring PMD functions removal Thomas Monjalon
2015-08-17 14:42 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
3 siblings, 0 replies; 18+ messages in thread
From: Thomas Monjalon @ 2015-08-16 22:51 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev
These functions are marked as deprecated for a long time:
fbf895d44cfe ("kni: identify device by name")
As suggested in this patch, it should be removed:
http://dpdk.org/ml/archives/dev/2015-June/019254.html
Suggested-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
---
doc/guides/rel_notes/deprecation.rst | 3 +++
1 file changed, 3 insertions(+)
diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst
index a9a12c6..2424c61 100644
--- a/doc/guides/rel_notes/deprecation.rst
+++ b/doc/guides/rel_notes/deprecation.rst
@@ -58,6 +58,9 @@ Deprecation Notices
the tunnel type, TNI/VNI, inner MAC and inner VLAN are monitored.
The release 2.2 will contain these changes without backwards compatibility.
+* librte_kni: Functions based on port id are deprecated for a long time and
+ should be removed (rte_kni_create, rte_kni_get_port_id and rte_kni_info_get).
+
* ABI changes are planned for struct virtio_net in order to support vhost-user
multiple queues feature.
It should be integrated in release 2.2 without backward compatibility.
--
2.4.2
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 3/3] doc: announce ring PMD functions removal
2015-08-16 22:51 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
2015-08-16 22:51 ` [dpdk-dev] [PATCH 1/3] doc: announce legacy 7-tuple acl rule removal Thomas Monjalon
2015-08-16 22:51 ` [dpdk-dev] [PATCH 2/3] doc: announce removal of kni functions using port id Thomas Monjalon
@ 2015-08-16 22:51 ` Thomas Monjalon
2015-08-17 14:42 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
3 siblings, 0 replies; 18+ messages in thread
From: Thomas Monjalon @ 2015-08-16 22:51 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev
These functions are marked as deprecated for a long time:
61934c0956d4 ("ring: convert to use of PMD_REGISTER_DRIVER and fix linking")
As suggested in this patch, it should be removed:
http://dpdk.org/ml/archives/dev/2015-June/019253.html
Suggested-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
---
doc/guides/rel_notes/deprecation.rst | 3 +++
1 file changed, 3 insertions(+)
diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst
index 2424c61..46a88ca 100644
--- a/doc/guides/rel_notes/deprecation.rst
+++ b/doc/guides/rel_notes/deprecation.rst
@@ -61,6 +61,9 @@ Deprecation Notices
* librte_kni: Functions based on port id are deprecated for a long time and
should be removed (rte_kni_create, rte_kni_get_port_id and rte_kni_info_get).
+* librte_pmd_ring: The deprecated functions rte_eth_ring_pair_create and
+ rte_eth_ring_pair_attach should be removed.
+
* ABI changes are planned for struct virtio_net in order to support vhost-user
multiple queues feature.
It should be integrated in release 2.2 without backward compatibility.
--
2.4.2
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated
2015-08-16 22:51 ` [dpdk-dev] [PATCH 0/3] announce deprecation of functions commented as deprecated Thomas Monjalon
` (2 preceding siblings ...)
2015-08-16 22:51 ` [dpdk-dev] [PATCH 3/3] doc: announce ring PMD functions removal Thomas Monjalon
@ 2015-08-17 14:42 ` Thomas Monjalon
3 siblings, 0 replies; 18+ messages in thread
From: Thomas Monjalon @ 2015-08-17 14:42 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: dev
2015-08-17 00:51, Thomas Monjalon:
> As suugested by Stephen, some functions are marked as deprecated in the code
> and should now be removed.
> Let's follow the deprecation process and announce it in the release notes.
>
> Thomas Monjalon (3):
> doc: announce legacy 7-tuple acl rule removal
> doc: announce removal of kni functions using port id
> doc: announce ring PMD functions removal
Applied
^ permalink raw reply [flat|nested] 18+ messages in thread
* [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions
2015-06-12 5:18 [dpdk-dev] [PATCH 0/3] do deprecation in 2.1 Stephen Hemminger
@ 2015-06-12 5:18 ` Stephen Hemminger
2015-06-12 6:20 ` Panu Matilainen
2015-06-15 2:35 ` Zhang, Helin
0 siblings, 2 replies; 18+ messages in thread
From: Stephen Hemminger @ 2015-06-12 5:18 UTC (permalink / raw)
To: dev; +Cc: Stephen Hemminger
From: Stephen Hemminger <shemming@brocade.com>
These functions were tagged as deprecated in 2.0 so they can be
removed in 2.1
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
app/test/Makefile | 6 ------
app/test/test_kni.c | 36 --------------------------------
lib/librte_kni/rte_kni.c | 50 --------------------------------------------
lib/librte_kni/rte_kni.h | 54 ------------------------------------------------
4 files changed, 146 deletions(-)
diff --git a/app/test/Makefile b/app/test/Makefile
index 3c777bf..81bd226 100644
--- a/app/test/Makefile
+++ b/app/test/Makefile
@@ -142,12 +142,6 @@ SRCS-$(CONFIG_RTE_LIBRTE_KVARGS) += test_kvargs.c
CFLAGS += -O3
CFLAGS += $(WERROR_FLAGS)
-# Disable warnings of deprecated-declarations in test_kni.c
-ifeq ($(CC), icc)
-CFLAGS_test_kni.o += -wd1478
-else
-CFLAGS_test_kni.o += -Wno-deprecated-declarations
-endif
CFLAGS += -D_GNU_SOURCE
# Disable VTA for memcpy test
diff --git a/app/test/test_kni.c b/app/test/test_kni.c
index 506b543..9dad988 100644
--- a/app/test/test_kni.c
+++ b/app/test/test_kni.c
@@ -398,17 +398,6 @@ test_kni_processing(uint8_t port_id, struct rte_mempool *mp)
printf("fail to create kni\n");
return -1;
}
- if (rte_kni_get_port_id(kni) != port_id) {
- printf("fail to get port id\n");
- ret = -1;
- goto fail_kni;
- }
-
- if (rte_kni_info_get(RTE_MAX_ETHPORTS)) {
- printf("Unexpectedly get a KNI successfully\n");
- ret = -1;
- goto fail_kni;
- }
test_kni_ctx = kni;
test_kni_processing_flag = 0;
@@ -591,14 +580,6 @@ test_kni(void)
goto fail;
}
- /* test of getting port id according to NULL kni context */
- if (rte_kni_get_port_id(NULL) < RTE_MAX_ETHPORTS) {
- ret = -1;
- printf("unexpectedly get port id successfully by NULL kni "
- "pointer\n");
- goto fail;
- }
-
/* test of releasing NULL kni context */
ret = rte_kni_release(NULL);
if (ret == 0) {
@@ -645,23 +626,6 @@ test_kni(void)
goto fail;
}
- /* test the interface of creating a KNI, for backward compatibility */
- memset(&ops, 0, sizeof(ops));
- ops = kni_ops;
- kni = rte_kni_create(port_id, MAX_PACKET_SZ, mp, &ops);
- if (!kni) {
- ret = -1;
- printf("Fail to create a KNI device for port %d\n", port_id);
- goto fail;
- }
-
- ret = rte_kni_release(kni);
- if (ret < 0) {
- printf("Fail to release a KNI device\n");
- goto fail;
- }
-
- ret = 0;
fail:
rte_eth_dev_stop(port_id);
diff --git a/lib/librte_kni/rte_kni.c b/lib/librte_kni/rte_kni.c
index 4e70fa0..f9bd9c1 100644
--- a/lib/librte_kni/rte_kni.c
+++ b/lib/librte_kni/rte_kni.c
@@ -305,31 +305,6 @@ kni_fail:
max_kni_ifaces);
}
-/* It is deprecated and just for backward compatibility */
-struct rte_kni *
-rte_kni_create(uint8_t port_id,
- unsigned mbuf_size,
- struct rte_mempool *pktmbuf_pool,
- struct rte_kni_ops *ops)
-{
- struct rte_kni_conf conf;
- struct rte_eth_dev_info info;
-
- memset(&info, 0, sizeof(info));
- memset(&conf, 0, sizeof(conf));
- rte_eth_dev_info_get(port_id, &info);
-
- snprintf(conf.name, sizeof(conf.name), "vEth%u", port_id);
- conf.addr = info.pci_dev->addr;
- conf.id = info.pci_dev->id;
- conf.group_id = (uint16_t)port_id;
- conf.mbuf_size = mbuf_size;
-
- /* Save the port id for request handling */
- ops->port_id = port_id;
-
- return rte_kni_alloc(pktmbuf_pool, &conf, ops);
-}
struct rte_kni *
rte_kni_alloc(struct rte_mempool *pktmbuf_pool,
@@ -644,16 +619,6 @@ kni_allocate_mbufs(struct rte_kni *kni)
}
}
-/* It is deprecated and just for backward compatibility */
-uint8_t
-rte_kni_get_port_id(struct rte_kni *kni)
-{
- if (!kni)
- return ~0x0;
-
- return kni->ops.port_id;
-}
-
struct rte_kni *
rte_kni_get(const char *name)
{
@@ -674,21 +639,6 @@ rte_kni_get(const char *name)
return NULL;
}
-/*
- * It is deprecated and just for backward compatibility.
- */
-struct rte_kni *
-rte_kni_info_get(uint8_t port_id)
-{
- char name[RTE_MEMZONE_NAMESIZE];
-
- if (port_id >= RTE_MAX_ETHPORTS)
- return NULL;
-
- snprintf(name, RTE_MEMZONE_NAMESIZE, "vEth%u", port_id);
-
- return rte_kni_get(name);
-}
static enum kni_ops_status
kni_check_request_register(struct rte_kni_ops *ops)
diff --git a/lib/librte_kni/rte_kni.h b/lib/librte_kni/rte_kni.h
index 603e2cd..f65ce24 100644
--- a/lib/librte_kni/rte_kni.h
+++ b/lib/librte_kni/rte_kni.h
@@ -129,30 +129,6 @@ extern struct rte_kni *rte_kni_alloc(struct rte_mempool *pktmbuf_pool,
struct rte_kni_ops *ops);
/**
- * It create a KNI device for specific port.
- *
- * Note: It is deprecated and just for backward compatibility.
- *
- * @param port_id
- * Port ID.
- * @param mbuf_size
- * mbuf size.
- * @param pktmbuf_pool
- * The mempool for allocting mbufs for packets.
- * @param ops
- * The pointer to the callbacks for the KNI kernel requests.
- *
- * @return
- * - The pointer to the context of a KNI interface.
- * - NULL indicate error.
- */
-extern struct rte_kni *rte_kni_create(uint8_t port_id,
- unsigned mbuf_size,
- struct rte_mempool *pktmbuf_pool,
- struct rte_kni_ops *ops) \
- __attribute__ ((deprecated));
-
-/**
* Release KNI interface according to the context. It will also release the
* paired KNI interface in kernel space. All processing on the specific KNI
* context need to be stopped before calling this interface.
@@ -221,21 +197,6 @@ extern unsigned rte_kni_tx_burst(struct rte_kni *kni,
struct rte_mbuf **mbufs, unsigned num);
/**
- * Get the port id from KNI interface.
- *
- * Note: It is deprecated and just for backward compatibility.
- *
- * @param kni
- * The KNI interface context.
- *
- * @return
- * On success: The port id.
- * On failure: ~0x0
- */
-extern uint8_t rte_kni_get_port_id(struct rte_kni *kni) \
- __attribute__ ((deprecated));
-
-/**
* Get the KNI context of its name.
*
* @param name
@@ -248,21 +209,6 @@ extern uint8_t rte_kni_get_port_id(struct rte_kni *kni) \
extern struct rte_kni *rte_kni_get(const char *name);
/**
- * Get the KNI context of the specific port.
- *
- * Note: It is deprecated and just for backward compatibility.
- *
- * @param port_id
- * the port id.
- *
- * @return
- * On success: Pointer to KNI interface.
- * On failure: NULL
- */
-extern struct rte_kni *rte_kni_info_get(uint8_t port_id) \
- __attribute__ ((deprecated));
-
-/**
* Register KNI request handling for a specified port,and it can
* be called by master process or slave process.
*
--
2.1.4
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions
2015-06-12 5:18 ` [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions Stephen Hemminger
@ 2015-06-12 6:20 ` Panu Matilainen
2015-06-15 2:35 ` Zhang, Helin
1 sibling, 0 replies; 18+ messages in thread
From: Panu Matilainen @ 2015-06-12 6:20 UTC (permalink / raw)
To: Stephen Hemminger, dev; +Cc: Stephen Hemminger
On 06/12/2015 08:18 AM, Stephen Hemminger wrote:
> From: Stephen Hemminger <shemming@brocade.com>
>
> These functions were tagged as deprecated in 2.0 so they can be
> removed in 2.1
>
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
> app/test/Makefile | 6 ------
> app/test/test_kni.c | 36 --------------------------------
> lib/librte_kni/rte_kni.c | 50 --------------------------------------------
> lib/librte_kni/rte_kni.h | 54 ------------------------------------------------
> 4 files changed, 146 deletions(-)
>
[...]
> diff --git a/lib/librte_kni/rte_kni.h b/lib/librte_kni/rte_kni.h
> index 603e2cd..f65ce24 100644
> --- a/lib/librte_kni/rte_kni.h
> +++ b/lib/librte_kni/rte_kni.h
> @@ -129,30 +129,6 @@ extern struct rte_kni *rte_kni_alloc(struct rte_mempool *pktmbuf_pool,
> struct rte_kni_ops *ops);
>
> /**
> - * It create a KNI device for specific port.
> - *
> - * Note: It is deprecated and just for backward compatibility.
> - *
> - * @param port_id
> - * Port ID.
> - * @param mbuf_size
> - * mbuf size.
> - * @param pktmbuf_pool
> - * The mempool for allocting mbufs for packets.
> - * @param ops
> - * The pointer to the callbacks for the KNI kernel requests.
> - *
> - * @return
> - * - The pointer to the context of a KNI interface.
> - * - NULL indicate error.
> - */
> -extern struct rte_kni *rte_kni_create(uint8_t port_id,
> - unsigned mbuf_size,
> - struct rte_mempool *pktmbuf_pool,
> - struct rte_kni_ops *ops) \
> - __attribute__ ((deprecated));
> -
> -/**
> * Release KNI interface according to the context. It will also release the
> * paired KNI interface in kernel space. All processing on the specific KNI
> * context need to be stopped before calling this interface.
> @@ -221,21 +197,6 @@ extern unsigned rte_kni_tx_burst(struct rte_kni *kni,
> struct rte_mbuf **mbufs, unsigned num);
>
> /**
> - * Get the port id from KNI interface.
> - *
> - * Note: It is deprecated and just for backward compatibility.
> - *
> - * @param kni
> - * The KNI interface context.
> - *
> - * @return
> - * On success: The port id.
> - * On failure: ~0x0
> - */
> -extern uint8_t rte_kni_get_port_id(struct rte_kni *kni) \
> - __attribute__ ((deprecated));
> -
> -/**
> * Get the KNI context of its name.
> *
> * @param name
> @@ -248,21 +209,6 @@ extern uint8_t rte_kni_get_port_id(struct rte_kni *kni) \
> extern struct rte_kni *rte_kni_get(const char *name);
>
> /**
> - * Get the KNI context of the specific port.
> - *
> - * Note: It is deprecated and just for backward compatibility.
> - *
> - * @param port_id
> - * the port id.
> - *
> - * @return
> - * On success: Pointer to KNI interface.
> - * On failure: NULL
> - */
> -extern struct rte_kni *rte_kni_info_get(uint8_t port_id) \
> - __attribute__ ((deprecated));
> -
> -/**
> * Register KNI request handling for a specified port,and it can
> * be called by master process or slave process.
> *
>
These symbols need to be removed from rte_kni_version.map too, and since
its an ABI break, the library soname needs a bump as well.
- Panu -
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions
2015-06-12 5:18 ` [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions Stephen Hemminger
2015-06-12 6:20 ` Panu Matilainen
@ 2015-06-15 2:35 ` Zhang, Helin
1 sibling, 0 replies; 18+ messages in thread
From: Zhang, Helin @ 2015-06-15 2:35 UTC (permalink / raw)
To: Stephen Hemminger, dev; +Cc: Stephen Hemminger
> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Stephen Hemminger
> Sent: Friday, June 12, 2015 1:19 PM
> To: dev@dpdk.org
> Cc: Stephen Hemminger
> Subject: [dpdk-dev] [PATCH 2/3] kni: remove deprecated functions
>
> From: Stephen Hemminger <shemming@brocade.com>
>
> These functions were tagged as deprecated in 2.0 so they can be removed in 2.1
>
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Helin Zhang <helin.zhang@intel.com>
> ---
> app/test/Makefile | 6 ------
> app/test/test_kni.c | 36 --------------------------------
> lib/librte_kni/rte_kni.c | 50 --------------------------------------------
> lib/librte_kni/rte_kni.h | 54 ------------------------------------------------
> 4 files changed, 146 deletions(-)
^ permalink raw reply [flat|nested] 18+ messages in thread