2011-11-14 12:53:05 +01:00
|
|
|
#ifndef PUFFS_PROTO_H
|
|
|
|
#define PUFFS_PROTO_H
|
|
|
|
|
2012-02-01 12:44:26 +01:00
|
|
|
struct puffs_usermount;
|
|
|
|
struct puffs_node;
|
|
|
|
|
2011-11-14 12:53:05 +01:00
|
|
|
/* Function prototypes. */
|
|
|
|
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_new_driver(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* inode.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_putnode(void);
|
|
|
|
void release_node(struct puffs_usermount *pu, struct puffs_node *pn );
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* device.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int dev_open(endpoint_t driver_e, dev_t dev, endpoint_t proc_e, int
|
|
|
|
flags);
|
|
|
|
void dev_close(endpoint_t driver_e, dev_t dev);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* link.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_ftrunc(void);
|
|
|
|
int fs_link(void);
|
|
|
|
int fs_rdlink(void);
|
|
|
|
int fs_rename(void);
|
|
|
|
int fs_unlink(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* misc.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_flush(void);
|
|
|
|
int fs_sync(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* mount.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_mountpoint(void);
|
|
|
|
int fs_readsuper(void);
|
|
|
|
int fs_unmount(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* open.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_create(void);
|
|
|
|
int fs_inhibread(void);
|
|
|
|
int fs_mkdir(void);
|
|
|
|
int fs_mknod(void);
|
|
|
|
int fs_slink(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* path.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_lookup(void);
|
|
|
|
struct puffs_node *advance(struct puffs_node *dirp, char string[NAME_MAX
|
|
|
|
+ 1], int chk_perm);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* protect.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_chmod(void);
|
|
|
|
int fs_chown(void);
|
|
|
|
int fs_getdents(void);
|
|
|
|
int forbidden(struct puffs_node *rip, mode_t access_desired);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* read.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_breadwrite(void);
|
|
|
|
int fs_readwrite(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* stadir.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_fstatfs(void);
|
|
|
|
int fs_stat(void);
|
|
|
|
int fs_statvfs(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* time.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int fs_utime(void);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
/* utility.c */
|
2012-03-24 16:16:34 +01:00
|
|
|
int no_sys(void);
|
|
|
|
void mfs_nul_f(const char *file, int line, char *str, unsigned int len,
|
|
|
|
unsigned int maxlen);
|
|
|
|
time_t clock_time(void);
|
|
|
|
int update_times(struct puffs_node *pn, int fl, time_t t);
|
|
|
|
void lpuffs_debug(const char *format, ...);
|
2011-11-14 12:53:05 +01:00
|
|
|
|
|
|
|
#endif /* PUFFS_PROTO_H */
|