HomeFreeBSD

m_uiotombuf: write total memory length of the allocated chain in pkthdr

Description

m_uiotombuf: write total memory length of the allocated chain in pkthdr

Data allocated by m_uiotombuf() usually goes into a socket buffer.
We are interested in the length of useful data to be added to sb_acc,
as well as total memory used by mbufs. The later would be added to
sb_mbcnt. Calculating this value at allocation time allows to save
on extra traversal of the mbuf chain.

Reviewed by: markj
Differential revision: https://reviews.freebsd.org/D35301

Details