Deepen Mehta
2011-Jan-05 10:07 UTC
[zfs-discuss] Query regarding how solaris stores the major number ?
Hi,
zfs_mknode() called from zfs_create() used to create device special file in
solaris kernel. I traverse the code and found how they stores the minor
number, which is in znode''s attributes field.
*if* (obj_type == DMU_OT_ZNODE || (vap->va_type == VBLK ||
vap->va_type == VCHR)) {
SA_ADD_BULK_ATTR(sa_attrs, cnt, SA_ZPL_RDEV(zfsvfs), NULL, &rdev, 8);
}
struct sa_bulk_attr field
{
.....
uint16_t
sa_buftype
....
}
which is of 16bit. so, it just store minor number and not a major number in
its attributes.
so, can somebody clarify where/how the major number stores in solaris code
or in znode(disk inode).
Regards,
Deepen Mehta
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://mail.opensolaris.org/pipermail/zfs-discuss/attachments/20110105/0a9873ac/attachment.html>