extern.h revision 1.16 1 1.16 joerg /* $NetBSD: extern.h,v 1.16 2020/04/03 19:36:33 joerg Exp $ */
2 1.1 perseant
3 1.1 perseant /*
4 1.1 perseant * Copyright (c) 1994 James A. Jegers
5 1.1 perseant * All rights reserved.
6 1.1 perseant *
7 1.1 perseant * Redistribution and use in source and binary forms, with or without
8 1.1 perseant * modification, are permitted provided that the following conditions
9 1.1 perseant * are met:
10 1.1 perseant * 1. Redistributions of source code must retain the above copyright
11 1.1 perseant * notice, this list of conditions and the following disclaimer.
12 1.1 perseant * 2. The name of the author may not be used to endorse or promote products
13 1.1 perseant * derived from this software without specific prior written permission
14 1.1 perseant *
15 1.1 perseant * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16 1.1 perseant * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17 1.1 perseant * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18 1.1 perseant * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19 1.1 perseant * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 1.1 perseant * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 1.1 perseant * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 1.1 perseant * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 1.1 perseant * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 1.1 perseant * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 1.1 perseant */
26 1.1 perseant
27 1.16 joerg #include <stdarg.h>
28 1.16 joerg #include "vnode.h"
29 1.16 joerg
30 1.16 joerg struct inodesc;
31 1.16 joerg union lfs_dinode;
32 1.16 joerg struct inode;
33 1.16 joerg struct lfs;
34 1.16 joerg union lfs_dirheader;
35 1.16 joerg
36 1.4 perseant void adjust(struct inodesc *, short);
37 1.4 perseant int allocblk(long);
38 1.4 perseant int allocdir(ino_t, ino_t, int);
39 1.8 christos void blkerror(ino_t, const char *, daddr_t);
40 1.12 dholland void cacheino(union lfs_dinode *, ino_t);
41 1.8 christos int changeino(ino_t, const char *, ino_t);
42 1.16 joerg u_int32_t cksum(void *, size_t);
43 1.3 perseant struct fstab;
44 1.4 perseant void checkinode(ino_t, struct inodesc *);
45 1.4 perseant int chkrange(daddr_t, int);
46 1.4 perseant void ckfini(int);
47 1.12 dholland int ckinode(union lfs_dinode *, struct inodesc *);
48 1.8 christos void clri(struct inodesc *, const char *, int);
49 1.16 joerg int dircheck(struct inodesc *, union lfs_dirheader *);
50 1.8 christos void direrror(ino_t, const char *);
51 1.4 perseant int dirscan(struct inodesc *);
52 1.8 christos int dofix(struct inodesc *, const char *);
53 1.8 christos void fileerror(ino_t, ino_t, const char *);
54 1.4 perseant int findino(struct inodesc *);
55 1.4 perseant int findname(struct inodesc *);
56 1.4 perseant void freeblk(daddr_t, long);
57 1.4 perseant void freeino(ino_t);
58 1.4 perseant void freeinodebuf(void);
59 1.12 dholland int ftypeok(union lfs_dinode *);
60 1.6 itojun void getpathname(char *, size_t, ino_t, ino_t);
61 1.4 perseant void inocleanup(void);
62 1.4 perseant void inodirty(struct inode *);
63 1.4 perseant int linkup(ino_t, ino_t);
64 1.16 joerg u_int32_t lfs_sb_cksum(struct lfs *);
65 1.8 christos int makeentry(ino_t, ino_t, const char *);
66 1.4 perseant void pass0(void);
67 1.4 perseant void pass1(void);
68 1.4 perseant void pass1b(void);
69 1.4 perseant void pass2(void);
70 1.4 perseant void pass3(void);
71 1.4 perseant void pass4(void);
72 1.4 perseant int pass1check(struct inodesc *);
73 1.4 perseant int pass4check(struct inodesc *);
74 1.4 perseant void pass5(void);
75 1.4 perseant void pass6(void);
76 1.4 perseant int pass6check(struct inodesc *);
77 1.4 perseant void pinode(ino_t);
78 1.4 perseant void propagate(void);
79 1.16 joerg void pwarn(const char *, ...);
80 1.8 christos int reply(const char *);
81 1.4 perseant void resetinodebuf(void);
82 1.4 perseant int setup(const char *);
83 1.16 joerg
84 1.16 joerg extern struct uvnodelst vnodelist;
85 1.16 joerg extern struct uvnodelst getvnodelist[VNODE_HASH_MAX];
86 1.16 joerg extern int nvnodes;
87 1.16 joerg extern void (*panic_func)(int, const char *, va_list);
88 1.16 joerg extern int fake_cleanseg;
89 1.16 joerg extern off_t locked_queue_bytes;
90 1.16 joerg extern int locked_queue_count;
91 1.16 joerg extern int preen;
92 1.16 joerg extern time_t write_time;
93