Index: sys/sys/mutex.h =================================================================== RCS file: /home/ncvs/src/sys/sys/mutex.h,v retrieving revision 1.25 diff -u -r1.25 mutex.h --- sys/sys/mutex.h 2001/02/12 03:15:43 1.25 +++ sys/sys/mutex.h 2001/03/03 05:51:57 @@ -393,14 +393,21 @@ /* * The INVARIANTS-enabled mtx_assert() functionality. + * + * The constants need to be defined for INVARIANT_SUPPORT infrastructure + * support as _mtx_assert() itself uses them and the latter implies that + * _mtx_assert() must build. */ -#ifdef INVARIANTS +#ifdef INVARIANT_SUPPORT #define MA_OWNED 0x01 #define MA_NOTOWNED 0x02 #define MA_RECURSED 0x04 #define MA_NOTRECURSED 0x08 void _mtx_assert(struct mtx *m, int what, const char *file, int line); +#endif /* INVARIANT_SUPPORT */ + +#ifdef INVARIANTS #define mtx_assert(m, what) \ _mtx_assert((m), (what), __FILE__, __LINE__)