Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Aug 1999 14:56:45 -0700 (PDT)
From:      John Polstra <jdp@polstra.com>
To:        hackers@freebsd.org
Subject:   Getting device and inode number from a vnode
Message-ID:  <XFMail.990815145645.jdp@polstra.com>

next in thread | raw e-mail | index | archive | help
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)
says, "The file should not be locked on entry."  But when stat calls
vn_stat, the vnode is locked.  Which is correct -- or doesn't it
matter?

Thanks,
John
---
  John Polstra                                               jdp@polstra.com
  John D. Polstra & Co., Inc.                        Seattle, Washington USA
  "No matter how cynical I get, I just can't keep up."        -- Nora Ephron



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.990815145645.jdp>