aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2008-10-30 02:21:10 -0400
committerLachlan McIlroy <lachlan@sgi.com>2008-10-30 02:21:10 -0400
commit3471394ba56f44761ce1c300f139478dbfb49d4a (patch)
treefb9faf7d207ad5421a7e9d2eb1a0ca73ef7f0964 /fs/xfs
parent76bf105cb16da6c847a13a3c77dc962ba1081713 (diff)
[XFS] fix instant oops with tracing enabled
We can only read inode->i_count if the inode is actually there and not a NULL pointer. This was introduced in one of the recent sync patches. SGI-PV: 988255 SGI-Modid: xfs-linux-melb:xfs-kern:32315a Signed-off-by: Christoph Hellwig <hch@infradead.org> Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Diffstat (limited to 'fs/xfs')
-rw-r--r--fs/xfs/linux-2.6/xfs_vnode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/xfs/linux-2.6/xfs_vnode.c b/fs/xfs/linux-2.6/xfs_vnode.c
index dceb6dbaa2da..ac827d231490 100644
--- a/fs/xfs/linux-2.6/xfs_vnode.c
+++ b/fs/xfs/linux-2.6/xfs_vnode.c
@@ -92,7 +92,7 @@ static inline int xfs_icount(struct xfs_inode *ip)
92{ 92{
93 struct inode *inode = VFS_I(ip); 93 struct inode *inode = VFS_I(ip);
94 94
95 if (!inode) 95 if (inode)
96 return atomic_read(&inode->i_count); 96 return atomic_read(&inode->i_count);
97 return -1; 97 return -1;
98} 98}