From: adas@sourceware.org <adas@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] cluster/gfs-kernel/src/gfs incore.h mount.c op ...
Date: 23 Oct 2006 20:15:29 -0000 [thread overview]
Message-ID: <20061023201529.12026.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: cluster
Changes by: adas at sourceware.org 2006-10-23 20:15:28
Modified files:
gfs-kernel/src/gfs: incore.h mount.c ops_fstype.c ops_super.c
Log message:
Adding Josef's noquota mount option for GFS1 in RHEL5. Original bz 205285
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/incore.h.diff?cvsroot=cluster&r1=1.29&r2=1.30
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/mount.c.diff?cvsroot=cluster&r1=1.15&r2=1.16
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_fstype.c.diff?cvsroot=cluster&r1=1.27&r2=1.28
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_super.c.diff?cvsroot=cluster&r1=1.23&r2=1.24
--- cluster/gfs-kernel/src/gfs/incore.h 2006/09/13 20:07:38 1.29
+++ cluster/gfs-kernel/src/gfs/incore.h 2006/10/23 20:15:28 1.30
@@ -855,6 +855,7 @@
(more daemons => faster cleanup) */
int ar_posix_acls; /* Enable posix acls */
int ar_suiddir; /* suiddir support */
+ int ar_noquota; /* Turn off quota support */
};
struct gfs_tune {
--- cluster/gfs-kernel/src/gfs/mount.c 2006/10/14 20:16:15 1.15
+++ cluster/gfs-kernel/src/gfs/mount.c 2006/10/23 20:15:28 1.16
@@ -153,6 +153,9 @@
else if (!strcmp(x, "suiddir"))
args->ar_suiddir = TRUE;
+ else if (!strcmp(x, "noquota"))
+ args->ar_noquota = TRUE;
+
/* Unknown */
else {
--- cluster/gfs-kernel/src/gfs/ops_fstype.c 2006/08/10 14:52:20 1.27
+++ cluster/gfs-kernel/src/gfs/ops_fstype.c 2006/10/23 20:15:28 1.28
@@ -612,6 +612,14 @@
init_vfs(sb, SDF_NOATIME);
+ /* Turn off quota stuff if we get the noquota mount option, don't
+ need to grab the sd_tune lock here since its before anything
+ touches the sd_tune values */
+ if (sdp->sd_args.ar_noquota) {
+ sdp->sd_tune.gt_quota_enforce = 0;
+ sdp->sd_tune.gt_quota_account = 0;
+ }
+
/* Set up the buffer cache and fill in some fake block size values
to allow us to read-in the on-disk superblock. */
--- cluster/gfs-kernel/src/gfs/ops_super.c 2006/10/14 20:16:15 1.23
+++ cluster/gfs-kernel/src/gfs/ops_super.c 2006/10/23 20:15:28 1.24
@@ -322,6 +322,7 @@
gfs_remount_fs(struct super_block *sb, int *flags, char *data)
{
struct gfs_sbd *sdp = get_v2sdp(sb);
+ struct gfs_tune *gt = &sdp->sd_tune;
int error = 0;
struct gfs_args *args;
@@ -362,6 +363,25 @@
}
}
+ if (args->ar_noquota) {
+ if (sdp->sd_args.ar_noquota == FALSE)
+ printk("GFS: remounting without quota\n");
+ sdp->sd_args.ar_noquota = TRUE;
+ spin_lock(>->gt_spin);
+ gt->gt_quota_enforce = 0;
+ gt->gt_quota_account = 0;
+ spin_unlock(>->gt_spin);
+ }
+ else {
+ if (sdp->sd_args.ar_noquota == TRUE)
+ printk("GFS: remounting with quota\n");
+ sdp->sd_args.ar_noquota = FALSE;
+ spin_lock(>->gt_spin);
+ gt->gt_quota_enforce = 1;
+ gt->gt_quota_account = 1;
+ spin_unlock(>->gt_spin);
+ }
+
/* Don't let the VFS update atimes. GFS handles this itself. */
*flags |= MS_NOATIME | MS_NODIRATIME;
@@ -444,6 +464,8 @@
seq_printf(s, ",num_glockd=%u", args->ar_num_glockd);
if (args->ar_posix_acls)
seq_printf(s, ",acl");
+ if (args->ar_noquota)
+ seq_printf(s, ",noquota");
if (args->ar_suiddir)
seq_printf(s, ",suiddir");
reply other threads:[~2006-10-23 20:15 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20061023201529.12026.qmail@sourceware.org \
--to=adas@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).