* [Cluster-devel] [GFS2 PATCH] gfs2: Turn the rgrplvb mount option on by default
@ 2018-08-24 13:45 Bob Peterson
0 siblings, 0 replies; only message in thread
From: Bob Peterson @ 2018-08-24 13:45 UTC (permalink / raw)
To: cluster-devel.redhat.com
Hi,
This patch changes the gfs2 mount code so that it defaults to using
the rgrplvb option for block allocations, and only shows you the
option if it's not the default.
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
---
fs/gfs2/incore.h | 2 ++
fs/gfs2/ops_fstype.c | 1 +
fs/gfs2/super.c | 8 ++++++--
3 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/fs/gfs2/incore.h b/fs/gfs2/incore.h
index b96d39c28e17..272d7d84d994 100644
--- a/fs/gfs2/incore.h
+++ b/fs/gfs2/incore.h
@@ -572,6 +572,8 @@ struct gfs2_statfs_change_host {
#define GFS2_ERRORS_RO 2 /* place holder for future feature */
#define GFS2_ERRORS_PANIC 3
+#define GFS2_RGRPLVB_DEFAULT 1
+
struct gfs2_args {
char ar_lockproto[GFS2_LOCKNAME_LEN]; /* Name of the Lock Protocol */
char ar_locktable[GFS2_LOCKNAME_LEN]; /* Name of the Lock Table */
diff --git a/fs/gfs2/ops_fstype.c b/fs/gfs2/ops_fstype.c
index c2469833b4fb..37bb779fcda8 100644
--- a/fs/gfs2/ops_fstype.c
+++ b/fs/gfs2/ops_fstype.c
@@ -1285,6 +1285,7 @@ static struct dentry *gfs2_mount(struct file_system_type *fs_type, int flags,
args.ar_statfs_quantum = 30;
args.ar_quota_quantum = 60;
args.ar_errors = GFS2_ERRORS_DEFAULT;
+ args.ar_rgrplvb = GFS2_RGRPLVB_DEFAULT;
error = gfs2_mount_args(&args, data);
if (error) {
diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c
index c212893534ed..81c853f38729 100644
--- a/fs/gfs2/super.c
+++ b/fs/gfs2/super.c
@@ -1459,8 +1459,12 @@ static int gfs2_show_options(struct seq_file *s, struct dentry *root)
seq_puts(s, ",nobarrier");
if (test_bit(SDF_DEMOTE, &sdp->sd_flags))
seq_puts(s, ",demote_interface_used");
- if (args->ar_rgrplvb)
- seq_puts(s, ",rgrplvb");
+ if (args->ar_rgrplvb != GFS2_RGRPLVB_DEFAULT) {
+ if (args->ar_rgrplvb)
+ seq_puts(s, ",rgrplvb");
+ else
+ seq_puts(s, ",norgrplvb");
+ }
if (args->ar_loccookie)
seq_puts(s, ",loccookie");
return 0;
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2018-08-24 13:45 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-24 13:45 [Cluster-devel] [GFS2 PATCH] gfs2: Turn the rgrplvb mount option on by default Bob Peterson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).