[SSI] openssi/kernel/fs fifo.c,1.6,1.7

Roger Tsang <[email protected]> Fri, 05 Mar 2010 05:44:42 +0000
Newsgroups gmane.linux.cluster.ssic.cvs
Message-ID <[email protected]>
Update of /cvsroot/ssic-linux/openssi/kernel/fs
In directory sfp-cvsdas-3.v30.ch3.sourceforge.com:/tmp/cvs-serv30165/kernel/fs

Modified Files:
      Tag: OPENSSI-FC
	fifo.c 
Log Message:
* RMTFB:
- Allocate from slab rmtfb_cli / rmtfb_svr structs. (#ifdef RMTFB_KMEM_CACHE)
- rmtfb_remote_tty_ino() is no longer inlined. (#ifdef
  REOP_EXPORT_PATH_SVRNODE)
- Rename cluster/ssi/util/rmtfb.c:hash() to rfbhash(). Use Linux hashing
  routine.
- Split rmtfb_set_bit() into itself and rmtfb_clear_bit().

* RMTFB (#ifdef RMTFB_HASH_LOCKLESS):
- Implement lockless rfb_hash list traversal. Remove locks in various rmtfb_*
  code paths. Reduce latency in pipes, etc.
- Fix file struct leak on server when client lost race with another
  rmtfb_newcli().

* RMTFB (#ifdef RMTFB_REFCNT_FIX):
- Consolidate rfb_refcnt in rmtfb_cli / rmtfb_svr structs into rmtfb_cmn
  struct.

 cluster/ssi/util/rmtfb.c         |  629 +++++++++++++++++++++++++++----
 cluster/ssi/util/rmtsock.c       |    4 
 cluster/ssi/util/ssidev.c        |    2 
 cluster/ssi/vproc/dvp_pvpops.c   |    2 
 fs/fifo.c                        |   13 
 include/cluster/ssi/util/rmtfb.h |   31 -
 include/linux/config.h           |    7 
 7 files changed, 594 insertions(+), 94 deletions(-)


Index: fifo.c
===================================================================
RCS file: /cvsroot/ssic-linux/openssi/kernel/fs/fifo.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- fifo.c	17 Dec 2009 06:43:51 -0000	1.6
+++ fifo.c	5 Mar 2010 05:44:40 -0000	1.7
@@ -54,11 +54,14 @@
 			goto err_nocleanup;
 #ifdef CONFIG_SSI
 #ifdef RMTFB_REFCNT_FIX
-		{
-			struct pipe_inode_info *info = inode->i_pipe;
-			BUG_ON(info->ssi_rmtfb_cli);
-			info->ssi_rmtfb_cli = (void *) ftocli(filp);
-			/* ssi_fifo_register() already incremented rfb_refcnt */
+		if (filp->private_data) {
+			void *rfb = (void *) ftocli(filp);
+			if (rfb) {
+				struct pipe_inode_info *info = inode->i_pipe;
+				/* take rmtfb_cli reference from filp */
+				info->ssi_rmtfb_cli = rfb;
+				filp->private_data = NULL;
+			}
 		}
 #endif /* RMTFB_REFCNT_FIX */
 #endif


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev