mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 01:30:30 -04:00
Completed function declarations and/or added prototypes and/or #includes
to get the prototypes.
This commit is contained in:
parent
b667af1da9
commit
57a4e3fa8a
5 changed files with 29 additions and 17 deletions
|
|
@ -31,7 +31,7 @@
|
|||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)ffs_alloc.c 8.8 (Berkeley) 2/21/94
|
||||
* $Id: ffs_alloc.c,v 1.18 1995/11/14 09:40:04 phk Exp $
|
||||
* $Id: ffs_alloc.c,v 1.19 1995/11/19 19:55:26 dyson Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
|
|
@ -47,13 +47,16 @@
|
|||
|
||||
#include <ufs/ufs/quota.h>
|
||||
#include <ufs/ufs/inode.h>
|
||||
#include <ufs/ufs/ufs_extern.h> /* YF - needed for ufs_getlbns() */
|
||||
#include <ufs/ufs/ufs_extern.h>
|
||||
|
||||
#include <ufs/ffs/fs.h>
|
||||
#include <ufs/ffs/ffs_extern.h>
|
||||
|
||||
extern u_long nextgennumber;
|
||||
|
||||
typedef long allocfcn_t __P((struct inode *ip, int cg, daddr_t bpref,
|
||||
int size));
|
||||
|
||||
static daddr_t ffs_alloccg __P((struct inode *, int, daddr_t, int));
|
||||
static daddr_t ffs_alloccgblk __P((struct fs *, struct cg *, daddr_t));
|
||||
static daddr_t ffs_clusteralloc __P((struct inode *, int, daddr_t, int));
|
||||
|
|
@ -61,7 +64,7 @@ static ino_t ffs_dirpref __P((struct fs *));
|
|||
static daddr_t ffs_fragextend __P((struct inode *, int, long, int, int));
|
||||
static void ffs_fserr __P((struct fs *, u_int, char *));
|
||||
static u_long ffs_hashalloc
|
||||
__P((struct inode *, int, long, int, u_long (*)()));
|
||||
__P((struct inode *, int, long, int, allocfcn_t *));
|
||||
static ino_t ffs_nodealloccg __P((struct inode *, int, daddr_t, int));
|
||||
static daddr_t ffs_mapsearch __P((struct fs *, struct cg *, daddr_t, int));
|
||||
|
||||
|
|
@ -128,8 +131,7 @@ ffs_alloc(ip, lbn, bpref, size, cred, bnp)
|
|||
cg = ino_to_cg(fs, ip->i_number);
|
||||
else
|
||||
cg = dtog(fs, bpref);
|
||||
bno = (daddr_t)ffs_hashalloc(ip, cg, (long)bpref, size,
|
||||
(u_long (*)())ffs_alloccg);
|
||||
bno = (daddr_t)ffs_hashalloc(ip, cg, (long)bpref, size, ffs_alloccg);
|
||||
if (bno > 0) {
|
||||
ip->i_blocks += btodb(size);
|
||||
ip->i_flag |= IN_CHANGE | IN_UPDATE;
|
||||
|
|
@ -278,8 +280,7 @@ ffs_realloccg(ip, lbprev, bpref, osize, nsize, cred, bpp)
|
|||
panic("ffs_realloccg: bad optim");
|
||||
/* NOTREACHED */
|
||||
}
|
||||
bno = (daddr_t)ffs_hashalloc(ip, cg, (long)bpref, request,
|
||||
(u_long (*)())ffs_alloccg);
|
||||
bno = (daddr_t)ffs_hashalloc(ip, cg, (long)bpref, request, ffs_alloccg);
|
||||
if (bno > 0) {
|
||||
bp->b_blkno = fsbtodb(fs, bno);
|
||||
ffs_blkfree(ip, bprev, (long)osize);
|
||||
|
|
@ -413,7 +414,7 @@ ffs_reallocblks(ap)
|
|||
* Search the block map looking for an allocation of the desired size.
|
||||
*/
|
||||
if ((newblk = (daddr_t)ffs_hashalloc(ip, dtog(fs, pref), (long)pref,
|
||||
len, (u_long (*)())ffs_clusteralloc)) == 0)
|
||||
len, ffs_clusteralloc)) == 0)
|
||||
goto fail;
|
||||
/*
|
||||
* We have found a new contiguous block.
|
||||
|
|
@ -689,10 +690,10 @@ ffs_hashalloc(ip, cg, pref, size, allocator)
|
|||
int cg;
|
||||
long pref;
|
||||
int size; /* size for data blocks, mode for inodes */
|
||||
u_long (*allocator)();
|
||||
allocfcn_t *allocator;
|
||||
{
|
||||
register struct fs *fs;
|
||||
long result;
|
||||
long result; /* XXX why not same type as we return? */
|
||||
int i, icg = cg;
|
||||
|
||||
fs = ip->i_fs;
|
||||
|
|
@ -727,7 +728,7 @@ ffs_hashalloc(ip, cg, pref, size, allocator)
|
|||
if (cg == fs->fs_ncg)
|
||||
cg = 0;
|
||||
}
|
||||
return (NULL);
|
||||
return (0);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@
|
|||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)lfs_bio.c 8.4 (Berkeley) 12/30/93
|
||||
* $Id: lfs_bio.c,v 1.5 1994/10/10 01:04:49 phk Exp $
|
||||
* $Id: lfs_bio.c,v 1.6 1995/08/11 11:31:16 davidg Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
|
|
@ -50,6 +50,8 @@
|
|||
#include <ufs/lfs/lfs.h>
|
||||
#include <ufs/lfs/lfs_extern.h>
|
||||
|
||||
extern void lfs_flush __P((void));
|
||||
|
||||
/*
|
||||
* LFS block write function.
|
||||
*
|
||||
|
|
|
|||
|
|
@ -31,10 +31,15 @@
|
|||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)lfs_cksum.c 8.1 (Berkeley) 6/11/93
|
||||
* $Id: lfs_cksum.c,v 1.2 1994/08/02 07:54:32 davidg Exp $
|
||||
* $Id: lfs_cksum.c,v 1.3 1995/05/30 08:15:14 rgrimes Exp $
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/vnode.h>
|
||||
|
||||
#include <ufs/lfs/lfs.h>
|
||||
#include <ufs/lfs/lfs_extern.h>
|
||||
|
||||
/*
|
||||
* Simple, general purpose, fast checksum. Data must be short-aligned.
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@
|
|||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)lfs_segment.c 8.5 (Berkeley) 1/4/94
|
||||
* $Id: lfs_segment.c,v 1.13 1995/08/16 16:14:13 bde Exp $
|
||||
* $Id: lfs_segment.c,v 1.14 1995/09/04 00:21:01 dyson Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
|
|
@ -60,7 +60,9 @@
|
|||
#include <ufs/lfs/lfs.h>
|
||||
#include <ufs/lfs/lfs_extern.h>
|
||||
|
||||
extern int count_lock_queue __P((void));
|
||||
extern int count_lock_queue __P((void));
|
||||
extern caddr_t lfs_alloc_buffer __P((int size));
|
||||
extern void lfs_reclaim_buffers __P((void));
|
||||
|
||||
#define MAX_ACTIVE 10
|
||||
#define MAX_IO_BUFS 256
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@
|
|||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)mfs_vfsops.c 8.4 (Berkeley) 4/16/94
|
||||
* $Id: mfs_vfsops.c,v 1.15 1995/11/28 02:15:29 peter Exp $
|
||||
* $Id: mfs_vfsops.c,v 1.16 1995/11/28 03:15:58 peter Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
|
|
@ -62,6 +62,8 @@
|
|||
#include <ufs/mfs/mfsnode.h>
|
||||
#include <ufs/mfs/mfs_extern.h>
|
||||
|
||||
extern int mfs_initminiroot __P((caddr_t base));
|
||||
|
||||
caddr_t mfs_rootbase; /* address of mini-root in kernel virtual memory */
|
||||
u_long mfs_rootsize; /* size of mini-root in bytes */
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue