From: Anatoly Burakov Date: Wed, 28 May 2014 17:32:39 +0000 (+0100) Subject: ip_frag: remove unneeded check and macro X-Git-Tag: spdx-start~10718 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=5cb60f3eb3633e3886096c738198f77b268c2e63;p=dpdk.git ip_frag: remove unneeded check and macro Signed-off-by: Anatoly Burakov Acked-by: Thomas Monjalon --- diff --git a/lib/librte_ip_frag/rte_ipv4_fragmentation.c b/lib/librte_ip_frag/rte_ipv4_fragmentation.c index 46ed5837a8..6e5feb63d6 100644 --- a/lib/librte_ip_frag/rte_ipv4_fragmentation.c +++ b/lib/librte_ip_frag/rte_ipv4_fragmentation.c @@ -45,11 +45,6 @@ #include "rte_ip_frag.h" #include "ip_frag_common.h" -/* - * MAX number of fragments per packet allowed. - */ -#define IPV4_MAX_FRAGS_PER_PACKET 0x80 - /* Fragment Offset */ #define IPV4_HDR_DF_SHIFT 14 #define IPV4_HDR_MF_SHIFT 13 @@ -119,10 +114,6 @@ rte_ipv4_fragmentation(struct rte_mbuf *pkt_in, /* Fragment size should be a multiply of 8. */ RTE_IP_FRAG_ASSERT((frag_size & IPV4_HDR_FO_MASK) == 0); - /* Fragment size should be a multiply of 8. */ - RTE_IP_FRAG_ASSERT(IPV4_MAX_FRAGS_PER_PACKET * frag_size >= - (uint16_t)(pkt_in->pkt.pkt_len - sizeof(struct ipv4_hdr))); - in_hdr = (struct ipv4_hdr *) pkt_in->pkt.data; flag_offset = rte_cpu_to_be_16(in_hdr->fragment_offset);