lkml.org 
[lkml]   [2012]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[34-longterm 013/179] ext4: release page cache in ext4_mb_load_buddy error path
    Date
    From: Yang Ruirui <ruirui.r.yang@tieto.com>

    -------------------
    This is a commit scheduled for the next v2.6.34 longterm release.
    http://git.kernel.org/?p=linux/kernel/git/paulg/longterm-queue-2.6.34.git
    If you see a problem with using this for longterm, please comment.
    -------------------

    commit 26626f1172fb4f3f323239a6a5cf4e082643fa46 upstream.

    Add missing page_cache_release in the error path of ext4_mb_load_buddy

    Signed-off-by: Yang Ruirui <ruirui.r.yang@tieto.com>
    Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
    Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
    ---
    fs/ext4/mballoc.c | 2 ++
    1 file changed, 2 insertions(+)

    diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c
    index 917fe78..f1c9a84 100644
    --- a/fs/ext4/mballoc.c
    +++ b/fs/ext4/mballoc.c
    @@ -1173,6 +1173,8 @@ repeat_load_buddy:
    return 0;

    err:
    + if (page)
    + page_cache_release(page);
    if (e4b->bd_bitmap_page)
    page_cache_release(e4b->bd_bitmap_page);
    if (e4b->bd_buddy_page)
    --
    1.7.9.6


    \
     
     \ /
      Last update: 2012-05-15 07:02    [W:0.023 / U:33.588 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site