Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 28 Feb 2007 22:20:49 +0000
From:      Bruce M Simpson <bms@incunabulum.net>
To:        net@FreeBSD.org
Subject:   Proposal: Add M_HASCL().
Message-ID:  <45E60041.1090607@incunabulum.net>

next in thread | raw e-mail | index | archive | help
Much network code needs to know if the mbuf it is looking at is using a 
cluster. I propose putting M_HASCL() in sys/mbuf.h. I realise this is a 
style change, however, it seems to be a very common idiom.

Places this macro is currently defined and used directly:
netinet/ip_mroute.c
netinet6/ip6_mroute.c
nfsclient/nfsm_subs.h
nfsserver/nfsm_subs.h

Places which use this idiom by another name:
if_ppp.c
ppp_tty.c

Places which use this idiom indirectly by its expansion:
 sys/mbuf.h
 sys/socketvar.h
 netinet/ip6.h
 dev/pdq
 Many device drivers and third party code.

Head on over to http://fxr.watson.org/fxr/ident?i=M_HASCL and have a look.

Feel free to not bikeshed about this. It became apparent that this is a 
common idiom (needing to know if an mbuf is using external storage for 
whatever reason).

Thoughts?

BMS



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?45E60041.1090607>