aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/linux-2.6/xfs_lrw.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2008-03-05 21:45:58 -0500
committerLachlan McIlroy <lachlan@redback.melbourne.sgi.com>2008-04-17 21:40:15 -0400
commitbc4ac74a4e5bd7db02976eb1b681e1d11f81c9ce (patch)
tree580c59e724938a57874c05298c8da4e685971401 /fs/xfs/linux-2.6/xfs_lrw.c
parentd234154125197053d5215711b5df867979e55ebd (diff)
[XFS] cleanup vnode use in dmapi calls
SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30545a Signed-off-by: Christoph Hellwig <hch@infradead.org> Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_lrw.c')
-rw-r--r--fs/xfs/linux-2.6/xfs_lrw.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/fs/xfs/linux-2.6/xfs_lrw.c b/fs/xfs/linux-2.6/xfs_lrw.c
index 3c20007ab48f..01a8f26e1b17 100644
--- a/fs/xfs/linux-2.6/xfs_lrw.c
+++ b/fs/xfs/linux-2.6/xfs_lrw.c
@@ -231,7 +231,7 @@ xfs_read(
231 int dmflags = FILP_DELAY_FLAG(file) | DM_SEM_FLAG_RD(ioflags); 231 int dmflags = FILP_DELAY_FLAG(file) | DM_SEM_FLAG_RD(ioflags);
232 int iolock = XFS_IOLOCK_SHARED; 232 int iolock = XFS_IOLOCK_SHARED;
233 233
234 ret = -XFS_SEND_DATA(mp, DM_EVENT_READ, vp, *offset, size, 234 ret = -XFS_SEND_DATA(mp, DM_EVENT_READ, ip, *offset, size,
235 dmflags, &iolock); 235 dmflags, &iolock);
236 if (ret) { 236 if (ret) {
237 xfs_iunlock(ip, XFS_IOLOCK_SHARED); 237 xfs_iunlock(ip, XFS_IOLOCK_SHARED);
@@ -276,7 +276,6 @@ xfs_splice_read(
276 int flags, 276 int flags,
277 int ioflags) 277 int ioflags)
278{ 278{
279 bhv_vnode_t *vp = XFS_ITOV(ip);
280 xfs_mount_t *mp = ip->i_mount; 279 xfs_mount_t *mp = ip->i_mount;
281 ssize_t ret; 280 ssize_t ret;
282 281
@@ -290,7 +289,7 @@ xfs_splice_read(
290 int iolock = XFS_IOLOCK_SHARED; 289 int iolock = XFS_IOLOCK_SHARED;
291 int error; 290 int error;
292 291
293 error = XFS_SEND_DATA(mp, DM_EVENT_READ, vp, *ppos, count, 292 error = XFS_SEND_DATA(mp, DM_EVENT_READ, ip, *ppos, count,
294 FILP_DELAY_FLAG(infilp), &iolock); 293 FILP_DELAY_FLAG(infilp), &iolock);
295 if (error) { 294 if (error) {
296 xfs_iunlock(ip, XFS_IOLOCK_SHARED); 295 xfs_iunlock(ip, XFS_IOLOCK_SHARED);
@@ -317,7 +316,6 @@ xfs_splice_write(
317 int flags, 316 int flags,
318 int ioflags) 317 int ioflags)
319{ 318{
320 bhv_vnode_t *vp = XFS_ITOV(ip);
321 xfs_mount_t *mp = ip->i_mount; 319 xfs_mount_t *mp = ip->i_mount;
322 ssize_t ret; 320 ssize_t ret;
323 struct inode *inode = outfilp->f_mapping->host; 321 struct inode *inode = outfilp->f_mapping->host;
@@ -333,7 +331,7 @@ xfs_splice_write(
333 int iolock = XFS_IOLOCK_EXCL; 331 int iolock = XFS_IOLOCK_EXCL;
334 int error; 332 int error;
335 333
336 error = XFS_SEND_DATA(mp, DM_EVENT_WRITE, vp, *ppos, count, 334 error = XFS_SEND_DATA(mp, DM_EVENT_WRITE, ip, *ppos, count,
337 FILP_DELAY_FLAG(outfilp), &iolock); 335 FILP_DELAY_FLAG(outfilp), &iolock);
338 if (error) { 336 if (error) {
339 xfs_iunlock(ip, XFS_IOLOCK_EXCL); 337 xfs_iunlock(ip, XFS_IOLOCK_EXCL);
@@ -631,7 +629,7 @@ start:
631 dmflags |= DM_FLAGS_IMUX; 629 dmflags |= DM_FLAGS_IMUX;
632 630
633 xfs_iunlock(xip, XFS_ILOCK_EXCL); 631 xfs_iunlock(xip, XFS_ILOCK_EXCL);
634 error = XFS_SEND_DATA(xip->i_mount, DM_EVENT_WRITE, vp, 632 error = XFS_SEND_DATA(xip->i_mount, DM_EVENT_WRITE, xip,
635 pos, count, dmflags, &iolock); 633 pos, count, dmflags, &iolock);
636 if (error) { 634 if (error) {
637 goto out_unlock_internal; 635 goto out_unlock_internal;
@@ -778,8 +776,8 @@ retry:
778 xfs_iunlock(xip, iolock); 776 xfs_iunlock(xip, iolock);
779 if (need_i_mutex) 777 if (need_i_mutex)
780 mutex_unlock(&inode->i_mutex); 778 mutex_unlock(&inode->i_mutex);
781 error = XFS_SEND_NAMESP(xip->i_mount, DM_EVENT_NOSPACE, vp, 779 error = XFS_SEND_NAMESP(xip->i_mount, DM_EVENT_NOSPACE, xip,
782 DM_RIGHT_NULL, vp, DM_RIGHT_NULL, NULL, NULL, 780 DM_RIGHT_NULL, xip, DM_RIGHT_NULL, NULL, NULL,
783 0, 0, 0); /* Delay flag intentionally unused */ 781 0, 0, 0); /* Delay flag intentionally unused */
784 if (need_i_mutex) 782 if (need_i_mutex)
785 mutex_lock(&inode->i_mutex); 783 mutex_lock(&inode->i_mutex);