Hi,
In get_filesystem_info mnt_sb->s_root of a vfsmntlist entry is directly passed
to d_path without checking whether it is null. This causes a panic in following
situation:
Process1 is in <filesystem>_put_super. Before this in d_umount, sb->s_root
is set to null.
Process2 scans /proc/mounts which enters get_filesystem_info. Since vfsmnt
entry for the filesystem being unmounted exists, it passes mnt_sb->s_root to
d_path.
Attached patch fixes that by skipping an entry if sb->s_root is null.
-- Amit Kale Veritas Software ( http://www.veritas.com )--- linux-2.3.99-pre3/fs/super.c Tue Mar 28 11:59:08 2000 +++ super.c Tue Mar 28 13:55:12 2000 @@ -364,6 +364,8 @@ int get_filesystem_info( char *buf ) if (!buffer) return 0; for (tmp = vfsmntlist; tmp && len < PAGE_SIZE - 160; tmp = tmp->mnt_next) { + if (!tmp->mnt_sb->s_root) + continue; path = d_path(tmp->mnt_sb->s_root, buffer, PAGE_SIZE); if (!path) continue;
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Fri Mar 31 2000 - 21:00:21 EST