From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bob Peterson Date: Fri, 24 Aug 2018 09:45:42 -0400 (EDT) Subject: [Cluster-devel] [GFS2 PATCH] gfs2: Turn the rgrplvb mount option on by default Message-ID: <373775457.6280293.1535118342549.JavaMail.zimbra@redhat.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit 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 --- 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;