X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=fs%2Fext4%2Finode.c;h=4d78342f3bf07ec61dbe8346eef88706aa5abebb;hb=81a6cff678ecee7cdc0658285d3150660c07cfce;hp=2d6c6c8c036df496f0b44e549d800d26494abdef;hpb=e4c5bf8e3dca827a1b3a6fac494eae8c74b7e1e7;p=firefly-linux-kernel-4.4.55.git diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index 2d6c6c8c036d..4d78342f3bf0 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -2718,7 +2718,7 @@ static int ext4_writepage(struct page *page, * try to create them using __block_write_begin. If this * fails, redirty the page and move on. */ - if (!page_buffers(page)) { + if (!page_has_buffers(page)) { if (__block_write_begin(page, 0, len, noalloc_get_block_write)) { redirty_page: @@ -2732,12 +2732,10 @@ static int ext4_writepage(struct page *page, if (walk_page_buffers(NULL, page_bufs, 0, len, NULL, ext4_bh_delay_or_unwritten)) { /* - * We don't want to do block allocation So redirty the - * page and return We may reach here when we do a - * journal commit via - * journal_submit_inode_data_buffers. If we don't - * have mapping block we just ignore them. We can also - * reach here via shrink_page_list + * We don't want to do block allocation, so redirty + * the page and return. We may reach here when we do + * a journal commit via journal_submit_inode_data_buffers. + * We can also reach here via shrink_page_list */ goto redirty_page; } @@ -5412,9 +5410,7 @@ int ext4_getattr(struct vfsmount *mnt, struct dentry *dentry, * will return the blocks that include the delayed allocation * blocks for this file. */ - spin_lock(&EXT4_I(inode)->i_block_reservation_lock); delalloc_blocks = EXT4_I(inode)->i_reserved_data_blocks; - spin_unlock(&EXT4_I(inode)->i_block_reservation_lock); stat->blocks += (delalloc_blocks << inode->i_sb->s_blocksize_bits)>>9; return 0;