* Christopher Zimmermann <madro...@zakweb.de> [2009-10-24 14:57]:
> Yes, I read something about "mbuf cluster" is the comments. As I
> understand the manpages this means the mbufs are chained together using
> the m_hdr.mh_next pointer !? But as far as I understand the code in
> sis_newbuf() it uses the MH_dat.m_ext. Isn't this mutually exclusive?

never ever, i repeat, NEVER, use those fields directly. you only use
the M_ / m_ macros and functions.

if you want to hack in network land you have to understand mbufs.
shameless plug: my recent talk has a reasonable introduction.
http://bulabula.org/papers/2009/eurobsdcon-faster_packets/

the mbufs are chained using m_hdr.mh_nextpkt in your case. but as
said, DO NOT touch these fields.

M_EXT (set in flags) mbufs have external data storage, usually mbuf
clusters.
M_HDR (set in flags) mbufs carry a pkthdr structure after the mbuf
header.
these are NOT mutually exclusive, not at all, this is even the most
common case for many usage scenarios :)

-- 
Henning Brauer, h...@bsws.de, henn...@openbsd.org
BS Web Services, http://bsws.de
Full-Service ISP - Secure Hosting, Mail and DNS Services
Dedicated Servers, Rootservers, Application Hosting

Reply via email to