[SSI] openssi/kernel/cluster/ssi/cfs cfs_chard.c,1.17,1.18
Roger Tsang <[email protected]> Mon, 17 Jan 2011 06:39:14 +0000
| Newsgroups | gmane.linux.cluster.ssic.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/ssic-linux/openssi/kernel/cluster/ssi/cfs
In directory sfp-cvsdas-3.v30.ch3.sourceforge.com:/tmp/cvs-serv28455/cluster/ssi/cfs
Modified Files:
Tag: OPENSSI-FC
cfs_chard.c
Log Message:
- cfs_sb_soft_down: invoke shrink_dcache_sb(). clear unused dentries since the soft mount is going away.
(#ifdef SKIP)
- cfs_sb_start_down: skip invalidate_inodes() since it is done in cfs_sb_soft_down() and is not necessary for hard mounts.
- cfs_sb_start_down: skip shrink_icache_sb() for hard mounts. we are only temporarily bringing down the hard mount and in linux-2.6 the inode cache is pruned automatically.
Index: cfs_chard.c
===================================================================
RCS file: /cvsroot/ssic-linux/openssi/kernel/cluster/ssi/cfs/cfs_chard.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- cfs_chard.c 27 Oct 2009 03:18:29 -0000 1.17
+++ cfs_chard.c 17 Jan 2011 06:39:12 -0000 1.18
@@ -439,17 +439,17 @@
UNLOCK_COND_LOCK(&mip->mi_cond_lock);
}
SSI_ASSERT(mip->mi_flags & MI_START_DOWN);
+#ifdef SKIP
/* Try to purge an up SB before bringing it down. */
if (CFS_SB_UP_MIP(mip)) {
-#ifdef SKIP
cflush(sb, CFLUSH_DATA);
dcache_purge(sb, 0);
if (!CFS_AT_SERVER_SB(sb))
cfsdi_sync_sb(sb, CFSDI_NUMSYNCS_ALL, B_FALSE);
-#endif
/* SSI_XXX: Should we check for busy inodes? */
(void)invalidate_inodes(sb);
}
+#endif
/* Synchronize SB down/rebuild operations. */
LOCK_COND_LOCK(&mip->mi_cond_lock);
/* Preserve initial state of SB. */
@@ -516,13 +516,14 @@
}
/* No. */
else {
+#ifdef SKIP
/* Force clean unused inodes to be invalidated */
#ifdef SHRINK_ICACHE_SB
(void )shrink_icache_sb(sb);
#else
#warning No shrink_icache_sb() create in 2.6 based on GFS code
#endif
-
+#endif /* SKIP */
/* Wake anyone else trying to bring this SB down. */
LOCK_COND_LOCK(&mip->mi_cond_lock);
mip->mi_flags &= ~MI_START_DOWN;
@@ -834,7 +835,6 @@
cfs_sb_soft_down(struct super_block *sb)
{
cfs_mntinfo_t *mip; /* SB specific data. */
- //void clean_list(struct list_head *, void *, int);
SSI_ASSERT(sb != NULL);
SSI_ASSERT(sb->s_count > 0);
@@ -850,6 +850,7 @@
list_del_init(&sb->s_list);
spin_unlock(&sb_lock);
process_cnodes(sb, clean_list, NULL);
+ shrink_dcache_sb(sb);
/* SSI_XXX: Does there need to be a while() loop here waiting
* until invalidate_inodes() doesn't return busy?
*
------------------------------------------------------------------------------
Protect Your Site and Customers from Malware Attacks
Learn about various malware tactics and how to avoid them. Understand
malware threats, the impact they can have on your business, and how you
can protect your company and customers by using code signing.
http://p.sf.net/sfu/oracle-sfdevnl