ceph: cleanup async writeback, truncation, invalidate helpers
Grab inode ref in helper. Make work functions static, with consistent
naming.
Signed-off-by: Sage Weil <sage@newdream.net>
diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c
index 89c5ff3..71f5ad1 100644
--- a/fs/ceph/addr.c
+++ b/fs/ceph/addr.c
@@ -947,8 +947,7 @@
*/
snapc = ceph_get_snap_context((void *)page->private);
unlock_page(page);
- if (ceph_queue_writeback(inode))
- igrab(inode);
+ ceph_queue_writeback(inode);
wait_event_interruptible(ci->i_cap_wq,
context_is_writeable_or_written(inode, snapc));
ceph_put_snap_context(snapc);