Add patch SR-ext4-resize-mark-new-group-EXT_BG_INODE_ZEROED.patch
[ext4-patch-queue/an.git] / defrag-06a-add-sparse-annotation
blob4bc57735a14c6245219e65ca889200446a4e9b62
1 defrag-06 patch fixup to add sparse annotation
3 From: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
5 This patch hunk was added by
6 aneesh-5-sparse-annotate-the-group-info-semaphore but it doesn't apply
7 until the defrag patches ar applied.  It should be merged up.
9 Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
10 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
11 ---
12 diff a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c    (rejected hunks)
13 --- a/fs/ext4/mballoc.c
14 +++ b/fs/ext4/mballoc.c
15 @@ -4805,8 +4821,10 @@ ext4_mb_search_free_extents(struct inode *inode,
16         end = EXT4_BLOCKS_PER_GROUP(sb) - 1;
18         err = ext4_mb_load_buddy(sb, group_no, &e4b);
19 -       if (err)
20 +       if (err) {
21 +               __release(e4b->alloc_semp);
22                 return err;
23 +       }
25         /* We consider about the boot block if bs = 1k */
26         if (sb->s_blocksize == 1024)