From: Lionel Sambuc Date: Tue, 29 Apr 2014 13:35:42 +0000 (+0200) Subject: Message types for VFS mountpoint X-Git-Tag: v3.3.0~347 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/mdoc.3.txt?a=commitdiff_plain;h=16a3f2320334499598411393b4265ca46644ed44;p=minix.git Message types for VFS mountpoint Change-Id: I61c5729628b9b9262cc11415591b1b0f25ad04a8 --- diff --git a/include/minix/ipc.h b/include/minix/ipc.h index bd799c364..7e3d9fb6a 100644 --- a/include/minix/ipc.h +++ b/include/minix/ipc.h @@ -204,6 +204,13 @@ typedef struct { } mess_fs_vfs_lookup; _ASSERT_MSG_SIZE(mess_fs_vfs_lookup); +typedef struct { + ino_t inode; + + uint8_t data[48]; +} mess_vfs_fs_mountpoint; +_ASSERT_MSG_SIZE(mess_vfs_fs_mountpoint); + typedef struct { dev_t device; @@ -330,6 +337,7 @@ typedef struct { mess_fs_vfs_create m_fs_vfs_create; mess_vfs_fs_lookup m_vfs_fs_lookup; mess_fs_vfs_lookup m_fs_vfs_lookup; + mess_vfs_fs_mountpoint m_vfs_fs_mountpoint; mess_vfs_fs_readsuper m_vfs_fs_readsuper; mess_fs_vfs_readsuper m_fs_vfs_readsuper; mess_vfs_utimens m_vfs_utimens; diff --git a/lib/libpuffs/mount.c b/lib/libpuffs/mount.c index 8707d7de5..036c5bd90 100644 --- a/lib/libpuffs/mount.c +++ b/lib/libpuffs/mount.c @@ -49,13 +49,14 @@ int fs_mountpoint(void) */ int r = OK; struct puffs_node *pn; - pmode_t bits; + mode_t bits; /* * XXX: we assume that lookup was done first, so pnode can be found with * puffs_pn_nodewalk. */ - if ((pn = puffs_pn_nodewalk(global_pu, 0, &fs_m_in.REQ_INODE_NR)) == NULL) + if ((pn = puffs_pn_nodewalk(global_pu, 0, &fs_m_in.m_vfs_fs_mountpoint.inode)) + == NULL) return(EINVAL); diff --git a/servers/ext2/mount.c b/servers/ext2/mount.c index da8cd1994..5904e832f 100644 --- a/servers/ext2/mount.c +++ b/servers/ext2/mount.c @@ -174,10 +174,10 @@ int fs_mountpoint() */ register struct inode *rip; int r = OK; - pmode_t bits; + mode_t bits; /* Temporarily open the file. */ - if( (rip = get_inode(fs_dev, fs_m_in.REQ_INODE_NR)) == NULL) + if( (rip = get_inode(fs_dev, fs_m_in.m_vfs_fs_mountpoint.inode)) == NULL) return(EINVAL); diff --git a/servers/iso9660fs/mount.c b/servers/iso9660fs/mount.c index 579db2d6d..b852ec9b9 100644 --- a/servers/iso9660fs/mount.c +++ b/servers/iso9660fs/mount.c @@ -70,7 +70,7 @@ int fs_mountpoint() int r = OK; /* Temporarily open the file. */ - if ((rip = get_dir_record(fs_m_in.REQ_INODE_NR)) == NULL) + if ((rip = get_dir_record(fs_m_in.m_vfs_fs_mountpoint.inode)) == NULL) return(EINVAL); if (rip->d_mountpoint) diff --git a/servers/mfs/mount.c b/servers/mfs/mount.c index 902da7e5d..ec832e9b3 100644 --- a/servers/mfs/mount.c +++ b/servers/mfs/mount.c @@ -132,7 +132,7 @@ int fs_mountpoint() pmode_t bits; /* Temporarily open the file. */ - if( (rip = get_inode(fs_dev, (pino_t) fs_m_in.REQ_INODE_NR)) == NULL) + if( (rip = get_inode(fs_dev, fs_m_in.m_vfs_fs_mountpoint.inode)) == NULL) return(EINVAL); diff --git a/servers/vfs/request.c b/servers/vfs/request.c index f3f56aa6a..fcefe03ec 100644 --- a/servers/vfs/request.c +++ b/servers/vfs/request.c @@ -607,7 +607,7 @@ int req_mountpoint(endpoint_t fs_e, ino_t inode_nr) /* Fill in request message */ m.m_type = REQ_MOUNTPOINT; - m.REQ_INODE_NR = (pino_t) inode_nr; + m.m_vfs_fs_mountpoint.inode = inode_nr; /* Send/rec request */ return fs_sendrec(fs_e, &m);