diff options
author | Chengguang Xu <cgxu519@icloud.com> | 2018-02-15 02:39:05 -0500 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2018-04-02 04:12:45 -0400 |
commit | 4d8969af28a5c1bccd9f42cf98ab5cff3c0fe140 (patch) | |
tree | fa423b2ef463803f841a2a03bec0df363e4a7707 | |
parent | 7377324e5bb2ed4c89e9d60691462a7272ee08a5 (diff) |
ceph: use seq_show_option for string type options
Using seq_show_option to replace seq_printf for string type options.
Signed-off-by: Chengguang Xu <cgxu519@icloud.com>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
-rw-r--r-- | fs/ceph/super.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/fs/ceph/super.c b/fs/ceph/super.c index ca8a830c07ad..52fec209f0a6 100644 --- a/fs/ceph/super.c +++ b/fs/ceph/super.c | |||
@@ -516,10 +516,7 @@ static int ceph_show_options(struct seq_file *m, struct dentry *root) | |||
516 | if ((fsopt->flags & CEPH_MOUNT_OPT_DCACHE) == 0) | 516 | if ((fsopt->flags & CEPH_MOUNT_OPT_DCACHE) == 0) |
517 | seq_puts(m, ",nodcache"); | 517 | seq_puts(m, ",nodcache"); |
518 | if (fsopt->flags & CEPH_MOUNT_OPT_FSCACHE) { | 518 | if (fsopt->flags & CEPH_MOUNT_OPT_FSCACHE) { |
519 | if (fsopt->fscache_uniq) | 519 | seq_show_option(m, "fsc", fsopt->fscache_uniq); |
520 | seq_printf(m, ",fsc=%s", fsopt->fscache_uniq); | ||
521 | else | ||
522 | seq_puts(m, ",fsc"); | ||
523 | } | 520 | } |
524 | if (fsopt->flags & CEPH_MOUNT_OPT_NOPOOLPERM) | 521 | if (fsopt->flags & CEPH_MOUNT_OPT_NOPOOLPERM) |
525 | seq_puts(m, ",nopoolperm"); | 522 | seq_puts(m, ",nopoolperm"); |
@@ -532,7 +529,7 @@ static int ceph_show_options(struct seq_file *m, struct dentry *root) | |||
532 | #endif | 529 | #endif |
533 | 530 | ||
534 | if (fsopt->mds_namespace) | 531 | if (fsopt->mds_namespace) |
535 | seq_printf(m, ",mds_namespace=%s", fsopt->mds_namespace); | 532 | seq_show_option(m, "mds_namespace", fsopt->mds_namespace); |
536 | if (fsopt->wsize) | 533 | if (fsopt->wsize) |
537 | seq_printf(m, ",wsize=%d", fsopt->wsize); | 534 | seq_printf(m, ",wsize=%d", fsopt->wsize); |
538 | if (fsopt->rsize != CEPH_MAX_READ_SIZE) | 535 | if (fsopt->rsize != CEPH_MAX_READ_SIZE) |