patch-2.4.6 linux/fs/reiserfs/fix_node.c

Next file: linux/fs/reiserfs/inode.c
Previous file: linux/fs/reiserfs/dir.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.5/linux/fs/reiserfs/fix_node.c linux/fs/reiserfs/fix_node.c
@@ -936,6 +936,7 @@
     if (p_s_tb->FEB[p_s_tb->cur_blknum])
       BUG();
 
+    mark_buffer_journal_new(p_s_new_bh) ;
     p_s_tb->FEB[p_s_tb->cur_blknum++] = p_s_new_bh;
   }
 
@@ -2249,7 +2250,7 @@
                dcache shrinking). So, release path and collected
                resourses here */
 	    free_buffers_in_tb (tb);
-	    buf = reiserfs_kmalloc(size, GFP_BUFFER, tb->tb_sb);
+	    buf = reiserfs_kmalloc(size, GFP_NOFS, tb->tb_sb);
 	    if ( !buf ) {
 #ifdef CONFIG_REISERFS_CHECK
 		reiserfs_warning ("vs-8345: get_mem_for_virtual_node: "
@@ -2719,12 +2720,6 @@
 {
     int	i;
 
-#ifdef CONFIG_REISERFS_CHECK
-    if ( ! tb->vn_buf )
-	reiserfs_panic (tb->tb_sb,
-			"PAP-16050: unfix_nodes: pointer to the virtual node is NULL");
-#endif
-
     /* Release path buffers. */
     pathrelse_and_restore (tb->tb_sb, tb->tb_path);
 
@@ -2781,7 +2776,8 @@
 	    }
 	}
 #endif /* 0 */
-    reiserfs_kfree (tb->vn_buf, tb->vn_buf_size, tb->tb_sb);
+    if (tb->vn_buf) 
+	reiserfs_kfree (tb->vn_buf, tb->vn_buf_size, tb->tb_sb);
 
 } 
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)