linux/drivers/infiniband/core
David Howells 454e2398be [PATCH] VFS: Permit filesystem to override root dentry on mount
Extend the get_sb() filesystem operation to take an extra argument that
permits the VFS to pass in the target vfsmount that defines the mountpoint.

The filesystem is then required to manually set the superblock and root dentry
pointers.  For most filesystems, this should be done with simple_set_mnt()
which will set the superblock pointer and then set the root dentry to the
superblock's s_root (as per the old default behaviour).

The get_sb() op now returns an integer as there's now no need to return the
superblock pointer.

This patch permits a superblock to be implicitly shared amongst several mount
points, such as can be done with NFS to avoid potential inode aliasing.  In
such a case, simple_set_mnt() would not be called, and instead the mnt_root
and mnt_sb would be set directly.

The patch also makes the following changes:

 (*) the get_sb_*() convenience functions in the core kernel now take a vfsmount
     pointer argument and return an integer, so most filesystems have to change
     very little.

 (*) If one of the convenience function is not used, then get_sb() should
     normally call simple_set_mnt() to instantiate the vfsmount. This will
     always return 0, and so can be tail-called from get_sb().

 (*) generic_shutdown_super() now calls shrink_dcache_sb() to clean up the
     dcache upon superblock destruction rather than shrink_dcache_anon().

     This is required because the superblock may now have multiple trees that
     aren't actually bound to s_root, but that still need to be cleaned up. The
     currently called functions assume that the whole tree is rooted at s_root,
     and that anonymous dentries are not the roots of trees which results in
     dentries being left unculled.

     However, with the way NFS superblock sharing are currently set to be
     implemented, these assumptions are violated: the root of the filesystem is
     simply a dummy dentry and inode (the real inode for '/' may well be
     inaccessible), and all the vfsmounts are rooted on anonymous[*] dentries
     with child trees.

     [*] Anonymous until discovered from another tree.

 (*) The documentation has been adjusted, including the additional bit of
     changing ext2_* into foo_* in the documentation.

[akpm@osdl.org: convert ipath_fs, do other stuff]
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Al Viro <viro@zeniv.linux.org.uk>
Cc: Nathan Scott <nathans@sgi.com>
Cc: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-06-23 07:42:45 -07:00
..
addr.c IB: address translation to map IP toIB addresses (GIDs) 2006-06-17 20:37:28 -07:00
agent.c IB/mad: Simplify SMI by eliminating smi_check_local_dr_smp() 2006-03-20 10:08:11 -08:00
agent.h [PATCH] missing include in infiniband 2005-10-29 10:35:07 -07:00
cache.c IB: Add caching of ports' LMC 2006-06-17 20:37:34 -07:00
cm_msgs.h [IB] cm: Add missing break in switch 2005-10-20 12:29:36 -07:00
cm.c IB/cm: Use address handle helpers 2006-06-17 20:37:40 -07:00
cma.c IB: IP address based RDMA connection manager 2006-06-17 20:37:29 -07:00
core_priv.h [PATCH] IB: move include files to include/rdma 2005-08-26 20:37:38 -07:00
device.c IB: convert from semaphores to mutexes 2006-01-13 14:51:39 -08:00
fmr_pool.c IB/fmr: Use device's max_map_map_per_fmr attribute in FMR pool. 2006-06-17 20:37:37 -07:00
mad_priv.h IB: Make needlessly global ib_mad_cache static 2006-06-17 20:37:31 -07:00
mad_rmpp.c IB: refcount race fixes 2006-05-12 14:57:52 -07:00
mad_rmpp.h [IB] Fix MAD layer DMA mappings to avoid touching data buffer once mapped 2005-10-25 10:51:39 -07:00
mad.c IB/mad: Check GID/LID when matching requests 2006-06-17 20:37:34 -07:00
Makefile IB: IP address based RDMA connection manager 2006-06-17 20:37:29 -07:00
packer.c [PATCH] fix remaining missing includes 2005-11-07 07:53:41 -08:00
sa_query.c IB/cm: Use address handle helpers 2006-06-17 20:37:40 -07:00
smi.c [PATCH] IB: move include files to include/rdma 2005-08-26 20:37:38 -07:00
smi.h IB/mad: Simplify SMI by eliminating smi_check_local_dr_smp() 2006-03-20 10:08:11 -08:00
sysfs.c IB: Fix display of 4-bit port counters in sysfs 2006-05-09 10:50:28 -07:00
ucm.c IB/ucm: Get rid of duplicate P_Key parameter 2006-06-17 20:37:39 -07:00
ud_header.c [PATCH] fix remaining missing includes 2005-11-07 07:53:41 -08:00
user_mad.c IB/mad: RMPP support for additional classes 2006-03-30 07:19:51 -08:00
uverbs_cmd.c IB/uverbs: Don't serialize with ib_uverbs_idr_mutex 2006-06-17 20:44:49 -07:00
uverbs_main.c [PATCH] VFS: Permit filesystem to override root dentry on mount 2006-06-23 07:42:45 -07:00
uverbs_marshall.c IB: common handling for marshalling parameters to/from userspace 2006-06-17 20:37:27 -07:00
uverbs_mem.c IB/uverbs: Don't leak ref to mm on error path 2006-05-17 22:20:50 -07:00
uverbs.h IB/uverbs: Don't serialize with ib_uverbs_idr_mutex 2006-06-17 20:44:49 -07:00
verbs.c IB: Add ib_init_ah_from_wc() 2006-06-17 20:37:39 -07:00