From 36e7a51ea1dedf0fc860ff3106aee1db1ab3b1f5 Mon Sep 17 00:00:00 2001 From: phk Date: Sun, 12 Oct 1997 20:26:33 +0000 Subject: Last major round (Unless Bruce thinks of somthing :-) of malloc changes. Distribute all but the most fundamental malloc types. This time I also remembered the trick to making things static: Put "static" in front of them. A couple of finer points by: bde --- sys/miscfs/nullfs/null_vfsops.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'sys/miscfs/nullfs/null_vfsops.c') diff --git a/sys/miscfs/nullfs/null_vfsops.c b/sys/miscfs/nullfs/null_vfsops.c index ea5711f..29be50a 100644 --- a/sys/miscfs/nullfs/null_vfsops.c +++ b/sys/miscfs/nullfs/null_vfsops.c @@ -36,7 +36,7 @@ * @(#)null_vfsops.c 8.2 (Berkeley) 1/21/94 * * @(#)lofs_vfsops.c 1.2 (Berkeley) 6/18/92 - * $Id: null_vfsops.c,v 1.18 1997/08/02 14:32:05 bde Exp $ + * $Id: null_vfsops.c,v 1.19 1997/08/16 19:15:16 wollman Exp $ */ /* @@ -48,12 +48,14 @@ #include #include #include +#include #include #include #include -#include #include +static MALLOC_DEFINE(M_NULLFSMNT, "NULLFS mount", "NULLFS mount structure"); + static int nullfs_fhtovp __P((struct mount *mp, struct fid *fidp, struct sockaddr *nam, struct vnode **vpp, int *exflagsp, struct ucred **credanonp)); @@ -154,7 +156,7 @@ nullfs_mount(mp, path, data, ndp, p) } xmp = (struct null_mount *) malloc(sizeof(struct null_mount), - M_UFSMNT, M_WAITOK); /* XXX */ + M_NULLFSMNT, M_WAITOK); /* XXX */ /* * Save reference to underlying FS @@ -175,7 +177,7 @@ nullfs_mount(mp, path, data, ndp, p) */ if (error) { vrele(lowerrootvp); - free(xmp, M_UFSMNT); /* XXX */ + free(xmp, M_NULLFSMNT); /* XXX */ return (error); } @@ -268,7 +270,7 @@ nullfs_unmount(mp, mntflags, p) /* * Finally, throw away the null_mount structure */ - free(mp->mnt_data, M_UFSMNT); /* XXX */ + free(mp->mnt_data, M_NULLFSMNT); /* XXX */ mp->mnt_data = 0; return 0; } -- cgit v1.1