projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
67954fe
)
mm: optimize pfn calculation in online_page()
author
Daniel Kiper
<
[email protected]
>
Thu, 14 Apr 2011 22:21:53 +0000
(15:21 -0700)
committer
Linus Torvalds
<
[email protected]
>
Thu, 14 Apr 2011 23:06:54 +0000
(16:06 -0700)
If CONFIG_FLATMEM is enabled pfn is calculated in online_page() more than
once. It is possible to optimize that and use value established at
beginning of that function.
Signed-off-by: Daniel Kiper <
[email protected]
>
Acked-by: Dave Hansen <
[email protected]
>
Cc: KAMEZAWA Hiroyuki <
[email protected]
>
Cc: Wu Fengguang <
[email protected]
>
Cc: Mel Gorman <
[email protected]
>
Cc: Christoph Lameter <
[email protected]
>
Acked-by: David Rientjes <
[email protected]
>
Reviewed-by: Jesper Juhl <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
mm/memory_hotplug.c
patch
|
blob
|
history
diff --git
a/mm/memory_hotplug.c
b/mm/memory_hotplug.c
index a2acaf820fe518a98a5e6008690967453fbef7d0..9ca1d604f7cd74aab7a897de22e0784a8c0bcb45 100644
(file)
--- a/
mm/memory_hotplug.c
+++ b/
mm/memory_hotplug.c
@@
-375,7
+375,7
@@
void online_page(struct page *page)
#endif
#ifdef CONFIG_FLATMEM
- max_mapnr = max(p
age_to_pfn(page)
, max_mapnr);
+ max_mapnr = max(p
fn
, max_mapnr);
#endif
ClearPageReserved(page);