diff options
author | Nathan Fontenot <nfont@austin.ibm.com> | 2008-10-01 05:44:02 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2008-10-10 00:55:17 -0400 |
commit | 9fd3f88cb67ac51bd5face8441472b91e042be67 (patch) | |
tree | 4579e16f3d1f9504f8320ce973afc9996cd07e39 /arch/powerpc/platforms/pseries | |
parent | 7c12d906f4ef690c65e60111375856640f63a545 (diff) |
powerpc: Oops in pseries_lmb_remove()
Testing hotplug memory remove has revealed that we can oops in
pseries_lmb_remove(). The incorrect shift causes a NULL pointer
dereference in the page_zone() inline routine.
I have only been able to reproduce the oops on kernels with large pages
enabled.
Tested on Power5 and Power6 with and without large pages enabled.
Signed-off-by: Nathan Fontenot <nfont@austin.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/platforms/pseries')
-rw-r--r-- | arch/powerpc/platforms/pseries/hotplug-memory.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/pseries/hotplug-memory.c b/arch/powerpc/platforms/pseries/hotplug-memory.c index a1a368dd2d99..140d02a5232a 100644 --- a/arch/powerpc/platforms/pseries/hotplug-memory.c +++ b/arch/powerpc/platforms/pseries/hotplug-memory.c | |||
@@ -21,7 +21,7 @@ static int pseries_remove_lmb(unsigned long base, unsigned int lmb_size) | |||
21 | struct zone *zone; | 21 | struct zone *zone; |
22 | int ret; | 22 | int ret; |
23 | 23 | ||
24 | start_pfn = base >> PFN_SECTION_SHIFT; | 24 | start_pfn = base >> PAGE_SHIFT; |
25 | zone = page_zone(pfn_to_page(start_pfn)); | 25 | zone = page_zone(pfn_to_page(start_pfn)); |
26 | 26 | ||
27 | /* | 27 | /* |