PERFORCE change 126451 for review
Kip Macy
kmacy at FreeBSD.org
Sat Sep 15 14:08:55 PDT 2007
http://perforce.freebsd.org/chv.cgi?CH=126451
Change 126451 by kmacy at kmacy_home:ethng on 2007/09/15 21:08:33
add jumbo_phys_contig knob
pass ref to cljset
past zone to cljget
Affected files ...
.. //depot/projects/ethng/src/sys/sys/mbuf.h#4 edit
Differences ...
==== //depot/projects/ethng/src/sys/sys/mbuf.h#4 (text+ko) ====
@@ -351,7 +351,7 @@
static __inline struct mbuf *m_getclr(int how, short type); /* XXX */
static __inline struct mbuf *m_free(struct mbuf *m);
static __inline void m_clget(struct mbuf *m, int how);
-static __inline void *m_cljget(struct mbuf *m, int how, int size);
+static __inline void *m_cljget(struct mbuf *m, int how, uma_zone_t zone);
static __inline void m_chtype(struct mbuf *m, short new_type);
void mb_free_ext(struct mbuf *);
static __inline struct mbuf *m_last(struct mbuf *m);
@@ -530,21 +530,19 @@
* For size it takes MCLBYTES, MJUMPAGESIZE, MJUM9BYTES, MJUM16BYTES.
*/
static __inline void *
-m_cljget(struct mbuf *m, int how, int size)
+m_cljget(struct mbuf *m, int how, uma_zone_t zone)
{
- uma_zone_t zone;
if (m && m->m_flags & M_EXT)
printf("%s: %p mbuf already has cluster\n", __func__, m);
if (m != NULL)
m->m_ext.ext_buf = NULL;
- zone = m_getzone(size);
return (uma_zalloc_arg(zone, m, how));
}
static __inline void
-m_cljset(struct mbuf *m, void *cl, int type)
+m_cljset(struct mbuf *m, void *cl, int type, volatile uint32_t *ref)
{
uma_zone_t zone;
int size;
@@ -577,7 +575,7 @@
m->m_ext.ext_free = m->m_ext.ext_args = NULL;
m->m_ext.ext_size = size;
m->m_ext.ext_type = type;
- m->m_ext.ref_cnt = uma_find_refcnt(zone, cl);
+ m->m_ext.ref_cnt = ref;
m->m_flags |= M_EXT;
}
@@ -723,6 +721,7 @@
extern int max_protohdr; /* Largest protocol header */
extern struct mbstat mbstat; /* General mbuf stats/infos */
extern int nmbclusters; /* Maximum number of clusters */
+extern int jumbo_phys_contig;
struct uio;
More information about the p4-projects
mailing list