Yes, I know the algorithm.
> It relies on numbers from stat() and numbers from readdir() being
> in sync. It's not true on so many filesystems that this algorithm
> is laughable. Anything with synthetic inode numbers breaks it.
Sure, but devfs does keep inums in sync. So it shouldn't be an issue.
[From another reply]
> So fix getcwd(3) in libc5.
Well, I might just do that one day. But I've got some devfs races to
fix first :-)
> Or use your ->dentry in devfs_readdir() - then you can get the
> consistency you want for existing inodes and that will allow b0rken
> getcwd() to work.
Yes, devfs_readdir() already uses de->inode.ino. Anyway, when I get
back to that machine I'll be able to dig further.
Regards,
Richard....
Permanent: rgooch@atnf.csiro.au
Current: rgooch@ras.ucalgary.ca
-
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/