Skip to content

Commit 490566e

Browse files
chenhanxiaoTrond Myklebust
authored and
Trond Myklebust
committed
NFS: Display the "fsc=" mount option if it is set
With this patch, mount command will show fsc=xxx if set: If -o fsc=6666 clientaddr=192.168.122.208,fsc=6666,local_lock=none If only -o fsc clientaddr=192.168.122.208,fsc,local_lock=none Signed-off-by: Chen Hanxiao <[email protected]> Signed-off-by: Trond Myklebust <[email protected]>
1 parent 6e21eda commit 490566e

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

fs/nfs/super.c

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -516,8 +516,16 @@ static void nfs_show_mount_options(struct seq_file *m, struct nfs_server *nfss,
516516
else
517517
nfs_show_nfsv4_options(m, nfss, showdefaults);
518518

519-
if (nfss->options & NFS_OPTION_FSCACHE)
519+
if (nfss->options & NFS_OPTION_FSCACHE) {
520+
#ifdef CONFIG_NFS_FSCACHE
521+
if (nfss->fscache_uniq)
522+
seq_printf(m, ",fsc=%s", nfss->fscache_uniq);
523+
else
524+
seq_puts(m, ",fsc");
525+
#else
520526
seq_puts(m, ",fsc");
527+
#endif
528+
}
521529

522530
if (nfss->options & NFS_OPTION_MIGRATION)
523531
seq_puts(m, ",migration");

0 commit comments

Comments
 (0)