summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1996-05-01 02:16:17 +0000
committerbde <bde@FreeBSD.org>1996-05-01 02:16:17 +0000
commit82c1afdaa1e8eef12f3ed9b548daa1fcf118f4cd (patch)
tree8fd7c8a67d75ea7446d091d266aa8e716d49679a
parentb3ded284a077f0b9c8fb148958c083eb07762578 (diff)
downloadFreeBSD-src-82c1afdaa1e8eef12f3ed9b548daa1fcf118f4cd.zip
FreeBSD-src-82c1afdaa1e8eef12f3ed9b548daa1fcf118f4cd.tar.gz
Removed bogus _BEGIN_DECLS/_END_DECLS.
Removed unused struct tag declarations in cloned code. Added or cleaned up idempotency ifdefs.
-rw-r--r--sys/gnu/ext2fs/ext2_extern.h27
-rw-r--r--sys/gnu/fs/ext2fs/ext2_extern.h27
-rw-r--r--sys/sys/bio.h8
-rw-r--r--sys/sys/buf.h8
-rw-r--r--sys/sys/lockf.h10
-rw-r--r--sys/ufs/ffs/ffs_extern.h17
-rw-r--r--sys/ufs/lfs/lfs_extern.h13
-rw-r--r--sys/ufs/mfs/mfs_extern.h13
-rw-r--r--sys/ufs/ufs/quota.h26
9 files changed, 57 insertions, 92 deletions
diff --git a/sys/gnu/ext2fs/ext2_extern.h b/sys/gnu/ext2fs/ext2_extern.h
index 9b0ce98..f07b7b7 100644
--- a/sys/gnu/ext2fs/ext2_extern.h
+++ b/sys/gnu/ext2fs/ext2_extern.h
@@ -39,24 +39,15 @@
* @(#)ffs_extern.h 8.3 (Berkeley) 4/16/94
*/
-struct buf;
-struct fid;
-struct fs;
+#ifndef _SYS_GNU_EXT2FS_EXT2_EXTERN_H_
+#define _SYS_GNU_EXT2FS_EXT2_EXTERN_H_
+
+struct dinode;
+struct ext2_inode;
struct inode;
struct mount;
-struct nameidata;
-struct proc;
-struct statfs;
-struct timeval;
-struct ucred;
-struct uio;
struct vnode;
-struct mbuf;
-struct dinode;
-struct ext2_group_desc;
-struct ext2_inode;
-__BEGIN_DECLS
int ext2_alloc __P((struct inode *,
daddr_t, daddr_t, int, struct ucred *, daddr_t *));
int ext2_balloc __P((struct inode *,
@@ -105,16 +96,18 @@ void mark_buffer_dirty __P((struct buf *bh));
int bwrite(); /* FFS needs a bwrite routine. XXX */
#endif
-/* this macros allows some of the ufs code to distinguish between
- * an EXT2 and a non-ext2(FFS/LFS) vnode.
+/*
+ * This macro allows the ufs code to distinguish between an EXT2 and a
+ * non-ext2(FFS/LFS) vnode.
*/
#define IS_EXT2_VNODE(vp) (vp->v_mount->mnt_stat.f_type == MOUNT_EXT2FS)
#ifdef DIAGNOSTIC
void ext2_checkoverlap __P((struct buf *, struct inode *));
#endif
-__END_DECLS
extern vop_t **ext2_vnodeop_p;
extern vop_t **ext2_specop_p;
extern vop_t **ext2_fifoop_p;
+
+#endif /* !_SYS_GNU_EXT2FS_EXT2_EXTERN_H_ */
diff --git a/sys/gnu/fs/ext2fs/ext2_extern.h b/sys/gnu/fs/ext2fs/ext2_extern.h
index 9b0ce98..f07b7b7 100644
--- a/sys/gnu/fs/ext2fs/ext2_extern.h
+++ b/sys/gnu/fs/ext2fs/ext2_extern.h
@@ -39,24 +39,15 @@
* @(#)ffs_extern.h 8.3 (Berkeley) 4/16/94
*/
-struct buf;
-struct fid;
-struct fs;
+#ifndef _SYS_GNU_EXT2FS_EXT2_EXTERN_H_
+#define _SYS_GNU_EXT2FS_EXT2_EXTERN_H_
+
+struct dinode;
+struct ext2_inode;
struct inode;
struct mount;
-struct nameidata;
-struct proc;
-struct statfs;
-struct timeval;
-struct ucred;
-struct uio;
struct vnode;
-struct mbuf;
-struct dinode;
-struct ext2_group_desc;
-struct ext2_inode;
-__BEGIN_DECLS
int ext2_alloc __P((struct inode *,
daddr_t, daddr_t, int, struct ucred *, daddr_t *));
int ext2_balloc __P((struct inode *,
@@ -105,16 +96,18 @@ void mark_buffer_dirty __P((struct buf *bh));
int bwrite(); /* FFS needs a bwrite routine. XXX */
#endif
-/* this macros allows some of the ufs code to distinguish between
- * an EXT2 and a non-ext2(FFS/LFS) vnode.
+/*
+ * This macro allows the ufs code to distinguish between an EXT2 and a
+ * non-ext2(FFS/LFS) vnode.
*/
#define IS_EXT2_VNODE(vp) (vp->v_mount->mnt_stat.f_type == MOUNT_EXT2FS)
#ifdef DIAGNOSTIC
void ext2_checkoverlap __P((struct buf *, struct inode *));
#endif
-__END_DECLS
extern vop_t **ext2_vnodeop_p;
extern vop_t **ext2_specop_p;
extern vop_t **ext2_fifoop_p;
+
+#endif /* !_SYS_GNU_EXT2FS_EXT2_EXTERN_H_ */
diff --git a/sys/sys/bio.h b/sys/sys/bio.h
index cc1760a..f789b6f 100644
--- a/sys/sys/bio.h
+++ b/sys/sys/bio.h
@@ -36,11 +36,12 @@
* SUCH DAMAGE.
*
* @(#)buf.h 8.9 (Berkeley) 3/30/95
- * $Id: buf.h,v 1.29 1996/03/11 02:04:27 hsu Exp $
+ * $Id: buf.h,v 1.30 1996/04/07 22:12:25 phk Exp $
*/
#ifndef _SYS_BUF_H_
#define _SYS_BUF_H_
+
#include <sys/queue.h>
#define NOLIST ((struct buf *)0x87654321)
@@ -196,7 +197,6 @@ extern struct buf *swbuf; /* Swap I/O buffer headers. */
extern int nswbuf; /* Number of swap I/O buffer headers. */
extern TAILQ_HEAD(swqueue, buf) bswlist;
-__BEGIN_DECLS
void bufinit __P((void));
void bremfree __P((struct buf *));
int bread __P((struct vnode *, daddr_t, int,
@@ -244,6 +244,6 @@ void vm_bounce_alloc __P((struct buf *));
void vm_bounce_free __P((struct buf *));
vm_offset_t vm_bounce_kva_alloc __P((int));
void vm_bounce_kva_alloc_free __P((vm_offset_t, int));
-__END_DECLS
-#endif
+#endif /* KERNEL */
+
#endif /* !_SYS_BUF_H_ */
diff --git a/sys/sys/buf.h b/sys/sys/buf.h
index cc1760a..f789b6f 100644
--- a/sys/sys/buf.h
+++ b/sys/sys/buf.h
@@ -36,11 +36,12 @@
* SUCH DAMAGE.
*
* @(#)buf.h 8.9 (Berkeley) 3/30/95
- * $Id: buf.h,v 1.29 1996/03/11 02:04:27 hsu Exp $
+ * $Id: buf.h,v 1.30 1996/04/07 22:12:25 phk Exp $
*/
#ifndef _SYS_BUF_H_
#define _SYS_BUF_H_
+
#include <sys/queue.h>
#define NOLIST ((struct buf *)0x87654321)
@@ -196,7 +197,6 @@ extern struct buf *swbuf; /* Swap I/O buffer headers. */
extern int nswbuf; /* Number of swap I/O buffer headers. */
extern TAILQ_HEAD(swqueue, buf) bswlist;
-__BEGIN_DECLS
void bufinit __P((void));
void bremfree __P((struct buf *));
int bread __P((struct vnode *, daddr_t, int,
@@ -244,6 +244,6 @@ void vm_bounce_alloc __P((struct buf *));
void vm_bounce_free __P((struct buf *));
vm_offset_t vm_bounce_kva_alloc __P((int));
void vm_bounce_kva_alloc_free __P((vm_offset_t, int));
-__END_DECLS
-#endif
+#endif /* KERNEL */
+
#endif /* !_SYS_BUF_H_ */
diff --git a/sys/sys/lockf.h b/sys/sys/lockf.h
index fa3b0b8..65db7d0 100644
--- a/sys/sys/lockf.h
+++ b/sys/sys/lockf.h
@@ -34,11 +34,11 @@
* SUCH DAMAGE.
*
* @(#)lockf.h 8.1 (Berkeley) 6/11/93
- * $Id: lockf.h,v 1.2 1994/08/21 04:41:50 paul Exp $
+ * $Id: lockf.h,v 1.3 1995/12/14 08:32:32 phk Exp $
*/
#ifndef _SYS_LOCKF_H_
-#define _SYS_LOCKF_H_
+#define _SYS_LOCKF_H_
/*
* The lockf structure is a kernel structure which contains the information
@@ -60,17 +60,13 @@ struct lockf {
/* Maximum length of sleep chains to traverse to try and detect deadlock. */
#define MAXDEPTH 50
-__BEGIN_DECLS
int lf_advlock __P((struct vop_advlock_args *, struct lockf **, u_quad_t));
-__END_DECLS
#ifdef LOCKF_DEBUG
extern int lockf_debug;
-__BEGIN_DECLS
void lf_print __P((char *, struct lockf *));
void lf_printlist __P((char *, struct lockf *));
-__END_DECLS
#endif
-#endif
+#endif /* !_SYS_LOCKF_H_ */
diff --git a/sys/ufs/ffs/ffs_extern.h b/sys/ufs/ffs/ffs_extern.h
index 62ee2b5..8498e28 100644
--- a/sys/ufs/ffs/ffs_extern.h
+++ b/sys/ufs/ffs/ffs_extern.h
@@ -31,24 +31,20 @@
* SUCH DAMAGE.
*
* @(#)ffs_extern.h 8.3 (Berkeley) 4/16/94
- * $Id: ffs_extern.h,v 1.9 1995/12/17 21:09:30 phk Exp $
+ * $Id: ffs_extern.h,v 1.10 1996/02/25 20:12:36 bde Exp $
*/
-struct buf;
+#ifndef _UFS_FFS_EXTERN_H
+#define _UFS_FFS_EXTERN_H
+
struct fid;
struct fs;
struct inode;
+struct mbuf;
struct mount;
-struct nameidata;
-struct proc;
struct statfs;
-struct timeval;
-struct ucred;
-struct uio;
struct vnode;
-struct mbuf;
-__BEGIN_DECLS
int ffs_alloc __P((struct inode *,
daddr_t, daddr_t, int, struct ucred *, daddr_t *));
int ffs_balloc __P((struct inode *,
@@ -84,8 +80,9 @@ int ffs_vptofh __P((struct vnode *, struct fid *));
#ifdef DIAGNOSTIC
void ffs_checkoverlap __P((struct buf *, struct inode *));
#endif
-__END_DECLS
extern vop_t **ffs_vnodeop_p;
extern vop_t **ffs_specop_p;
extern vop_t **ffs_fifoop_p;
+
+#endif /* !_UFS_FFS_EXTERN_H */
diff --git a/sys/ufs/lfs/lfs_extern.h b/sys/ufs/lfs/lfs_extern.h
index ef8d9fd..0f106aa 100644
--- a/sys/ufs/lfs/lfs_extern.h
+++ b/sys/ufs/lfs/lfs_extern.h
@@ -31,23 +31,17 @@
* SUCH DAMAGE.
*
* @(#)lfs_extern.h 8.2 (Berkeley) 4/16/94
- * $Id: lfs_extern.h,v 1.10 1995/12/17 21:09:48 phk Exp $
+ * $Id: lfs_extern.h,v 1.11 1995/12/22 17:56:37 bde Exp $
*/
#ifndef _UFS_LFS_LFS_EXTERN_H_
#define _UFS_LFS_LFS_EXTERN_H_
#ifdef KERNEL
-struct fid;
+
+struct inode;
struct mount;
struct nameidata;
-struct proc;
-struct statfs;
-struct timeval;
-struct inode;
-struct uio;
-struct mbuf;
-
int lfs_balloc __P((struct vnode *, u_long, daddr_t, struct buf **));
int lfs_blkatoff __P((struct vop_blkatoff_args *));
@@ -85,6 +79,7 @@ extern vop_t **lfs_vnodeop_p;
extern vop_t **lfs_specop_p;
extern vop_t **lfs_fifoop_p;
#define LFS_FIFOOPS lfs_fifoop_p
+
#endif /* KERNEL */
__BEGIN_DECLS
diff --git a/sys/ufs/mfs/mfs_extern.h b/sys/ufs/mfs/mfs_extern.h
index 2464659..e64a59d 100644
--- a/sys/ufs/mfs/mfs_extern.h
+++ b/sys/ufs/mfs/mfs_extern.h
@@ -31,24 +31,17 @@
* SUCH DAMAGE.
*
* @(#)mfs_extern.h 8.1 (Berkeley) 6/11/93
- * $Id: mfs_extern.h,v 1.4 1995/08/28 09:19:13 julian Exp $
+ * $Id: mfs_extern.h,v 1.5 1995/12/17 21:09:58 phk Exp $
*/
#ifndef _UFS_MFS_MFS_EXTERN_H_
-#define _UFS_MFS_MFS_EXTERN_H_
+#define _UFS_MFS_MFS_EXTERN_H_
-struct buf;
struct mount;
-struct nameidata;
-struct proc;
-struct statfs;
-struct ucred;
struct vnode;
-__BEGIN_DECLS
void mfs_doio __P((struct buf *bp, caddr_t base));
int mfs_mountfs __P((struct vnode *, struct mount *, struct proc *));
int mfs_mountroot __P((void));
-__END_DECLS
-#endif
+#endif /* !_UFS_MFS_MFS_EXTERN_H_ */
diff --git a/sys/ufs/ufs/quota.h b/sys/ufs/ufs/quota.h
index b50e1f2..e703a68 100644
--- a/sys/ufs/ufs/quota.h
+++ b/sys/ufs/ufs/quota.h
@@ -34,11 +34,11 @@
* SUCH DAMAGE.
*
* @(#)quota.h 8.1 (Berkeley) 6/11/93
- * $Id: quota.h,v 1.4 1995/12/22 15:58:54 phk Exp $
+ * $Id: quota.h,v 1.5 1996/02/27 07:57:57 mpp Exp $
*/
-#ifndef _UFS_UFS_QUOTA_
-#define _UFS_UFS_QUOTA_
+#ifndef _UFS_UFS_QUOTA_H_
+#define _UFS_UFS_QUOTA_H_
/*
* Definitions for disk quotas imposed on the average user
@@ -168,17 +168,12 @@ struct dquot {
#define DQREF(dq) (dq)->dq_cnt++
#endif
-#include <sys/cdefs.h>
+#ifdef KERNEL
-struct dquot;
struct inode;
struct mount;
-struct proc;
-struct ucred;
-struct ufsmount;
struct vnode;
-#ifdef KERNEL
-__BEGIN_DECLS
+
int chkdq __P((struct inode *, long, struct ucred *, int));
int chkiq __P((struct inode *, long, struct ucred *, int));
void dqinit __P((void));
@@ -191,12 +186,15 @@ int quotaon __P((struct proc *, struct mount *, int, caddr_t));
int setquota __P((struct mount *, u_long, int, caddr_t));
int setuse __P((struct mount *, u_long, int, caddr_t));
int ufs_quotactl __P((struct mount *, int, uid_t, caddr_t, struct proc *));
-__END_DECLS
-#else /* KERNEL */
+
+#else /* !KERNEL */
+
+#include <sys/cdefs.h>
+
__BEGIN_DECLS
int quotactl __P((const char *, int, int, char *));
__END_DECLS
-#endif /* KERNEL */
+#endif /* KERNEL */
-#endif /* _QUOTA_ */
+#endif /* !_UFS_UFS_QUOTA_H_ */
OpenPOWER on IntegriCloud