[dpdk-dev] mbuf changes

Morten Brørup mb at smartsharesystems.com
Tue Oct 25 15:18:20 CEST 2016


I support that!

Med venlig hilsen / kind regards
- Morten Brørup


> -----Original Message-----
> From: Olivier Matz [mailto:olivier.matz at 6wind.com]
> Sent: Tuesday, October 25, 2016 3:14 PM
> To: Morten Brørup; dev at dpdk.org
> Subject: Re: mbuf changes
> 
> Hi,
> 
> On 10/24/2016 05:49 PM, Morten Brørup wrote:
> > And here’s something new to think about:
> >
> > m->next already reveals if there are more segments to a packet. Which
> > purpose does m->nb_segs serve that is not already covered by m->next?
> >
> 
> I was asking myself the same question some time ago:
> http://dpdk.org/ml/archives/dev/2016-May/039483.html
> 
> But it seems nb_segs is useful for PMDs on TX side, to anticipate how
> many descriptors a packet will use in the TX ring. It can also help a
> PMD to check that this packet is supported by the hardware (too many
> segments) without browsing the list.
> 
> So finally I think it should be kept in the mbuf. But as suggested by
> Bruce, it could go in the second cache line, since m->next is also
> there, at the condition that this field is set to 1 in mbuf_free().
> 
> Regards,
> Olivier



More information about the dev mailing list