Messages in this thread Patch in this message | | | From | (Ulf Jaenicke-Roessler) | Subject | Re: strange vfat problem | Date | Fri, 13 Mar 1998 14:26:43 +0100 (MET) |
| |
David Woodhouse wrote:
> > I've observed a vfat problem; here's a session transcript: > > /c is a vfat mount.
[cut]
> > when directories are moved, they become inaccessible. If I move it > > back, it becomes accessible again. But only to the original directory. > > Kernel 2.1.86. > > > > Can anyone verify this? > > Yep. This has been happening for as long as I can remember. It's a dcache > thing. If you move the directory, unmount and remount the filesystem, it'll be > where you put it.
The kernel didn't handle the hard links for vfat directories correctly, which is shown by a simple stat call. So it thinks the moved directory is actually a file. You can even cat it.
You may want to use the appended patch I got from Gordon Chaffee. This patch is part of the kernel since 2.1.88, I think.
HTH,
Ulf
--- linux-2.1.85-clean/fs/vfat/namei.c Tue Jan 20 22:57:38 1998 +++ linux/fs/vfat/namei.c Fri Feb 13 08:19:03 1998 @@ -1761,12 +1768,15 @@ new_inode->i_mtime = old_inode->i_mtime; new_inode->i_atime = old_inode->i_atime; new_inode->i_ctime = old_inode->i_ctime; + new_inode->i_nlink = old_inode->i_nlink; + new_inode->i_op = old_inode->i_op; MSDOS_I(new_inode)->i_ctime_ms = MSDOS_I(old_inode)->i_ctime_ms; MSDOS_I(new_inode)->i_start = MSDOS_I(old_inode)->i_start; MSDOS_I(new_inode)->i_logstart = MSDOS_I(old_inode)->i_logstart; MSDOS_I(new_inode)->i_attrs = MSDOS_I(old_inode)->i_attrs; + fat_cache_inval_inode(old_inode); mark_inode_dirty(new_inode); old_dir->i_version = ++event;
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu
| |