[v2,1/4] mbuf: mark old offload flag as deprecated

Message ID 20210429080438.15032-2-david.marchand@redhat.com (mailing list archive)
State Superseded, archived
Delegated to: Maxime Coquelin
Headers
Series Offload flags fixes |

Checks

Context Check Description
ci/checkpatch warning coding style issues

Commit Message

David Marchand April 29, 2021, 8:04 a.m. UTC
  PKT_RX_EIP_CKSUM_BAD has been declared deprecated but there was no
warning to applications still using it.
Fix this by marking as deprecated with the newly introduced
RTE_DEPRECATED.

Fixes: e8a419d6de4b ("mbuf: rename outer IP checksum macro")

Signed-off-by: David Marchand <david.marchand@redhat.com>
Reviewed-by: Flavio Leitner <fbl@sysclose.org>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
Changes since v1:
- updated commitlog following Olivier comment,

---
 lib/mbuf/rte_mbuf_core.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
  

Comments

Lance Richardson April 29, 2021, 12:14 p.m. UTC | #1
On Thu, Apr 29, 2021 at 4:05 AM David Marchand
<david.marchand@redhat.com> wrote:
>
> PKT_RX_EIP_CKSUM_BAD has been declared deprecated but there was no
> warning to applications still using it.
> Fix this by marking as deprecated with the newly introduced
> RTE_DEPRECATED.
>
> Fixes: e8a419d6de4b ("mbuf: rename outer IP checksum macro")
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> Reviewed-by: Flavio Leitner <fbl@sysclose.org>
> Acked-by: Olivier Matz <olivier.matz@6wind.com>
> ---
> Changes since v1:
> - updated commitlog following Olivier comment,
>
> ---
>  lib/mbuf/rte_mbuf_core.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/lib/mbuf/rte_mbuf_core.h b/lib/mbuf/rte_mbuf_core.h
> index c17dc95c51..bb38d7f581 100644
> --- a/lib/mbuf/rte_mbuf_core.h
> +++ b/lib/mbuf/rte_mbuf_core.h
> @@ -83,7 +83,8 @@ extern "C" {
>   * Deprecated.
>   * This flag has been renamed, use PKT_RX_OUTER_IP_CKSUM_BAD instead.
>   */
> -#define PKT_RX_EIP_CKSUM_BAD PKT_RX_OUTER_IP_CKSUM_BAD
> +#define PKT_RX_EIP_CKSUM_BAD \
> +       RTE_DEPRECATED(PKT_RX_EIP_CKSUM_BAD) PKT_RX_OUTER_IP_CKSUM_BAD
>
>  /**
>   * A vlan has been stripped by the hardware and its tci is saved in
> --
> 2.23.0
>
Acked-by: Lance Richardson <lance.richardson@broadcom.com>
  
Ajit Khaparde April 29, 2021, 4:45 p.m. UTC | #2
On Thu, Apr 29, 2021 at 1:05 AM David Marchand
<david.marchand@redhat.com> wrote:
>
> PKT_RX_EIP_CKSUM_BAD has been declared deprecated but there was no
> warning to applications still using it.
> Fix this by marking as deprecated with the newly introduced
> RTE_DEPRECATED.
>
> Fixes: e8a419d6de4b ("mbuf: rename outer IP checksum macro")
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> Reviewed-by: Flavio Leitner <fbl@sysclose.org>
> Acked-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>

> ---
> Changes since v1:
> - updated commitlog following Olivier comment,
>
> ---
>  lib/mbuf/rte_mbuf_core.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/lib/mbuf/rte_mbuf_core.h b/lib/mbuf/rte_mbuf_core.h
> index c17dc95c51..bb38d7f581 100644
> --- a/lib/mbuf/rte_mbuf_core.h
> +++ b/lib/mbuf/rte_mbuf_core.h
> @@ -83,7 +83,8 @@ extern "C" {
>   * Deprecated.
>   * This flag has been renamed, use PKT_RX_OUTER_IP_CKSUM_BAD instead.
>   */
> -#define PKT_RX_EIP_CKSUM_BAD PKT_RX_OUTER_IP_CKSUM_BAD
> +#define PKT_RX_EIP_CKSUM_BAD \
> +       RTE_DEPRECATED(PKT_RX_EIP_CKSUM_BAD) PKT_RX_OUTER_IP_CKSUM_BAD
>
>  /**
>   * A vlan has been stripped by the hardware and its tci is saved in
> --
> 2.23.0
>
  

Patch

diff --git a/lib/mbuf/rte_mbuf_core.h b/lib/mbuf/rte_mbuf_core.h
index c17dc95c51..bb38d7f581 100644
--- a/lib/mbuf/rte_mbuf_core.h
+++ b/lib/mbuf/rte_mbuf_core.h
@@ -83,7 +83,8 @@  extern "C" {
  * Deprecated.
  * This flag has been renamed, use PKT_RX_OUTER_IP_CKSUM_BAD instead.
  */
-#define PKT_RX_EIP_CKSUM_BAD PKT_RX_OUTER_IP_CKSUM_BAD
+#define PKT_RX_EIP_CKSUM_BAD \
+	RTE_DEPRECATED(PKT_RX_EIP_CKSUM_BAD) PKT_RX_OUTER_IP_CKSUM_BAD
 
 /**
  * A vlan has been stripped by the hardware and its tci is saved in