Re: Getting device and inode number from a vnode

1999-08-15 Thread Assar Westerlund
John Polstra writes: > 1. I have a pointer to a vnode and I want to get the corresponding > dev_t and inode number. Is there a non-sleazy way to do that other > than calling vn_stat? I think you just want to call VOP_GETATTR(vp, vap, cred, proc) and then look at vap->va_fsid and vap->va_fileid.

Re: Getting device and inode number from a vnode

1999-08-15 Thread Assar Westerlund
John Polstra <[EMAIL PROTECTED]> writes: > 1. I have a pointer to a vnode and I want to get the corresponding > dev_t and inode number. Is there a non-sleazy way to do that other > than calling vn_stat? I think you just want to call VOP_GETATTR(vp, vap, cred, proc) and then look at vap->va_fsid

Re: Getting device and inode number from a vnode

1999-08-15 Thread John Polstra
Alfred Perlstein wrote: > On Sun, 15 Aug 1999, John Polstra wrote: >> >> 1. I have a pointer to a vnode and I want to get the corresponding >> dev_t and inode number. Is there a non-sleazy way to do that other >> than calling vn_stat? > > use vn_todev from "vfs_subr.c" ~line 2970 of 2976 if you

Re: Getting device and inode number from a vnode

1999-08-15 Thread Alfred Perlstein
On Sun, 15 Aug 1999, John Polstra wrote: > I have two VFS-related questions which are probably pretty basic. > > 1. I have a pointer to a vnode and I want to get the corresponding > dev_t and inode number. Is there a non-sleazy way to do that other > than calling vn_stat? use vn_todev from "vfs

Getting device and inode number from a vnode

1999-08-15 Thread John Polstra
I have two VFS-related questions which are probably pretty basic. 1. I have a pointer to a vnode and I want to get the corresponding dev_t and inode number. Is there a non-sleazy way to do that other than calling vn_stat? 2. The first action of vn_stat is to call VOP_GETATTR. VOP_GETATTR(9) say

Re: Getting device and inode number from a vnode

1999-08-15 Thread John Polstra
Alfred Perlstein wrote: > On Sun, 15 Aug 1999, John Polstra wrote: >> >> 1. I have a pointer to a vnode and I want to get the corresponding >> dev_t and inode number. Is there a non-sleazy way to do that other >> than calling vn_stat? > > use vn_todev from "vfs_subr.c" ~line 2970 of 2976 if you

Re: Getting device and inode number from a vnode

1999-08-15 Thread Alfred Perlstein
On Sun, 15 Aug 1999, John Polstra wrote: > I have two VFS-related questions which are probably pretty basic. > > 1. I have a pointer to a vnode and I want to get the corresponding > dev_t and inode number. Is there a non-sleazy way to do that other > than calling vn_stat? use vn_todev from "vf

Getting device and inode number from a vnode

1999-08-15 Thread John Polstra
I have two VFS-related questions which are probably pretty basic. 1. I have a pointer to a vnode and I want to get the corresponding dev_t and inode number. Is there a non-sleazy way to do that other than calling vn_stat? 2. The first action of vn_stat is to call VOP_GETATTR. VOP_GETATTR(9) sa