/****************************************************************************** 版权所有: 文件名称: rt_file.h 文件版本: 01.01 创建作者: sunxi 创建日期: 2020-06-18 功能说明: 实时微系统文件系统接口 其它说明: 修改记录: */ #ifndef _RT_FILE_H #define _RT_FILE_H /*------------------------------- 头文件 -------------------------------------- */ #include "rt.h" /*------------------------------- 宏定义 -------------------------------------- */ #define IS_ERR(x) (((int)x < 0) ? 1 : 0) #define UMH_WAIT_PROC 0 #define UMH_NO_WAIT 1 /*------------------------------ 类型结构 ------------------------------------- */ /*------------------------------ 函数声明 ------------------------------------- */ int rt_file_open(const char *filename, int flags, int mode); int rt_file_close(int fd, int id); int rt_file_llseek(int fd, long offset, int origin); int rt_file_read(int fd, char *buf, size_t count, off_t *pos); int rt_file_write(int fd, const char *buf, size_t count, off_t *pos); int rt_file_getfile_size(int fd); int rt_file_cp(char *src,char *dst); int rt_file_mv(char *src,char *dst); int rt_file_del(char *pathname); int rt_file_mkdir(char *dir); int rt_file_ln(char *src, char *dst); int rt_rootfs_version(char *pathname); int rt_kernel_version(char *pathname); int rt_printenv_version(char *pathname); int rt_rootfs_version1(char *pathname,char *pathname1,char *pathname2); int call_usermodehelper(char *cmd, char *cmd_and_argv[], char *envp[], int flag); #endif //_RT_FILE_H /*------------------------------ 文件结束 ------------------------------------- */