DPDK-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: dev@dpdk.org
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	Thomas Monjalon <thomas@monjalon.net>,
	Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Subject: [PATCH 04/22] ethdev: promote hairpin API to stable
Date: Tue,  1 Sep 2026 13:23:03 -0700	[thread overview]
Message-ID: <20260901203217.1485915-5-stephen@networkplumber.org> (raw)
In-Reply-To: <20260901203217.1485915-1-stephen@networkplumber.org>

Hairpin support was introduced in v19.11 with the queue setup and
capability query functions, and completed in v20.11 with the
explicit bind/unbind and peer port query functions:

  19.11  rte_eth_rx_hairpin_queue_setup
         rte_eth_tx_hairpin_queue_setup
         rte_eth_dev_hairpin_capability_get
  20.11  rte_eth_hairpin_bind
         rte_eth_hairpin_unbind
         rte_eth_hairpin_get_peer_ports

The interface has been unchanged since and is implemented by
several PMDs, so promote the feature as a whole.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 doc/guides/rel_notes/release_26_11.rst |  6 +++++
 lib/ethdev/rte_ethdev.c                | 12 ++++-----
 lib/ethdev/rte_ethdev.h                | 36 --------------------------
 3 files changed, 12 insertions(+), 42 deletions(-)

diff --git a/doc/guides/rel_notes/release_26_11.rst b/doc/guides/rel_notes/release_26_11.rst
index 77ee3380f9..8a60d21a1d 100644
--- a/doc/guides/rel_notes/release_26_11.rst
+++ b/doc/guides/rel_notes/release_26_11.rst
@@ -100,6 +100,12 @@ API Changes
   * meter (MTR) and policing: ``rte_mtr_*``
   * SFF: ``rte_eth_dev_get_module_info`` and ``rte_eth_dev_get_module_eeprom``
   * flow conversion: ``rte_flow_conv``
+  * hairpin queue: ``rte_eth_rx_hairpin_queue_setup``,
+    ``rte_eth_tx_hairpin_queue_setup``,
+    ``rte_eth_dev_hairpin_capability_get``,
+    ``rte_eth_hairpin_bind``,
+    ``rte_eth_hairpin_unbind``,
+    ``rte_eth_hairpin_get_peer_ports``
 
 
 ABI Changes
diff --git a/lib/ethdev/rte_ethdev.c b/lib/ethdev/rte_ethdev.c
index 78ad12c2c0..f27f698406 100644
--- a/lib/ethdev/rte_ethdev.c
+++ b/lib/ethdev/rte_ethdev.c
@@ -2506,7 +2506,7 @@ rte_eth_rx_queue_setup(uint16_t port_id, uint16_t rx_queue_id,
 	return eth_err(port_id, ret);
 }
 
-RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_eth_rx_hairpin_queue_setup, 19.11)
+RTE_EXPORT_SYMBOL(rte_eth_rx_hairpin_queue_setup)
 int
 rte_eth_rx_hairpin_queue_setup(uint16_t port_id, uint16_t rx_queue_id,
 			       uint16_t nb_rx_desc,
@@ -2724,7 +2724,7 @@ rte_eth_tx_queue_setup(uint16_t port_id, uint16_t tx_queue_id,
 		       tx_queue_id, nb_tx_desc, socket_id, &local_conf));
 }
 
-RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_eth_tx_hairpin_queue_setup, 19.11)
+RTE_EXPORT_SYMBOL(rte_eth_tx_hairpin_queue_setup)
 int
 rte_eth_tx_hairpin_queue_setup(uint16_t port_id, uint16_t tx_queue_id,
 			       uint16_t nb_tx_desc,
@@ -2824,7 +2824,7 @@ rte_eth_tx_hairpin_queue_setup(uint16_t port_id, uint16_t tx_queue_id,
 	return ret;
 }
 
-RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_eth_hairpin_bind, 20.11)
+RTE_EXPORT_SYMBOL(rte_eth_hairpin_bind)
 int
 rte_eth_hairpin_bind(uint16_t tx_port, uint16_t rx_port)
 {
@@ -2852,7 +2852,7 @@ rte_eth_hairpin_bind(uint16_t tx_port, uint16_t rx_port)
 	return ret;
 }
 
-RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_eth_hairpin_unbind, 20.11)
+RTE_EXPORT_SYMBOL(rte_eth_hairpin_unbind)
 int
 rte_eth_hairpin_unbind(uint16_t tx_port, uint16_t rx_port)
 {
@@ -2880,7 +2880,7 @@ rte_eth_hairpin_unbind(uint16_t tx_port, uint16_t rx_port)
 	return ret;
 }
 
-RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_eth_hairpin_get_peer_ports, 20.11)
+RTE_EXPORT_SYMBOL(rte_eth_hairpin_get_peer_ports)
 int
 rte_eth_hairpin_get_peer_ports(uint16_t port_id, uint16_t *peer_ports,
 			       size_t len, uint32_t direction)
@@ -7094,7 +7094,7 @@ rte_eth_dev_adjust_nb_rx_tx_desc(uint16_t port_id,
 	return 0;
 }
 
-RTE_EXPORT_EXPERIMENTAL_SYMBOL(rte_eth_dev_hairpin_capability_get, 19.11)
+RTE_EXPORT_SYMBOL(rte_eth_dev_hairpin_capability_get)
 int
 rte_eth_dev_hairpin_capability_get(uint16_t port_id,
 				   struct rte_eth_hairpin_cap *cap)
diff --git a/lib/ethdev/rte_ethdev.h b/lib/ethdev/rte_ethdev.h
index 7f0333cbd1..33ec81792d 100644
--- a/lib/ethdev/rte_ethdev.h
+++ b/lib/ethdev/rte_ethdev.h
@@ -1240,9 +1240,6 @@ struct rte_eth_txconf {
 };
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * A structure used to return the Tx or Rx hairpin queue capabilities.
  */
 struct rte_eth_hairpin_queue_cap {
@@ -1262,9 +1259,6 @@ struct rte_eth_hairpin_queue_cap {
 };
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * A structure used to return the hairpin capabilities that are supported.
  */
 struct rte_eth_hairpin_cap {
@@ -1282,9 +1276,6 @@ struct rte_eth_hairpin_cap {
 #define RTE_ETH_MAX_HAIRPIN_PEERS 32
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * A structure used to hold hairpin peer data.
  */
 struct rte_eth_hairpin_peer {
@@ -1293,9 +1284,6 @@ struct rte_eth_hairpin_peer {
 };
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * A structure used to configure hairpin binding.
  */
 struct rte_eth_hairpin_conf {
@@ -2531,9 +2519,6 @@ int rte_eth_rx_queue_setup(uint16_t port_id, uint16_t rx_queue_id,
 		struct rte_mempool *mb_pool);
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * Allocate and set up a hairpin receive queue for an Ethernet device.
  *
  * The function set up the selected queue to be used in hairpin.
@@ -2557,7 +2542,6 @@ int rte_eth_rx_queue_setup(uint16_t port_id, uint16_t rx_queue_id,
  *   - (-EINVAL) if bad parameter.
  *   - (-ENOMEM) if unable to allocate the resources.
  */
-__rte_experimental
 int rte_eth_rx_hairpin_queue_setup
 	(uint16_t port_id, uint16_t rx_queue_id, uint16_t nb_rx_desc,
 	 const struct rte_eth_hairpin_conf *conf);
@@ -2615,9 +2599,6 @@ int rte_eth_tx_queue_setup(uint16_t port_id, uint16_t tx_queue_id,
 		const struct rte_eth_txconf *tx_conf);
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * Allocate and set up a transmit hairpin queue for an Ethernet device.
  *
  * @param port_id
@@ -2639,15 +2620,11 @@ int rte_eth_tx_queue_setup(uint16_t port_id, uint16_t tx_queue_id,
  *   - (-EINVAL) if bad parameter.
  *   - (-ENOMEM) if unable to allocate the resources.
  */
-__rte_experimental
 int rte_eth_tx_hairpin_queue_setup
 	(uint16_t port_id, uint16_t tx_queue_id, uint16_t nb_tx_desc,
 	 const struct rte_eth_hairpin_conf *conf);
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * Get all the hairpin peer Rx / Tx ports of the current port.
  * The caller should ensure that the array is large enough to save the ports
  * list.
@@ -2670,14 +2647,10 @@ int rte_eth_tx_hairpin_queue_setup
  *   - (-ENOTSUP) if hardware doesn't support.
  *   - Others detailed errors from PMDs.
  */
-__rte_experimental
 int rte_eth_hairpin_get_peer_ports(uint16_t port_id, uint16_t *peer_ports,
 				   size_t len, uint32_t direction);
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * Bind all hairpin Tx queues of one port to the Rx queues of the peer port.
  * It is only allowed to call this function after all hairpin queues are
  * configured properly and the devices are in started state.
@@ -2696,13 +2669,9 @@ int rte_eth_hairpin_get_peer_ports(uint16_t port_id, uint16_t *peer_ports,
  *   - (-ENOTSUP) if hardware doesn't support.
  *   - Others detailed errors from PMDs.
  */
-__rte_experimental
 int rte_eth_hairpin_bind(uint16_t tx_port, uint16_t rx_port);
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * Unbind all hairpin Tx queues of one port from the Rx queues of the peer port.
  * This should be called before closing the Tx or Rx devices, if the bind
  * function is called before.
@@ -2723,7 +2692,6 @@ int rte_eth_hairpin_bind(uint16_t tx_port, uint16_t rx_port);
  *   - (-ENOTSUP) if hardware doesn't support.
  *   - Others detailed errors from PMDs.
  */
-__rte_experimental
 int rte_eth_hairpin_unbind(uint16_t tx_port, uint16_t rx_port);
 
 /**
@@ -5755,9 +5723,6 @@ void *
 rte_eth_dev_get_sec_ctx(uint16_t port_id);
 
 /**
- * @warning
- * @b EXPERIMENTAL: this API may change, or be removed, without prior notice
- *
  * Query the device hairpin capabilities.
  *
  * @param port_id
@@ -5769,7 +5734,6 @@ rte_eth_dev_get_sec_ctx(uint16_t port_id);
  *   - (-ENOTSUP) if hardware doesn't support.
  *   - (-EINVAL) if bad parameter.
  */
-__rte_experimental
 int rte_eth_dev_hairpin_capability_get(uint16_t port_id,
 				       struct rte_eth_hairpin_cap *cap);
 
-- 
2.53.0


  parent reply	other threads:[~2026-09-01 20:32 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-01 20:22 [PATCH 00/22] ethdev: convert experimental symbols etc Stephen Hemminger
2026-09-01 20:23 ` [PATCH 01/22] ethdev: promote meter API to stable Stephen Hemminger
2026-09-01 20:23 ` [PATCH 02/22] ethdev: promote module EEPROM " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 03/22] ethdev: promote rte_flow_conv " Stephen Hemminger
2026-09-01 20:23 ` Stephen Hemminger [this message]
2026-09-01 20:23 ` [PATCH 05/22] ethdev: promote read clock and flow dump " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 06/22] ethdev: promote FEC API " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 07/22] ethdev: promote link speed helpers " Stephen Hemminger
2026-09-02  8:05   ` Bruce Richardson
2026-09-01 20:23 ` [PATCH 08/22] ethdev: promote flow tunnel offload API " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 09/22] ethdev: promote aged flow query " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 10/22] ethdev: promote indirect action API " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 11/22] ethdev: promote asynchronous flow " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 12/22] ethdev: promote flex item " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 13/22] ethdev: promote remaining aged flow helpers " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 14/22] ethdev: promote congestion management API " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 15/22] ethdev: promote IP reassembly offload " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 16/22] ethdev: promote per-queue priority flow control " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 17/22] ethdev: promote device info and dump helpers " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 18/22] ethdev: promote speed lanes API " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 19/22] ethdev: promote queue helpers and aggregated ports " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 20/22] ethdev: promote remaining aged symbols " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 21/22] ethdev: promote fast path inline helpers " Stephen Hemminger
2026-09-01 20:23 ` [PATCH 22/22] ethdev: promote experimental structures " Stephen Hemminger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260901203217.1485915-5-stephen@networkplumber.org \
    --to=stephen@networkplumber.org \
    --cc=andrew.rybchenko@oktetlabs.ru \
    --cc=dev@dpdk.org \
    --cc=thomas@monjalon.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox