Subversion Repositories shark

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
422 giacomo 1
#ifndef _AFFS_FS_H
2
#define _AFFS_FS_H
3
/*
4
 * The affs filesystem constants/structures
5
 */
6
 
7
#include <linux/types.h>
8
 
9
#include <linux/affs_fs_i.h>
10
#include <linux/affs_fs_sb.h>
11
 
12
#define AFFS_SUPER_MAGIC 0xadff
13
 
14
struct affs_date;
15
 
16
/* --- Prototypes ----------------------------------------------------------------------------- */
17
 
18
/* amigaffs.c */
19
 
20
extern int      affs_insert_hash(struct inode *inode, struct buffer_head *bh);
21
extern int      affs_remove_hash(struct inode *dir, struct buffer_head *rem_bh);
22
extern int      affs_remove_header(struct dentry *dentry);
23
extern u32      affs_checksum_block(struct super_block *sb, struct buffer_head *bh);
24
extern void     affs_fix_checksum(struct super_block *sb, struct buffer_head *bh);
25
extern void     secs_to_datestamp(time_t secs, struct affs_date *ds);
26
extern mode_t   prot_to_mode(u32 prot);
27
extern void     mode_to_prot(struct inode *inode);
28
extern void     affs_error(struct super_block *sb, const char *function, const char *fmt, ...);
29
extern void     affs_warning(struct super_block *sb, const char *function, const char *fmt, ...);
30
extern int      affs_check_name(const unsigned char *name, int len);
31
extern int      affs_copy_name(unsigned char *bstr, struct dentry *dentry);
32
 
33
/* bitmap. c */
34
 
35
extern u32      affs_count_free_bits(u32 blocksize, const void *data);
36
extern u32      affs_count_free_blocks(struct super_block *s);
37
extern void     affs_free_block(struct super_block *sb, u32 block);
38
extern u32      affs_alloc_block(struct inode *inode, u32 goal);
39
extern int      affs_init_bitmap(struct super_block *sb);
40
 
41
/* namei.c */
42
 
43
extern int      affs_hash_name(struct super_block *sb, const u8 *name, unsigned int len);
44
extern struct dentry *affs_lookup(struct inode *dir, struct dentry *dentry, struct nameidata *);
45
extern int      affs_unlink(struct inode *dir, struct dentry *dentry);
46
extern int      affs_create(struct inode *dir, struct dentry *dentry, int mode, struct nameidata *);
47
extern int      affs_mkdir(struct inode *dir, struct dentry *dentry, int mode);
48
extern int      affs_rmdir(struct inode *dir, struct dentry *dentry);
49
extern int      affs_link(struct dentry *olddentry, struct inode *dir,
50
                          struct dentry *dentry);
51
extern int      affs_symlink(struct inode *dir, struct dentry *dentry,
52
                             const char *symname);
53
extern int      affs_rename(struct inode *old_dir, struct dentry *old_dentry,
54
                            struct inode *new_dir, struct dentry *new_dentry);
55
 
56
/* inode.c */
57
 
58
extern unsigned long             affs_parent_ino(struct inode *dir);
59
extern struct inode             *affs_new_inode(struct inode *dir);
60
extern int                       affs_notify_change(struct dentry *dentry, struct iattr *attr);
61
extern void                      affs_put_inode(struct inode *inode);
62
extern void                      affs_delete_inode(struct inode *inode);
63
extern void                      affs_clear_inode(struct inode *inode);
64
extern void                      affs_read_inode(struct inode *inode);
65
extern void                      affs_write_inode(struct inode *inode, int);
66
extern int                       affs_add_entry(struct inode *dir, struct inode *inode, struct dentry *dentry, s32 type);
67
 
68
/* super.c */
69
 
70
extern int                       affs_fs(void);
71
 
72
/* file.c */
73
 
74
void            affs_free_prealloc(struct inode *inode);
75
extern void     affs_truncate(struct inode *);
76
 
77
/* dir.c */
78
 
79
extern void   affs_dir_truncate(struct inode *);
80
 
81
/* jump tables */
82
 
83
extern struct inode_operations   affs_file_inode_operations;
84
extern struct inode_operations   affs_dir_inode_operations;
85
extern struct inode_operations   affs_symlink_inode_operations;
86
extern struct file_operations    affs_file_operations;
87
extern struct file_operations    affs_file_operations_ofs;
88
extern struct file_operations    affs_dir_operations;
89
extern struct address_space_operations   affs_symlink_aops;
90
extern struct address_space_operations   affs_aops;
91
extern struct address_space_operations   affs_aops_ofs;
92
 
93
extern struct dentry_operations  affs_dentry_operations;
94
extern struct dentry_operations  affs_dentry_operations_intl;
95
 
96
#endif