summaryrefslogtreecommitdiffstats
path: root/contrib/libc++/src/shared_mutex.cpp
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2015-01-14 23:44:00 +0000
committerrwatson <rwatson@FreeBSD.org>2015-01-14 23:44:00 +0000
commit08b6ceecbb05f0b7bd21e29feee1624747a5b172 (patch)
tree3701a56361039aa728c4e2940e9b9967b4527cd6 /contrib/libc++/src/shared_mutex.cpp
parent1ded1eb19ecae7ee6436ebbaf9522457330587f3 (diff)
downloadFreeBSD-src-08b6ceecbb05f0b7bd21e29feee1624747a5b172.zip
FreeBSD-src-08b6ceecbb05f0b7bd21e29feee1624747a5b172.tar.gz
In order to support ongoing work to implement variable-size mbufs, and
more generally make it easier to extend 'struct mbuf in the future', make a number of changes to the data structure: - As we anticipate embedding mbufs headers within variable-size regions of memory in the future, change the definitions of byte arrays embedded in mbufs to be of size [0] rather than [MLEN] and [MHLEN]. In fact, the cxgbe driver already uses 'struct mbuf' on the front of other storage sizes, but we would like the global mbuf allocator do be able to do this as well. - Fold 'struct m_hdr' into 'struct mbuf' itself, eliminating a set of macros that aliased 'mh_foo' field names to 'm_foo' names such as 'm_next'. These present a particular problem as we would like to add new mbuf-header fields -- e.g., 'm_size' -- that, if similarly named via macros, would introduce collisions with many other variable names in the kernel. - Rename 'struct m_ext' to 'struct struct_m_ext' so that we can add compile-time assertions without bumping into the still-extant 'm_ext' macro. - Remove the MSIZE compile-time assertion for 'struct mbuf', but add new assertions for alignment of embedded data arrays (64-bit alignment even on 32-bit platforms), and for the sizes the mbuf header, packet header, and m_ext structure. - Document that these assertions exist in comments in mbuf.h. This change is not intended to cause (non-trivial) behavioural differences, but is a precursor to further mbuf-allocator work. Differential Revision: https://reviews.freebsd.org/D1483 Reviewed by: bz, gnn, np, glebius ("go ahead, I trust you") Sponsored by: EMC / Isilon Storage Division
Diffstat (limited to 'contrib/libc++/src/shared_mutex.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud