Move the #define of _KERN_MUTEX_C_ so that it's before any system headers

are included.  System headers can include sys/mutex.h and then certain
macros do not get defined.

Reviewed by: jake
This commit is contained in:
Alfred Perlstein 2000-11-26 21:14:17 +00:00
parent a52585d77e
commit 0931dcefb3
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=69215
3 changed files with 18 additions and 3 deletions

View file

@ -53,6 +53,12 @@
#include "opt_ddb.h"
#include "opt_witness.h"
/*
* Cause non-inlined mtx_*() to be compiled.
* Must be defined early because other system headers may include mutex.h.
*/
#define _KERN_MUTEX_C_
#include <sys/param.h>
#include <sys/bus.h>
#include <sys/kernel.h>
@ -73,7 +79,6 @@
#include <vm/vm.h>
#include <vm/vm_extern.h>
#define _KERN_MUTEX_C_ /* Cause non-inlined mtx_*() to be compiled. */
#include <sys/mutex.h>
/*

View file

@ -53,6 +53,12 @@
#include "opt_ddb.h"
#include "opt_witness.h"
/*
* Cause non-inlined mtx_*() to be compiled.
* Must be defined early because other system headers may include mutex.h.
*/
#define _KERN_MUTEX_C_
#include <sys/param.h>
#include <sys/bus.h>
#include <sys/kernel.h>
@ -73,7 +79,6 @@
#include <vm/vm.h>
#include <vm/vm_extern.h>
#define _KERN_MUTEX_C_ /* Cause non-inlined mtx_*() to be compiled. */
#include <sys/mutex.h>
/*

View file

@ -53,6 +53,12 @@
#include "opt_ddb.h"
#include "opt_witness.h"
/*
* Cause non-inlined mtx_*() to be compiled.
* Must be defined early because other system headers may include mutex.h.
*/
#define _KERN_MUTEX_C_
#include <sys/param.h>
#include <sys/bus.h>
#include <sys/kernel.h>
@ -73,7 +79,6 @@
#include <vm/vm.h>
#include <vm/vm_extern.h>
#define _KERN_MUTEX_C_ /* Cause non-inlined mtx_*() to be compiled. */
#include <sys/mutex.h>
/*