Commit d27e202b authored by Konstantin Komarov's avatar Konstantin Komarov

fs/ntfs3: Add more info into /proc/fs/ntfs3/<dev>/volinfo

Signed-off-by: default avatarKonstantin Komarov <almaz.alexandrovich@paragon-software.com>
parent f684073c
...@@ -453,15 +453,23 @@ static struct proc_dir_entry *proc_info_root; ...@@ -453,15 +453,23 @@ static struct proc_dir_entry *proc_info_root;
* ntfs3.1 * ntfs3.1
* cluster size * cluster size
* number of clusters * number of clusters
* total number of mft records
* number of used mft records ~= number of files + folders
* real state of ntfs "dirty"/"clean"
* current state of ntfs "dirty"/"clean"
*/ */
static int ntfs3_volinfo(struct seq_file *m, void *o) static int ntfs3_volinfo(struct seq_file *m, void *o)
{ {
struct super_block *sb = m->private; struct super_block *sb = m->private;
struct ntfs_sb_info *sbi = sb->s_fs_info; struct ntfs_sb_info *sbi = sb->s_fs_info;
seq_printf(m, "ntfs%d.%d\n%u\n%zu\n", sbi->volume.major_ver, seq_printf(m, "ntfs%d.%d\n%u\n%zu\n\%zu\n%zu\n%s\n%s\n",
sbi->volume.minor_ver, sbi->cluster_size, sbi->volume.major_ver, sbi->volume.minor_ver,
sbi->used.bitmap.nbits); sbi->cluster_size, sbi->used.bitmap.nbits,
sbi->mft.bitmap.nbits,
sbi->mft.bitmap.nbits - wnd_zeroes(&sbi->mft.bitmap),
sbi->volume.real_dirty ? "dirty" : "clean",
(sbi->volume.flags & VOLUME_FLAG_DIRTY) ? "dirty" : "clean");
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment