mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
[PATCH] fix WANT_PAGE_VIRTUAL in memmap_init
I spotted this issue while in memmap_init last week. I can't say the change has any test coverage by me. start_pfn was formerly used in main "for" loop. The fix is replace start_pfn with pfn. Signed-off-by: Bob Picco <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
9c4142a133
commit
3212c6be25
1 changed files with 1 additions and 2 deletions
|
|
@ -1667,9 +1667,8 @@ void __init memmap_init_zone(unsigned long size, int nid, unsigned long zone,
|
|||
#ifdef WANT_PAGE_VIRTUAL
|
||||
/* The shift won't overflow because ZONE_NORMAL is below 4G. */
|
||||
if (!is_highmem_idx(zone))
|
||||
set_page_address(page, __va(start_pfn << PAGE_SHIFT));
|
||||
set_page_address(page, __va(pfn << PAGE_SHIFT));
|
||||
#endif
|
||||
start_pfn++;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue