38#if !defined(RTEMS_RFS_RTEMS_DEFINED)
39#define RTEMS_RFS_RTEMS_DEFINED
48#define RTEMS_RFS_RTEMS_ERROR 0
53#define RTEMS_RFS_RTEMS_TRACE 0
59#if !RTEMS_RFS_RTEMS_ERROR
60#define rtems_rfs_rtems_error(_m, _e) \
61 (((errno = (_e)) == 0) ? 0 : -1)
82#define RTEMS_RFS_RTEMS_DEBUG_ALL (0xffffffff)
83#define RTEMS_RFS_RTEMS_DEBUG_ERROR_MSGS (1 << 0)
84#define RTEMS_RFS_RTEMS_DEBUG_EVAL_PATH (1 << 1)
85#define RTEMS_RFS_RTEMS_DEBUG_EVAL_FOR_MAKE (1 << 2)
86#define RTEMS_RFS_RTEMS_DEBUG_EVAL_PERMS (1 << 3)
87#define RTEMS_RFS_RTEMS_DEBUG_MKNOD (1 << 4)
88#define RTEMS_RFS_RTEMS_DEBUG_RMNOD (1 << 5)
89#define RTEMS_RFS_RTEMS_DEBUG_LINK (1 << 6)
90#define RTEMS_RFS_RTEMS_DEBUG_UNLINK (1 << 7)
91#define RTEMS_RFS_RTEMS_DEBUG_CHOWN (1 << 8)
92#define RTEMS_RFS_RTEMS_DEBUG_READLINK (1 << 9)
93#define RTEMS_RFS_RTEMS_DEBUG_FCHMOD (1 << 10)
94#define RTEMS_RFS_RTEMS_DEBUG_STAT (1 << 11)
95#define RTEMS_RFS_RTEMS_DEBUG_RENAME (1 << 12)
96#define RTEMS_RFS_RTEMS_DEBUG_DIR_RMNOD (1 << 13)
97#define RTEMS_RFS_RTEMS_DEBUG_FILE_OPEN (1 << 14)
98#define RTEMS_RFS_RTEMS_DEBUG_FILE_CLOSE (1 << 15)
99#define RTEMS_RFS_RTEMS_DEBUG_FILE_READ (1 << 16)
100#define RTEMS_RFS_RTEMS_DEBUG_FILE_WRITE (1 << 17)
101#define RTEMS_RFS_RTEMS_DEBUG_FILE_LSEEK (1 << 18)
102#define RTEMS_RFS_RTEMS_DEBUG_FILE_FTRUNC (1 << 19)
114#if RTEMS_RFS_RTEMS_TRACE
117#define rtems_rfs_rtems_trace(_m) (0)
127#if RTEMS_RFS_RTEMS_TRACE
130#define rtems_rfs_rtems_trace_set_mask(_m)
140#if RTEMS_RFS_RTEMS_TRACE
143#define rtems_rfs_rtems_trace_clear_mask(_m)
149#if RTEMS_RFS_RTEMS_TRACE
150int rtems_rfs_rtems_trace_shell_command (
int argc,
char *argv[]);
175#define rtems_rfs_rtems_pathloc_dev(_loc) \
176 ((rtems_rfs_file_system*)((_loc)->mt_entry->fs_info))
184#define rtems_rfs_rtems_set_pathloc_ino(_loc, _ino) \
185 (_loc)->node_access = (void*)((intptr_t)(_ino))
193#define rtems_rfs_rtems_get_pathloc_ino(_loc) \
194 ((rtems_rfs_ino) (intptr_t)((_loc)->node_access))
202#define rtems_rfs_rtems_set_pathloc_doff(_loc, _doff) \
203 (_loc)->node_access_2 = (void*)((intptr_t)(_doff))
211#define rtems_rfs_rtems_get_pathloc_doff(_loc) \
212 ((uint32_t) (intptr_t)((_loc)->node_access_2))
220#define rtems_rfs_rtems_get_iop_ino(_iop) \
221 ((intptr_t)(_iop)->pathinfo.node_access)
229#define rtems_rfs_rtems_get_iop_file_handle(_iop) \
230 ((rtems_rfs_file_handle*)(_iop)->pathinfo.node_access_2)
238#define rtems_rfs_rtems_set_iop_file_handle(_iop, _fh) \
239 (_iop)->pathinfo.node_access_2 = (_fh)
247#define rtems_rfs_rtems_handlers(_h) \
248 &rtems_rfs_rtems_ ## _h ## _handlers
286 rtems_rfs_mutex_lock (&rtems->
access);
297 rtems_rfs_mutex_unlock (&rtems->
access);
LibIO Internal Interface.
int rtems_rfs_buffers_release(rtems_rfs_file_system *fs)
Definition: rtems-rfs-buffer.c:485
#define rtems_rfs_fs_user(_fs)
Definition: rtems-rfs-file-system.h:383
RTEMS File System Information Node.
uint32_t rtems_rfs_mutex
Definition: rtems-rfs-mutex.h:60
int rtems_rfs_rtems_fstat(const rtems_filesystem_location_info_t *pathloc, struct stat *buf)
Definition: rtems-rfs-rtems.c:433
const rtems_filesystem_file_handlers_r rtems_rfs_rtems_link_handlers
Definition: rtems-rfs-rtems.c:708
uint16_t rtems_rfs_rtems_imode(mode_t mode)
Definition: rtems-rfs-rtems-utils.c:73
#define rtems_rfs_rtems_trace_clear_mask(_m)
Definition: rtems-rfs-rtems.h:143
bool rtems_rfs_rtems_set_handlers(rtems_filesystem_location_info_t *pathloc, rtems_rfs_inode_handle *inode)
Definition: rtems-rfs-rtems-utils.c:51
#define rtems_rfs_rtems_error(_m, _e)
Definition: rtems-rfs-rtems.h:60
#define rtems_rfs_rtems_trace_set_mask(_m)
Definition: rtems-rfs-rtems.h:130
int rtems_rfs_rtems_rmnod(const rtems_filesystem_location_info_t *parent_pathloc, const rtems_filesystem_location_info_t *pathloc)
Definition: rtems-rfs-rtems.c:580
const rtems_filesystem_file_handlers_r rtems_rfs_rtems_dir_handlers
Definition: rtems-rfs-rtems-dir.c:174
#define rtems_rfs_rtems_trace(_m)
Definition: rtems-rfs-rtems.h:117
int rtems_rfs_rtems_fdatasync(rtems_libio_t *iop)
Definition: rtems-rfs-rtems.c:610
mode_t rtems_rfs_rtems_mode(int imode)
Definition: rtems-rfs-rtems-utils.c:82
File system node operations table.
Definition: libio.h:1021
Definition: rtems-rfs-file-system.h:135
Definition: rtems-rfs-inode.h:201
File system location.
Definition: fs.h:72
An open file data structure.
Definition: libio.h:1338
Definition: rtems-rfs-rtems.h:163
rtems_rfs_mutex access
Definition: rtems-rfs-rtems.h:167