diff mbox series

[v1,1/1] linux-gen: drop unused _odp_packet_cmp_data() function

Message ID 1506387607-31849-2-git-send-email-odpbot@yandex.ru
State Superseded
Headers show
Series [v1,1/1] linux-gen: drop unused _odp_packet_cmp_data() function | expand

Commit Message

Github ODP bot Sept. 26, 2017, 1 a.m. UTC
From: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org>


Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org>

---
/** Email created from pull request 195 (lumag:drop-cmp-data)
 ** https://github.com/Linaro/odp/pull/195
 ** Patch: https://github.com/Linaro/odp/pull/195.patch
 ** Base sha: f710dd9c76b8a7683f07574afdfc5896f8e4db7a
 ** Merge commit sha: 697c00828c8cb381ce85486e7027e6390912160f
 **/
 .../linux-generic/include/odp_packet_internal.h    |  3 ---
 platform/linux-generic/odp_packet.c                | 26 ----------------------
 2 files changed, 29 deletions(-)
diff mbox series

Patch

diff --git a/platform/linux-generic/include/odp_packet_internal.h b/platform/linux-generic/include/odp_packet_internal.h
index d76d7bf08..15cb53f41 100644
--- a/platform/linux-generic/include/odp_packet_internal.h
+++ b/platform/linux-generic/include/odp_packet_internal.h
@@ -321,9 +321,6 @@  int _odp_cls_parse(odp_packet_hdr_t *pkt_hdr, const uint8_t *parseptr);
 int _odp_packet_set_data(odp_packet_t pkt, uint32_t offset,
 			 uint8_t c, uint32_t len);
 
-int _odp_packet_cmp_data(odp_packet_t pkt, uint32_t offset,
-			 const void *s, uint32_t len);
-
 #ifdef __cplusplus
 }
 #endif
diff --git a/platform/linux-generic/odp_packet.c b/platform/linux-generic/odp_packet.c
index f4a0e0ec9..fff01ad9d 100644
--- a/platform/linux-generic/odp_packet.c
+++ b/platform/linux-generic/odp_packet.c
@@ -1642,32 +1642,6 @@  int _odp_packet_set_data(odp_packet_t pkt, uint32_t offset,
 	return 0;
 }
 
-int _odp_packet_cmp_data(odp_packet_t pkt, uint32_t offset,
-			 const void *s, uint32_t len)
-{
-	const uint8_t *ptr = s;
-	void *mapaddr;
-	uint32_t seglen = 0; /* GCC */
-	uint32_t cmplen;
-	int ret;
-	odp_packet_hdr_t *pkt_hdr = packet_hdr(pkt);
-
-	ODP_ASSERT(offset + len <= pkt_hdr->frame_len);
-
-	while (len > 0) {
-		mapaddr = packet_map(pkt_hdr, offset, &seglen, NULL);
-		cmplen = len > seglen ? seglen : len;
-		ret = memcmp(mapaddr, ptr, cmplen);
-		if (ret != 0)
-			return ret;
-		offset  += cmplen;
-		len     -= cmplen;
-		ptr     += cmplen;
-	}
-
-	return 0;
-}
-
 /*
  *
  * Debugging