Messages in this thread | | | Date | Wed, 9 Jun 2004 01:24:35 -0400 (EDT) | Subject | Re: [PATCH] iso9660 Inodes Anywhere and NFS | From | "Eric Lammerts" <> |
| |
"Paul Serice" <paul@serice.net> wrote: > The inode number scheme was also changed. Continuing to use the byte > offset would have resulted in non-unique inodes in many common > situations, but because the inode number no longer plays any role in > reading the meta-data off the disk, I was free to set the inode number > to some unique characteristic of the file. I have chosen to use the > block offset which is also 32-bits wide.
But what about 0-byte files? The block offset could be the same for all 0-byte files, or worse, it could be the same as the block offset of a non-0-byte file.
I don't know if this has been mentioned before, but since a directory record is always 34 bytes or bigger, why not simply divide the directory record byte offset by 32? I.e.,
- inode_number = (bh->b_blocknr << bufbits) + offset; + inode_number = (bh->b_blocknr << (bufbits - 5)) + (offset >> 5);
Eric
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |