ocfs2: Fix extent lookup to return true size of holes
[deliverable/linux.git] / fs / ocfs2 / journal.c
index 825cb0ae1b4c812862bbff0d8da5608497611eb7..12d2340eee29ebf1761c2ed93df6ebe3bebd435c 100644 (file)
@@ -649,9 +649,9 @@ bail:
 static int ocfs2_force_read_journal(struct inode *inode)
 {
        int status = 0;
-       int i, p_blocks;
-       u64 v_blkno, p_blkno;
-#define CONCURRENT_JOURNAL_FILL 32
+       int i;
+       u64 v_blkno, p_blkno, p_blocks;
+#define CONCURRENT_JOURNAL_FILL 32ULL
        struct buffer_head *bhs[CONCURRENT_JOURNAL_FILL];
 
        mlog_entry_void();
@@ -670,8 +670,7 @@ static int ocfs2_force_read_journal(struct inode *inode)
               (inode->i_blocks >> (inode->i_sb->s_blocksize_bits - 9))) {
 
                status = ocfs2_extent_map_get_blocks(inode, v_blkno,
-                                                    1, &p_blkno,
-                                                    &p_blocks);
+                                                    &p_blkno, &p_blocks, NULL);
                if (status < 0) {
                        mlog_errno(status);
                        goto bail;
@@ -1306,7 +1305,7 @@ static int ocfs2_queue_orphans(struct ocfs2_super *osb,
                                continue;
 
                        iter = ocfs2_iget(osb, le64_to_cpu(de->inode),
-                                         OCFS2_FI_FLAG_NOLOCK);
+                                         OCFS2_FI_FLAG_ORPHAN_RECOVERY);
                        if (IS_ERR(iter))
                                continue;
 
@@ -1418,7 +1417,6 @@ static int ocfs2_recover_orphans(struct ocfs2_super *osb,
                /* Set the proper information to get us going into
                 * ocfs2_delete_inode. */
                oi->ip_flags |= OCFS2_INODE_MAYBE_ORPHANED;
-               oi->ip_orphaned_slot = slot;
                spin_unlock(&oi->ip_lock);
 
                iput(inode);
This page took 0.029915 seconds and 5 git commands to generate.