Re: [PATCH] ip_frag: extend rte_ipv6_frag_get_ipv6_fragment_header()
From: Ananyev, Konstantin <hidden>
Date: 2018-07-17 13:54:39
From: Ananyev, Konstantin <hidden>
Date: 2018-07-17 13:54:39
Hi Cody,
Hi,quoted
Just a generic thought - might be worse to move functions that parse ipv6 header extentions and related strcutures into rte_net. I am sure they might be reused by some other code.Sorry, I am misunderstanding. Do you mean it might be better to move struct ipv6_opt_hdr and ipv6_ext_hdr() into rte_net since they are not fragmentation specific? That seems fine to me.
Yes, that's was my thought.
quoted
pktmbuf_read() is quite heavy-weight one. Do we really need it here? From my perspective - add an assumption that all whole IPv6 header will be inside one segment seems reasonable enough.It is my understanding that rte_pktmbuf_read() will almost always just invoke a light weight rte_pktmbuf_mtod_offset(). It only runs the heavy weight __rte_pktmbuf_read() in the case that the assumption you mentioned is broken.
Ah, yes you right. Konstantin