diff options
author | zec <zec@FreeBSD.org> | 2009-05-08 14:11:06 +0000 |
---|---|---|
committer | zec <zec@FreeBSD.org> | 2009-05-08 14:11:06 +0000 |
commit | 639797b2e609797fdaf2c8e88b9203bfc7c70b7e (patch) | |
tree | 070fe9c96176ed914dfefc12a45fea29b98c4122 /sys/nlm | |
parent | f851007175f37de5aec0c77eb852e3444150e653 (diff) | |
download | FreeBSD-src-639797b2e609797fdaf2c8e88b9203bfc7c70b7e.zip FreeBSD-src-639797b2e609797fdaf2c8e88b9203bfc7c70b7e.tar.gz |
Introduce a new virtualization container, provisionally named vprocg, to hold
virtualized instances of hostname and domainname, as well as a new top-level
virtualization struct vimage, which holds pointers to struct vnet and struct
vprocg. Struct vprocg is likely to become replaced in the near future with
a new jail management API import.
As a consequence of this change, change struct ucred to point to a struct
vimage, instead of directly pointing to a vnet.
Merge vnet / vimage / ucred refcounting infrastructure from p4 / vimage
branch.
Permit kldload / kldunload operations to be executed only from the default
vimage context.
This change should have no functional impact on nooptions VIMAGE kernel
builds.
Reviewed by: bz
Approved by: julian (mentor)
Diffstat (limited to 'sys/nlm')
-rw-r--r-- | sys/nlm/nlm_advlock.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/nlm/nlm_advlock.c b/sys/nlm/nlm_advlock.c index 2c1f1a6..a2c62f0 100644 --- a/sys/nlm/nlm_advlock.c +++ b/sys/nlm/nlm_advlock.c @@ -41,6 +41,7 @@ __FBSDID("$FreeBSD$"); #include <sys/syslog.h> #include <sys/systm.h> #include <sys/unistd.h> +#include <sys/vimage.h> #include <sys/vnode.h> #include <rpc/rpcclnt.h> @@ -1222,12 +1223,12 @@ nlm_init_lock(struct flock *fl, int flags, int svid, } mtx_lock(&hostname_mtx); - snprintf(oh_space, 32, "%d@%s", svid, hostname); + snprintf(oh_space, 32, "%d@%s", svid, G_hostname); mtx_unlock(&hostname_mtx); oh_len = strlen(oh_space); memset(lock, 0, sizeof(*lock)); - lock->caller_name = hostname; + lock->caller_name = G_hostname; lock->fh.n_len = fhlen; lock->fh.n_bytes = fh; lock->oh.n_len = oh_len; |