#define NR_VFS_CALLS 49 /* highest number from base plus one */
-/* Field names for the creat(2) call. */
-#define VFS_CREAT_NAME m1_p1 /* const char * */
-#define VFS_CREAT_LEN m1_i1 /* size_t */
-#define VFS_CREAT_FLAGS m1_i2 /* int */
-#define VFS_CREAT_MODE m1_i3 /* mode_t */
-
/* Field names for the chown(2) and fchown(2) calls. */
#define VFS_CHOWN_NAME m1_p1 /* const char * */
#define VFS_CHOWN_LEN m1_i1 /* size_t */
} mess_sigcalls;
_ASSERT_MSG_SIZE(mess_sigcalls);
+typedef struct {
+ vir_bytes name;
+ size_t len;
+ int flags;
+ mode_t mode;
+
+ uint8_t padding[40];
+} mess_lc_vfs_creat;
+_ASSERT_MSG_SIZE(mess_lc_vfs_creat);
+
typedef struct {
int fd;
int cmd;
mess_fs_vfs_readsuper m_fs_vfs_readsuper;
mess_fs_vfs_readwrite m_fs_vfs_readwrite;
+ mess_lc_vfs_creat m_lc_vfs_creat;
mess_lc_vfs_fcntl m_lc_vfs_fcntl;
mess_lc_vfs_fstat m_lc_vfs_fstat;
mess_lc_vfs_fsync m_lc_vfs_fsync;
* and therefore a different call number as well.
*/
if (flags & O_CREAT) {
- m.VFS_CREAT_LEN = strlen(name) + 1;
- m.VFS_CREAT_FLAGS = flags;
- m.VFS_CREAT_MODE = va_arg(argp, int);
- m.VFS_CREAT_NAME = (char *) __UNCONST(name);
+ m.m_lc_vfs_creat.len = strlen(name) + 1;
+ m.m_lc_vfs_creat.flags = flags;
+ m.m_lc_vfs_creat.mode = va_arg(argp, mode_t);
+ m.m_lc_vfs_creat.name = (vir_bytes)name;
call = VFS_CREAT;
} else {
_loadname(name, &m);
vir_bytes vname;
size_t vname_length;
- vname = (vir_bytes) job_m_in.VFS_CREAT_NAME;
- vname_length = (size_t) job_m_in.VFS_CREAT_LEN;
- open_flags = job_m_in.VFS_CREAT_FLAGS;
- create_mode = job_m_in.VFS_CREAT_MODE;
+ vname = job_m_in.m_lc_vfs_creat.name;
+ vname_length = job_m_in.m_lc_vfs_creat.len;
+ open_flags = job_m_in.m_lc_vfs_creat.flags;
+ create_mode = job_m_in.m_lc_vfs_creat.mode;
if (!(open_flags & O_CREAT))
return(EINVAL);