Hide struct resource and struct rman. You must define

__RMAN_RESOURCE_VISIBLE to see inside these now.

Reviewed by: dfr, njl (not njr)
This commit is contained in:
Warner Losh 2004-06-30 16:54:10 +00:00
parent 0d055a20bf
commit 0363a12688
5 changed files with 10 additions and 0 deletions

View File

@ -29,6 +29,7 @@
* $FreeBSD$
*/
#define __RMAN_RESOURCE_VISIBLE
#include "opt_acpi.h"
#include <sys/param.h>
#include <sys/kernel.h>

View File

@ -43,6 +43,7 @@ __FBSDID("$FreeBSD$");
#include "opt_isa.h"
#define __RMAN_RESOURCE_VISIBLE
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/bus.h>

View File

@ -29,6 +29,7 @@ __FBSDID("$FreeBSD$");
#include "opt_bus.h"
#define __RMAN_RESOURCE_VISIBLE
#include <sys/param.h>
#include <sys/conf.h>
#include <sys/filio.h>

View File

@ -58,6 +58,7 @@
#include <sys/cdefs.h>
__FBSDID("$FreeBSD$");
#define __RMAN_RESOURCE_VISIBLE
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>

View File

@ -93,6 +93,7 @@ struct u_rman {
* at some point in the future, particularly if we want to support 36-bit
* addresses on IA32 hardware.
*/
#ifdef __RMAN_RESOURCE_VISIBLE
TAILQ_HEAD(resource_head, resource);
struct resource {
TAILQ_ENTRY(resource) r_link;
@ -119,6 +120,11 @@ struct rman {
const char *rm_descr; /* text descripion of this resource */
};
TAILQ_HEAD(rman_head, rman);
#else
struct resource;
struct rman;
struct device;
#endif
int rman_activate_resource(struct resource *r);
int rman_await_resource(struct resource *r, int pri, int timo);