Add a constant PR_MAXMETHOD to better define the jail/OSD interface.

Reviewed by:	dchagin, kib
Approved by:	bz (mentor)
This commit is contained in:
Jamie Gritton 2009-05-05 05:49:08 +00:00
parent 614dd4f83c
commit 49939083a0
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=191806
2 changed files with 3 additions and 1 deletions

View File

@ -32,6 +32,7 @@ __FBSDID("$FreeBSD$");
#include <sys/systm.h>
#include <sys/sysctl.h>
#include <sys/errno.h>
#include <sys/jail.h>
#include <sys/malloc.h>
#include <sys/lock.h>
#include <sys/mutex.h>
@ -73,7 +74,7 @@ static osd_method_t *osd_methods[OSD_LAST + 1]; /* (m) */
static u_int osd_nslots[OSD_LAST + 1]; /* (m) */
static osd_destructor_t *osd_destructors[OSD_LAST + 1]; /* (o) */
static const u_int osd_nmethods[OSD_LAST + 1] = {
[OSD_JAIL] = 5,
[OSD_JAIL] = PR_MAXMETHOD,
};
static struct sx osd_module_lock[OSD_LAST + 1];

View File

@ -189,6 +189,7 @@ struct prison {
#define PR_METHOD_SET 2
#define PR_METHOD_CHECK 3
#define PR_METHOD_ATTACH 4
#define PR_MAXMETHOD 5
/*
* Sysctl-set variables that determine global jail policy