lkml.org 
[lkml]   [2009]   [Dec]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH 03/25] bootmem: move out map assigning out of loop
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
---
mm/bootmem.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/mm/bootmem.c b/mm/bootmem.c
index 7d14868..8caf744 100644
--- a/mm/bootmem.c
+++ b/mm/bootmem.c
@@ -171,6 +171,7 @@ static unsigned long __init free_all_bootmem_core(bootmem_data_t *bdata)
{
int aligned;
struct page *page;
+ unsigned long *map;
unsigned long start, end, pages, count = 0;

if (!bdata->node_bootmem_map)
@@ -188,10 +189,10 @@ static unsigned long __init free_all_bootmem_core(bootmem_data_t *bdata)
bdebug("nid=%td start=%lx end=%lx aligned=%d\n",
bdata - bootmem_node_data, start, end, aligned);

+ map = bdata->node_bootmem_map;
while (start < end) {
- unsigned long *map, idx, vec;
+ unsigned long idx, vec;

- map = bdata->node_bootmem_map;
idx = start - bdata->node_min_pfn;
vec = ~map[idx / BITS_PER_LONG];

--
1.6.0.2


\
 
 \ /
  Last update: 2009-12-23 00:47    [W:0.089 / U:0.884 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site