cvs commit: src/sys/kern uipc_mbuf.c uipc_mbuf2.c src/sys/sys mbuf.h

Florent Thoumie flz at xbsd.org
Wed Jul 21 03:50:01 PDT 2004


Alfred wrote :

 > alfred      2004-07-21 07:12:24 UTC
 >
 >   FreeBSD src repository
 >
 >   Modified files:
 >     sys/kern             uipc_mbuf.c uipc_mbuf2.c
 >     sys/sys              mbuf.h
 >   Log:
 >   Make sure we don't call mbuf allocation functions with mutexes held.
 >
 >   Discussed with: rwatson
 >
 >   Revision  Changes    Path
 >   1.134     +8 -0      src/sys/kern/uipc_mbuf.c
 >   1.26      +4 -0      src/sys/kern/uipc_mbuf2.c
 >   1.153     +16 -0     src/sys/sys/mbuf.h

This breaks my kernel compilation :

---
In file included from /usr/src/sys/dev/if_ndis/if_ndis.c:41:
@/sys/mbuf.h: In function `m_get':
@/sys/mbuf.h:341: warning: implicit declaration of function `WITNESS_WARN'
@/sys/mbuf.h:341: error: `WARN_GIANTOK' undeclared (first use in this function)
@/sys/mbuf.h:341: error: (Each undeclared identifier is reported only once
@/sys/mbuf.h:341: error: for each function it appears in.)
@/sys/mbuf.h:341: error: `WARN_SLEEPOK' undeclared (first use in this function)
@/sys/mbuf.h: In function `m_getclr':
@/sys/mbuf.h:356: error: `WARN_GIANTOK' undeclared (first use in this function)
@/sys/mbuf.h:356: error: `WARN_SLEEPOK' undeclared (first use in this function)
@/sys/mbuf.h: In function `m_gethdr':
@/sys/mbuf.h:372: error: `WARN_GIANTOK' undeclared (first use in this function)
@/sys/mbuf.h:372: error: `WARN_SLEEPOK' undeclared (first use in this function)
@/sys/mbuf.h: In function `m_getcl':
@/sys/mbuf.h:385: error: `WARN_GIANTOK' undeclared (first use in this function)
@/sys/mbuf.h:385: error: `WARN_SLEEPOK' undeclared (first use in this function)
@/sys/mbuf.h: In function `m_clget':
@/sys/mbuf.h:413: error: `WARN_GIANTOK' undeclared (first use in this function)
@/sys/mbuf.h:413: error: `WARN_SLEEPOK' undeclared (first use in this function)
*** Error code 1

Stop in /usr/src/sys/modules/if_ndis.
---

I suggest removing ths #ifdef WITNESS ... #endif around #include <sys/lock.h>,
since WITNESS_WARN must be defined in mbuf.h.

PS: Sorry Alfred for the first mail, I should have posted this here in first
place.


                                                      -- flz


More information about the cvs-all mailing list