4 #define get_block(d, n, t) lmfs_get_block(d, n, t)
5 #define put_block(n, t) lmfs_put_block(n, t)
7 /* Function prototypes. */
9 /* Structs used in prototypes must be declared as such first. */
17 void discard_preallocated_blocks(struct inode
*rip
);
18 block_t
alloc_block(struct inode
*rip
, block_t goal
);
19 void free_block(struct super_block
*sp
, bit_t bit
);
22 struct inode
*alloc_inode(struct inode
*parent
, mode_t bits
);
23 void free_inode(struct inode
*rip
);
26 void dup_inode(struct inode
*ip
);
27 struct inode
*find_inode(dev_t dev
, ino_t numb
);
29 void init_inode_cache(void);
30 struct inode
*get_inode(dev_t dev
, ino_t numb
);
31 void put_inode(struct inode
*rip
);
32 void update_times(struct inode
*rip
);
33 void rw_inode(struct inode
*rip
, int rw_flag
);
41 int truncate_inode(struct inode
*rip
, off_t len
);
46 int fs_new_driver(void);
49 int fs_mountpoint(void);
50 int fs_readsuper(void);
55 int fs_inhibread(void);
62 struct inode
*advance(struct inode
*dirp
, char string
[NAME_MAX
+ 1], int
64 int search_dir(struct inode
*ldir_ptr
, char string
[NAME_MAX
+ 1], ino_t
65 *numb
, int flag
, int check_permissions
, int ftype
);
70 int fs_getdents(void);
71 int forbidden(struct inode
*rip
, mode_t access_desired
);
72 int read_only(struct inode
*ip
);
75 int fs_breadwrite(void);
76 int fs_readwrite(void);
77 void read_ahead(void);
78 block_t
read_map(struct inode
*rip
, off_t pos
);
79 block_t
rd_indir(struct buf
*bp
, int index
);
87 unsigned int get_block_size(dev_t dev
);
88 struct super_block
*get_super(dev_t dev
);
89 int read_super(struct super_block
*sp
);
90 void write_super(struct super_block
*sp
);
91 struct group_desc
* get_group_desc(unsigned int bnum
);
97 time_t clock_time(void);
98 unsigned conv2(int norm
, int w
);
99 long conv4(int norm
, long x
);
100 void mfs_nul_f(char *file
, int line
, char *str
, unsigned int len
,
101 unsigned int maxlen
);
102 int min(unsigned int l
, unsigned int r
);
104 void sanitycheck(char *file
, int line
);
105 #define SANITYCHECK sanitycheck(__FILE__, __LINE__)
106 int ansi_strcmp(register const char* ansi_s
, register const char *s2
,
107 register size_t ansi_s_length
);
108 bit_t
setbit(bitchunk_t
*bitmap
, bit_t max_bits
, unsigned int word
);
109 bit_t
setbyte(bitchunk_t
*bitmap
, bit_t max_bits
);
110 int unsetbit(bitchunk_t
*bitmap
, bit_t bit
);
113 struct buf
*new_block(struct inode
*rip
, off_t position
);
114 void zero_block(struct buf
*bp
);
115 int write_map(struct inode
*, off_t
, block_t
, int);
117 #endif /* EXT2_PROTO_H */