1 /* $NetBSD: extern.h,v 1.24 2008/08/30 10:46:16 bouyer Exp $ */
4 * Copyright (c) 1994 James A. Jegers
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions
10 * 1. Redistributions of source code must retain the above copyright
11 * notice, this list of conditions and the following disclaimer.
12 * 2. The name of the author may not be used to endorse or promote products
13 * derived from this software without specific prior written permission
15 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 void adjust(struct inodesc
*, int);
28 daddr_t
allocblk(long);
29 ino_t
allocdir(ino_t
, ino_t
, int);
30 ino_t
allocino(ino_t
, int);
31 void blkerror(ino_t
, const char *, daddr_t
);
32 int bread(int, char *, daddr_t
, long);
34 void bwrite(int, char *, daddr_t
, long);
35 void cacheino(union dinode
*, ino_t
);
38 int changeino(ino_t
, const char *, ino_t
);
39 int chkrange(daddr_t
, int);
41 int ckinode(union dinode
*, struct inodesc
*);
42 int clearentry(struct inodesc
*);
43 void clri(struct inodesc
*, const char *, int);
44 int cmpsblks(const struct fs
*, struct fs
*);
45 int cmpsblks42(const struct fs
*, struct fs
*);
46 int cmpsblks44(const struct fs
*, struct fs
*);
47 union dinode
* getnextinode(ino_t
);
48 void direrror(ino_t
, const char *);
49 int dirscan(struct inodesc
*);
50 int dofix(struct inodesc
*, const char *);
51 void fileerror(ino_t
, ino_t
, const char *);
52 int findino(struct inodesc
*);
53 int findname(struct inodesc
*);
54 void flush(int, struct bufarea
*);
55 void freeblk(daddr_t
, long);
57 void freeinodebuf(void);
58 int ftypeok(union dinode
*);
59 void getblk(struct bufarea
*, daddr_t
, long);
60 struct bufarea
*getdatablk(daddr_t
, long);
61 struct inoinfo
*getinoinfo(ino_t
);
62 union dinode
*ginode(ino_t
);
63 void getpathname(char *, size_t, ino_t
, ino_t
);
64 void infohandler(int sig
);
65 void inocleanup(void);
67 struct inostat
*inoinfo(ino_t
);
68 int linkup(ino_t
, ino_t
, char *);
69 int makeentry(ino_t
, ino_t
, const char *);
72 int pass1check(struct inodesc
*);
76 int pass4check(struct inodesc
*);
79 void propagate(ino_t
);
80 int reply(const char *);
81 void setinodebuf(ino_t
);
82 int setup(const char *, const char *);
85 int check_wapbl(void);
86 void replay_wapbl(void);
87 void cleanup_wapbl(void);
88 int read_wapbl(char *, long, daddr_t
);
89 int is_journal_inode(ino_t
);
91 void swap_cg(struct cg
*, struct cg
*);
92 void copyback_cg(struct bufarea
*);
93 void sb_oldfscompat_write(struct fs
*, struct fs
*);
94 void sb_oldfscompat_read(struct fs
*, struct fs
**);