ip_frag: fix some debug logs
authorLi Han <han.li1@zte.com.cn>
Wed, 18 Apr 2018 08:51:37 +0000 (04:51 -0400)
committerThomas Monjalon <thomas@monjalon.net>
Mon, 14 May 2018 19:14:49 +0000 (21:14 +0200)
In ip_frag_process, some IP_FRAG_LOG content is wrong.

Fixes: 4f1a8f633862 ("ip_frag: add IPv6 reassembly")
Cc: stable@dpdk.org
Signed-off-by: Li Han <han.li1@zte.com.cn>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
lib/librte_ip_frag/ip_frag_internal.c

index 7397aa6..2560c77 100644 (file)
@@ -152,7 +152,7 @@ ip_frag_process(struct ip_frag_pkt *fp, struct rte_ip_frag_death_row *dr,
                                fp->frags[IP_LAST_FRAG_IDX].len);
                else
                        IP_FRAG_LOG(DEBUG, "%s:%d invalid fragmented packet:\n"
-                               "ipv4_frag_pkt: %p, key: <" IPv6_KEY_BYTES_FMT ", %#x>, "
+                               "ipv6_frag_pkt: %p, key: <" IPv6_KEY_BYTES_FMT ", %#x>, "
                                "total_size: %u, frag_size: %u, last_idx: %u\n"
                                "first fragment: ofs: %u, len: %u\n"
                                "last fragment: ofs: %u, len: %u\n\n",
@@ -210,7 +210,7 @@ ip_frag_process(struct ip_frag_pkt *fp, struct rte_ip_frag_death_row *dr,
                                fp->frags[IP_LAST_FRAG_IDX].len);
                else
                        IP_FRAG_LOG(DEBUG, "%s:%d invalid fragmented packet:\n"
-                               "ipv4_frag_pkt: %p, key: <" IPv6_KEY_BYTES_FMT ", %#x>, "
+                               "ipv6_frag_pkt: %p, key: <" IPv6_KEY_BYTES_FMT ", %#x>, "
                                "total_size: %u, frag_size: %u, last_idx: %u\n"
                                "first fragment: ofs: %u, len: %u\n"
                                "last fragment: ofs: %u, len: %u\n\n",
@@ -331,7 +331,7 @@ ip_frag_lookup(struct rte_ip_frag_tbl *tbl,
                if (p1->key.key_len == IPV4_KEYLEN)
                        IP_FRAG_LOG(DEBUG, "%s:%d:\n"
                                        "tbl: %p, max_entries: %u, use_entries: %u\n"
-                                       "ipv6_frag_pkt line0: %p, index: %u from %u\n"
+                                       "ipv4_frag_pkt line0: %p, index: %u from %u\n"
                        "key: <%" PRIx64 ", %#x>, start: %" PRIu64 "\n",
                                        __func__, __LINE__,
                                        tbl, tbl->max_entries, tbl->use_entries,
@@ -357,7 +357,7 @@ ip_frag_lookup(struct rte_ip_frag_tbl *tbl,
                if (p2->key.key_len == IPV4_KEYLEN)
                        IP_FRAG_LOG(DEBUG, "%s:%d:\n"
                                        "tbl: %p, max_entries: %u, use_entries: %u\n"
-                                       "ipv6_frag_pkt line1: %p, index: %u from %u\n"
+                                       "ipv4_frag_pkt line1: %p, index: %u from %u\n"
                        "key: <%" PRIx64 ", %#x>, start: %" PRIu64 "\n",
                                        __func__, __LINE__,
                                        tbl, tbl->max_entries, tbl->use_entries,