From: Mike Waychison <michael.waychison@sun.com>
To: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org
Cc: raven@themaw.net
Subject: [PATCH 7/28] AFS: Update AFS to use new expiry interface
Date: Mon, 25 Oct 2004 10:42:01 -0400 [thread overview]
Message-ID: <10987153211852@sun.com> (raw)
In-Reply-To: <1098715291724@sun.com>
Update kAFS to use the new mountpoint expire infrastructure.
Signed-off-by: Mike Waychison <michael.waychison@sun.com>
---
cmservice.c | 5 -----
mntpt.c | 34 +++++++---------------------------
super.c | 2 --
3 files changed, 7 insertions(+), 34 deletions(-)
Index: linux-2.6.9-quilt/fs/afs/mntpt.c
===================================================================
--- linux-2.6.9-quilt.orig/fs/afs/mntpt.c 2004-08-14 01:36:17.000000000 -0400
+++ linux-2.6.9-quilt/fs/afs/mntpt.c 2004-10-22 17:17:36.477918656 -0400
@@ -43,16 +43,6 @@ struct inode_operations afs_mntpt_inode_
.getattr = afs_inode_getattr,
};
-static LIST_HEAD(afs_vfsmounts);
-
-static void afs_mntpt_expiry_timed_out(struct afs_timer *timer);
-
-struct afs_timer_ops afs_mntpt_expiry_timer_ops = {
- .timed_out = afs_mntpt_expiry_timed_out,
-};
-
-struct afs_timer afs_mntpt_expiry_timer;
-
unsigned long afs_mntpt_expiry_timeout = 20;
/*****************************************************************************/
@@ -252,9 +242,15 @@ static int afs_mntpt_follow_link(struct
newnd = *nd;
newnd.dentry = dentry;
- err = do_add_mount(newmnt, &newnd, 0, &afs_vfsmounts);
+ err = do_graft_mount(newmnt, &newnd);
if (!err) {
+ /*
+ * We currently don't test to see if we were able to set
+ * expiry.
+ */
+ mnt_expire(newmnt, afs_mntpt_expiry_timeout);
+
path_release(nd);
mntget(newmnt);
nd->mnt = newmnt;
@@ -265,19 +261,3 @@ static int afs_mntpt_follow_link(struct
kleave(" = %d", err);
return err;
} /* end afs_mntpt_follow_link() */
-
-/*****************************************************************************/
-/*
- * handle mountpoint expiry timer going off
- */
-static void afs_mntpt_expiry_timed_out(struct afs_timer *timer)
-{
- kenter("");
-
- mark_mounts_for_expiry(&afs_vfsmounts);
-
- afs_kafstimod_add_timer(&afs_mntpt_expiry_timer,
- afs_mntpt_expiry_timeout * HZ);
-
- kleave("");
-} /* end afs_mntpt_expiry_timed_out() */
Index: linux-2.6.9-quilt/fs/afs/cmservice.c
===================================================================
--- linux-2.6.9-quilt.orig/fs/afs/cmservice.c 2004-08-14 01:36:57.000000000 -0400
+++ linux-2.6.9-quilt/fs/afs/cmservice.c 2004-10-22 17:17:36.478918504 -0400
@@ -306,9 +306,6 @@ int afscm_start(void)
ret = rxrpc_add_service(afs_transport, &AFSCM_service);
if (ret < 0)
goto kill;
-
- afs_kafstimod_add_timer(&afs_mntpt_expiry_timer,
- afs_mntpt_expiry_timeout * HZ);
}
afscm_usage++;
@@ -389,8 +386,6 @@ void afscm_stop(void)
spin_lock(&kafscmd_attention_lock);
}
spin_unlock(&kafscmd_attention_lock);
-
- afs_kafstimod_del_timer(&afs_mntpt_expiry_timer);
}
up_write(&afscm_sem);
Index: linux-2.6.9-quilt/fs/afs/super.c
===================================================================
--- linux-2.6.9-quilt.orig/fs/afs/super.c 2004-08-14 01:36:56.000000000 -0400
+++ linux-2.6.9-quilt/fs/afs/super.c 2004-10-22 17:17:36.478918504 -0400
@@ -78,8 +78,6 @@ int __init afs_fs_init(void)
_enter("");
- afs_timer_init(&afs_mntpt_expiry_timer, &afs_mntpt_expiry_timer_ops);
-
/* create ourselves an inode cache */
atomic_set(&afs_count_active_inodes, 0);
next prev parent reply other threads:[~2004-10-25 14:42 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-25 14:38 [PATCH 0/28] Autofs NG Patchset 0.2 Mike Waychison
2004-10-25 14:39 ` [PATCH 1/28] VFS: Unexport umount_tree Mike Waychison
2004-10-25 14:39 ` [PATCH 2/28] VFS: mnt_fslink -> mnt_expire Mike Waychison
2004-10-25 14:40 ` [PATCH 3/28] VFS: Move expiry into vfs Mike Waychison
2004-10-25 14:40 ` [PATCH 4/28] VFS: Stat shouldn't stop expire Mike Waychison
2004-10-25 14:41 ` [PATCH 5/28] VFS: Make expiry timeout configurable Mike Waychison
2004-10-25 14:41 ` [PATCH 6/28] VFS: Make expiry recursive Mike Waychison
2004-10-25 14:42 ` Mike Waychison [this message]
2004-10-25 14:42 ` [PATCH 8/28] VFS: Remove MNT_EXPIRE support Mike Waychison
2004-10-25 14:43 ` [PATCH 9/28] VFS: Give sane expiry semantics Mike Waychison
2004-10-25 14:43 ` [PATCH 10/28] VFS: Move next_mnt() Mike Waychison
2004-10-25 14:44 ` [PATCH 11/28] VFS: Allow for detachable subtrees Mike Waychison
2004-10-25 14:44 ` [PATCH 12/28] VFS: Remove (now bogus) check_mnt Mike Waychison
2004-10-25 14:45 ` [PATCH 13/28] VFS: Introduce soft reference counts Mike Waychison
2004-10-25 15:25 ` Christoph Hellwig
2004-10-25 15:35 ` [PATCH 14/28] VFS: Introduce Mountpoint file descriptors (resend) Mike Waychison
2004-10-25 17:20 ` [PATCH 13/28] VFS: Introduce soft reference counts Mika Penttilä
2004-10-25 17:25 ` Mike Waychison
2004-10-25 17:52 ` Mika Penttilä
2004-10-25 17:56 ` [PATCH 11/28] VFS: Allow for detachable subtrees (resend) Mike Waychison
2004-10-25 15:09 ` [PATCH 12/28] VFS: Remove (now bogus) check_mnt Christoph Hellwig
2004-10-25 15:15 ` Mike Waychison
2004-10-25 15:04 ` [PATCH 8/28] VFS: Remove MNT_EXPIRE support Christoph Hellwig
2004-10-25 15:12 ` Mike Waychison
2004-10-25 15:16 ` Christoph Hellwig
2004-10-25 15:30 ` Mike Waychison
2004-10-25 17:16 ` Mike Waychison
2004-10-25 17:29 ` Mike Waychison
2004-10-25 15:04 ` [PATCH 6/28] VFS: Make expiry recursive Christoph Hellwig
2004-10-26 10:27 ` [PATCH 4/28] VFS: Stat shouldn't stop expire Christoph Hellwig
2004-10-27 18:36 ` Mike Waychison
2004-10-25 14:59 ` [PATCH 3/28] VFS: Move expiry into vfs Christoph Hellwig
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=10987153211852@sun.com \
--to=michael.waychison@sun.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=raven@themaw.net \
/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).