#define NR_VFS_CALLS 49 /* highest number from base plus one */
-/* Field names for the fstat(2) call. */
-#define VFS_FSTAT_FD m1_i1 /* int */
-#define VFS_FSTAT_BUF m1_p1 /* struct stat * */
-
/* Field names for the fcntl(2) call. */
#define VFS_FCNTL_FD m1_i1 /* int */
#define VFS_FCNTL_CMD m1_i2 /* int */
} mess_sigcalls;
_ASSERT_MSG_SIZE(mess_sigcalls);
+typedef struct {
+ int fd;
+ vir_bytes buf; /* struct stat * */
+
+ uint8_t padding[48];
+} mess_lc_vfs_fstat;
+_ASSERT_MSG_SIZE(mess_lc_vfs_fstat);
+
typedef struct {
int fd;
mess_fs_vfs_readsuper m_fs_vfs_readsuper;
mess_fs_vfs_readwrite m_fs_vfs_readwrite;
+ mess_lc_vfs_fstat m_lc_vfs_fstat;
mess_lc_vfs_fsync m_lc_vfs_fsync;
mess_lc_vfs_getvfsstat m_lc_vfs_getvfsstat;
mess_lc_vfs_ioctl m_lc_vfs_ioctl;
message m;
memset(&m, 0, sizeof(m));
- m.VFS_FSTAT_FD = fd;
- m.VFS_FSTAT_BUF = (char *) buffer;
+ m.m_lc_vfs_fstat.fd = fd;
+ m.m_lc_vfs_fstat.buf = (vir_bytes)buffer;
return _syscall(VFS_PROC_NR, VFS_FSTAT, &m);
}
int r, rfd;
vir_bytes statbuf;
- statbuf = (vir_bytes) job_m_in.VFS_FSTAT_BUF;
- rfd = job_m_in.VFS_FSTAT_FD;
+ statbuf = job_m_in.m_lc_vfs_fstat.buf;
+ rfd = job_m_in.m_lc_vfs_fstat.fd;
/* Is the file descriptor valid? */
if ((rfilp = get_filp(rfd, VNODE_READ)) == NULL) return(err_code);