64 #ifndef CFS_CONF_OFFSET_TYPE 65 typedef int cfs_offset_t;
67 typedef CFS_CONF_OFFSET_TYPE cfs_offset_t;
129 #define CFS_SEEK_SET 0 138 #define CFS_SEEK_CUR 1 147 #define CFS_SEEK_END 2 169 int cfs_open(
const char *name,
int flags);
195 int cfs_read(
int fd,
void *buf,
unsigned int len);
210 int cfs_write(
int fd,
const void *buf,
unsigned int len);
231 cfs_offset_t
cfs_seek(
int fd, cfs_offset_t offset,
int whence);
254 int cfs_opendir(
struct cfs_dir *dirp,
const char *name);
268 int cfs_readdir(
struct cfs_dir *dirp,
struct cfs_dirent *dirent);
int cfs_open(const char *name, int flags)
Open a file.
int cfs_remove(const char *name)
Remove a file.
cfs_offset_t cfs_seek(int fd, cfs_offset_t offset, int whence)
Seek to a specified position in an open file.
int cfs_write(int fd, const void *buf, unsigned int len)
Write data to an open file.
int cfs_opendir(struct cfs_dir *dirp, const char *name)
Open a directory for reading directory entries.
void cfs_close(int fd)
Close an open file.
int cfs_readdir(struct cfs_dir *dirp, struct cfs_dirent *dirent)
Read a directory entry.
int cfs_read(int fd, void *buf, unsigned int len)
Read data from an open file.
void cfs_closedir(struct cfs_dir *dirp)
Close a directory opened with cfs_opendir().