diff options
Diffstat (limited to 'recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.25/0016-mm-hugetlb-fix-warning-in-alloc_huge_page-dequeue_hu.patch')
-rw-r--r-- | recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.25/0016-mm-hugetlb-fix-warning-in-alloc_huge_page-dequeue_hu.patch | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.25/0016-mm-hugetlb-fix-warning-in-alloc_huge_page-dequeue_hu.patch b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.25/0016-mm-hugetlb-fix-warning-in-alloc_huge_page-dequeue_hu.patch new file mode 100644 index 00000000..9c4a09a4 --- /dev/null +++ b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.25/0016-mm-hugetlb-fix-warning-in-alloc_huge_page-dequeue_hu.patch | |||
@@ -0,0 +1,50 @@ | |||
1 | From f9871f8705a930f3c3c4588a8c990cf76db2b95e Mon Sep 17 00:00:00 2001 | ||
2 | From: Konstantin Khlebnikov <khlebnikov@openvz.org> | ||
3 | Date: Wed, 25 Apr 2012 16:01:46 -0700 | ||
4 | Subject: [PATCH 16/73] mm/hugetlb: fix warning in | ||
5 | alloc_huge_page/dequeue_huge_page_vma | ||
6 | |||
7 | commit b1c12cbcd0a02527c180a862e8971e249d3b347d upstream. | ||
8 | |||
9 | Stable note: Not tracked in Bugzilla. [get|put]_mems_allowed() is extremely | ||
10 | expensive and severely impacted page allocator performance. This | ||
11 | is part of a series of patches that reduce page allocator overhead. | ||
12 | |||
13 | Fix a gcc warning (and bug?) introduced in cc9a6c877 ("cpuset: mm: reduce | ||
14 | large amounts of memory barrier related damage v3") | ||
15 | |||
16 | Local variable "page" can be uninitialized if the nodemask from vma policy | ||
17 | does not intersects with nodemask from cpuset. Even if it doesn't happens | ||
18 | it is better to initialize this variable explicitly than to introduce | ||
19 | a kernel oops in a weird corner case. | ||
20 | |||
21 | mm/hugetlb.c: In function `alloc_huge_page': | ||
22 | mm/hugetlb.c:1135:5: warning: `page' may be used uninitialized in this function | ||
23 | |||
24 | Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org> | ||
25 | Acked-by: Mel Gorman <mgorman@suse.de> | ||
26 | Acked-by: David Rientjes <rientjes@google.com> | ||
27 | Signed-off-by: Andrew Morton <akpm@linux-foundation.org> | ||
28 | Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> | ||
29 | Signed-off-by: Mel Gorman <mgorman@suse.de> | ||
30 | Signed-off-by: Ben Hutchings <ben@decadent.org.uk> | ||
31 | --- | ||
32 | mm/hugetlb.c | 2 +- | ||
33 | 1 files changed, 1 insertions(+), 1 deletions(-) | ||
34 | |||
35 | diff --git a/mm/hugetlb.c b/mm/hugetlb.c | ||
36 | index 1e747e4..b1e1bad 100644 | ||
37 | --- a/mm/hugetlb.c | ||
38 | +++ b/mm/hugetlb.c | ||
39 | @@ -532,7 +532,7 @@ static struct page *dequeue_huge_page_vma(struct hstate *h, | ||
40 | struct vm_area_struct *vma, | ||
41 | unsigned long address, int avoid_reserve) | ||
42 | { | ||
43 | - struct page *page; | ||
44 | + struct page *page = NULL; | ||
45 | struct mempolicy *mpol; | ||
46 | nodemask_t *nodemask; | ||
47 | struct zonelist *zonelist; | ||
48 | -- | ||
49 | 1.7.7.6 | ||
50 | |||