diff options
author | rwatson <rwatson@FreeBSD.org> | 2008-01-19 14:32:44 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2008-01-19 14:32:44 +0000 |
commit | 735d73fd1d8db41f85bb6533c1f32cc5e954e2dd (patch) | |
tree | 3274d4cc51cc259406780499dd8f608f062958c7 /sys/fs/coda | |
parent | af893b7bf8101d630e9acbe337d1e4fb8a04e6f9 (diff) | |
download | FreeBSD-src-735d73fd1d8db41f85bb6533c1f32cc5e954e2dd.zip FreeBSD-src-735d73fd1d8db41f85bb6533c1f32cc5e954e2dd.tar.gz |
Don't declare functions as extern.
Move all extern variable definitions to associated .h files, move some
extern variable definitions between include files to place them more
appropriately.
MFC after: 3 days
Diffstat (limited to 'sys/fs/coda')
-rw-r--r-- | sys/fs/coda/cnode.h | 6 | ||||
-rw-r--r-- | sys/fs/coda/coda_namecache.h | 37 | ||||
-rw-r--r-- | sys/fs/coda/coda_psdev.c | 3 | ||||
-rw-r--r-- | sys/fs/coda/coda_vfsops.c | 3 |
4 files changed, 22 insertions, 27 deletions
diff --git a/sys/fs/coda/cnode.h b/sys/fs/coda/cnode.h index c747170..297d538 100644 --- a/sys/fs/coda/cnode.h +++ b/sys/fs/coda/cnode.h @@ -74,15 +74,9 @@ do { \ #define CODA_FREE(ptr, size) free((ptr), M_CODA) /* - * global cache state control - */ -extern int coda_nc_use; - -/* * Used to select debugging statements throughout the cfs code. */ extern int codadebug; -extern int coda_nc_debug; extern int coda_printf_delay; extern int coda_vnop_print_entry; extern int coda_psdev_print_entry; diff --git a/sys/fs/coda/coda_namecache.h b/sys/fs/coda/coda_namecache.h index 77f2cb1..41442f4 100644 --- a/sys/fs/coda/coda_namecache.h +++ b/sys/fs/coda/coda_namecache.h @@ -136,21 +136,28 @@ struct coda_hash { /* Start of Hash chain */ #define CODA_NC_DEBUG(N, STMT) { if (coda_nc_debug & (1 <<N)) { STMT } } /* Prototypes of functions exported within cfs */ -extern void coda_nc_init(void); -extern void coda_nc_enter(struct cnode *, const char *, int, struct ucred *, struct cnode *); -extern struct cnode *coda_nc_lookup(struct cnode *, const char *, int, struct ucred *); - -extern void coda_nc_zapParentfid(CodaFid *, enum dc_status); -extern void coda_nc_zapfid(CodaFid *, enum dc_status); -extern void coda_nc_zapvnode(CodaFid *, struct ucred *, enum dc_status); -extern void coda_nc_zapfile(struct cnode *, const char *, int); -extern void coda_nc_purge_user(uid_t, enum dc_status); -extern void coda_nc_flush(enum dc_status); - -extern void print_coda_nc(void); -extern void coda_nc_gather_stats(void); -extern int coda_nc_resize(int, int, enum dc_status); -extern void coda_nc_name(struct cnode *cp); +void coda_nc_init(void); +void coda_nc_enter(struct cnode *, const char *, int, struct ucred *, struct cnode *); +struct cnode *coda_nc_lookup(struct cnode *, const char *, int, struct ucred *); + +void coda_nc_zapParentfid(CodaFid *, enum dc_status); +void coda_nc_zapfid(CodaFid *, enum dc_status); +void coda_nc_zapvnode(CodaFid *, struct ucred *, enum dc_status); +void coda_nc_zapfile(struct cnode *, const char *, int); +void coda_nc_purge_user(uid_t, enum dc_status); +void coda_nc_flush(enum dc_status); + +void print_coda_nc(void); +void coda_nc_gather_stats(void); +int coda_nc_resize(int, int, enum dc_status); +void coda_nc_name(struct cnode *cp); + +/* + * Global variables tracking and controlling Coda namecache operation. + */ +extern int coda_nc_debug; /* Set to enable debugging printfs */ +extern int coda_nc_initialized; /* Set if cache has been initialized */ +extern int coda_nc_use; /* Indicate use of CODA Name Cache */ /* * Structure to contain statistics on the cache usage diff --git a/sys/fs/coda/coda_psdev.c b/sys/fs/coda/coda_psdev.c index 32123ec..0321bb1 100644 --- a/sys/fs/coda/coda_psdev.c +++ b/sys/fs/coda/coda_psdev.c @@ -51,9 +51,6 @@ #include <sys/cdefs.h> __FBSDID("$FreeBSD$"); - -extern int coda_nc_initialized; /* Set if cache has been initialized */ - #include <sys/param.h> #include <sys/systm.h> #include <sys/ioccom.h> diff --git a/sys/fs/coda/coda_vfsops.c b/sys/fs/coda/coda_vfsops.c index c0a7868..7e827ab 100644 --- a/sys/fs/coda/coda_vfsops.c +++ b/sys/fs/coda/coda_vfsops.c @@ -77,9 +77,6 @@ struct coda_op_stats coda_vfsopstats[CODA_VFSOPS_SIZE]; #define MARK_INT_FAIL(op) (coda_vfsopstats[op].unsat_intrn++) #define MARK_INT_GEN(op) (coda_vfsopstats[op].gen_intrn++) -extern int coda_nc_initialized; /* Set if cache has been initialized */ -extern int vc_nb_open(struct cdev *, int, int, struct thread *); - int coda_vfsopstats_init(void) { |