]> Pileus Git - ~andy/linux/blobdiff - fs/buffer.c
Merge branch 'for-2.6.31' of git://git.kernel.dk/linux-2.6-block
[~andy/linux] / fs / buffer.c
index 36e2bbc60ec75332cd0417aedc42f52b6e8c53f4..a3ef091a45bd4664e5ba5e683f9329bda3d1d3df 100644 (file)
@@ -2736,6 +2736,8 @@ has_buffers:
                pos += blocksize;
        }
 
+       map_bh.b_size = blocksize;
+       map_bh.b_state = 0;
        err = get_block(inode, iblock, &map_bh, 0);
        if (err)
                goto unlock;
@@ -2933,6 +2935,8 @@ int submit_bh(int rw, struct buffer_head * bh)
        BUG_ON(!buffer_locked(bh));
        BUG_ON(!buffer_mapped(bh));
        BUG_ON(!bh->b_end_io);
+       BUG_ON(buffer_delay(bh));
+       BUG_ON(buffer_unwritten(bh));
 
        /*
         * Mask in barrier bit for a write (could be either a WRITE or a