linux/fs/xfs/linux-2.6
Christoph Hellwig 848ce8f731 xfs: simplify inode teardown
Currently the reclaim code for the case where we don't reclaim the
final reclaim is overly complicated.  We know that the inode is clean
but instead of just directly reclaiming the clean inode we go through
the whole process of marking the inode reclaimable just to directly
reclaim it from the calling context.  Besides being overly complicated
this introduces a race where iget could recycle an inode between
marked reclaimable and actually being reclaimed leading to panics.

This patch gets rid of the existing reclaim path, and replaces it with
a simple call to xfs_ireclaim if the inode was clean.  While we're at
it we also use the slightly more lax xfs_inode_clean check we'd use
later to determine if we need to flush the inode here.

Finally get rid of xfs_reclaim function and place the remaining small
bits of reclaim code directly into xfs_fs_destroy_inode.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reported-by: Patrick Schreurs <patrick@news-service.com>
Reported-by: Tommy van Leeuwen <tommy@news-service.com>
Tested-by: Patrick Schreurs <patrick@news-service.com>
Reviewed-by: Alex Elder <aelder@sgi.com>
Signed-off-by: Alex Elder <aelder@sgi.com>
2009-12-11 15:11:19 -06:00
..
kmem.c Fix congestion_wait() sync/async vs read/write confusion 2009-07-10 20:31:53 +02:00
kmem.h xfs: prevent deadlock in xfs_qm_shake() 2009-06-01 22:59:45 -05:00
mrlock.h [XFS] shrink mrlock_t 2008-04-29 15:54:02 +10:00
sv.h remove dead code from sv_t implementation 2008-12-04 15:39:21 +11:00
time.h [XFS] Update license/copyright notices to match the prefered SGI 2005-11-02 14:58:39 +11:00
xfs_acl.c switch xfs to generic acl caching helpers 2009-06-24 08:17:07 -04:00
xfs_aops.c Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs 2009-10-09 13:29:42 -07:00
xfs_aops.h xfs: prevent unwritten extent conversion from blocking I/O completion 2009-04-06 18:42:11 +02:00
xfs_buf.c Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs 2009-08-12 08:49:35 -07:00
xfs_buf.h xfs: only issues a cache flush on unmount if barriers are enabled 2009-03-06 17:35:12 -06:00
xfs_cred.h [XFS] Fix merge failures 2008-12-29 16:47:18 +11:00
xfs_dmapi_priv.h [XFS] Remove KERNEL_VERSION macros from xfs_dmapi.h 2006-11-11 18:05:06 +11:00
xfs_export.c [XFS] pass XFS_IGET_BULKSTAT to xfs_iget for handle operations 2009-01-09 15:17:17 +11:00
xfs_export.h xfs: new export ops 2007-10-22 08:13:20 -07:00
xfs_file.c Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs 2009-10-09 13:29:42 -07:00
xfs_fs_subr.c xfs: use xfs_sync_inodes() for device flushing 2009-04-06 18:44:54 +02:00
xfs_fs_subr.h [XFS] decontaminate vnode operations from behavior details 2007-10-15 16:54:29 +10:00
xfs_globals.c [XFS] remove restricted chown parameter from xfs linux 2008-10-30 18:30:48 +11:00
xfs_globals.h CRED: Separate task security context from task_struct 2008-11-14 10:39:16 +11:00
xfs_ioctl32.c xfs: actually enable the swapext compat handler 2009-09-01 17:00:46 -05:00
xfs_ioctl32.h [XFS] fix compile on 32 bit systems 2008-12-04 13:07:29 +11:00
xfs_ioctl.c Merge branch 'master' of git://git.kernel.org/pub/scm/fs/xfs/xfs 2009-06-11 16:56:49 -05:00
xfs_ioctl.h xfs: fix dentry aliasing issues in open_by_handle 2009-01-19 14:43:18 +11:00
xfs_iops.c Merge branch 'master' into for-linus 2009-10-08 13:53:44 -05:00
xfs_iops.h [XFS] add a FMODE flag to make XFS invisible I/O less hacky 2008-12-11 13:14:41 +11:00
xfs_linux.h block: rename CONFIG_LBD to CONFIG_LBDAF 2009-06-19 08:08:50 +02:00
xfs_lrw.c xfs: implement ->dirty_inode to fix timestamp handling 2009-10-08 12:00:03 -05:00
xfs_lrw.h [XFS] remove sendfile leftovers 2008-04-29 16:08:14 +10:00
xfs_quotaops.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/fs/xfs/xfs 2009-10-31 12:12:49 -07:00
xfs_stats.c xfs: switch to seq_file 2009-09-15 12:29:24 -05:00
xfs_stats.h [XFS] add new btree statistics 2008-10-30 16:55:03 +11:00
xfs_super.c xfs: simplify inode teardown 2009-12-11 15:11:19 -06:00
xfs_super.h const: make struct super_block::s_qcop const 2009-09-22 07:17:24 -07:00
xfs_sync.c xfs: simplify inode teardown 2009-12-11 15:11:19 -06:00
xfs_sync.h xfs: simplify inode teardown 2009-12-11 15:11:19 -06:00
xfs_sysctl.c sysctl: remove "struct file *" argument of ->proc_handler 2009-09-24 07:21:04 -07:00
xfs_sysctl.h [XFS] remove restricted chown parameter from xfs linux 2008-10-30 18:30:48 +11:00
xfs_version.h [XFS] Update license/copyright notices to match the prefered SGI 2005-11-02 14:58:39 +11:00
xfs_vnode.h xfs: kill VN_BAD 2009-03-16 08:25:25 +01:00
xfs_xattr.c xfs: use generic Posix ACL code 2009-06-10 17:07:47 +02:00