Skip to contentSkip to conversation

page_alloc.c: kill add_from_early_node_map

PATCH In review Kautuk Consul 3 participants 3 messages Mar 13, 2012 – Mar 21, 2012

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 page_alloc.c: kill add_from_early_node_map

No one seems to be calling add_from_early_node_map anywhere from the kernel.

Also, deleting this function decreases page_alloc.o file size.

---
 include/linux/mm.h |    2 --
 mm/page_alloc.c    |   12 ------------
 2 files changed, 0 insertions(+), 14 deletions(-)
include/linux/mm.h +0 -2
index 17b27cd..d8c4339 100644
@@ -1291,8 +1291,6 @@ extern void get_pfn_range_for_nid(unsigned int nid,
 extern unsigned long find_min_pfn_with_active_regions(void);
 extern void free_bootmem_with_active_regions(int nid,
 						unsigned long max_low_pfn);
-int add_from_early_node_map(struct range *range, int az,
-				   int nr_range, int nid);
 extern void sparse_memory_present_with_active_regions(int nid);
 
 #endif /* CONFIG_HAVE_MEMBLOCK_NODE_MAP */
mm/page_alloc.c +0 -12
index a13ded1..3171f4c 100644
@@ -3925,18 +3925,6 @@ void __init free_bootmem_with_active_regions(int nid, unsigned long max_low_pfn)
 	}
 }
 
-int __init add_from_early_node_map(struct range *range, int az,
-				   int nr_range, int nid)
-{
-	unsigned long start_pfn, end_pfn;
-	int i;
-
-	/* need to go over early_node_map to find out good range for node */
-	for_each_mem_pfn_range(i, nid, &start_pfn, &end_pfn, NULL)
-		nr_range = add_range(range, az, nr_range, start_pfn, end_pfn);
-	return nr_range;
-}
-
 /**
  * sparse_memory_present_with_active_regions - Call memory_present for each active range
  * @nid: The node to call memory_present for. If MAX_NUMNODES, all nodes will be used.
Signature · 8 lines
1.7.5.4

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Acked-by on v1 1/2
#1 lore raw
Quoted 6 lines · Kautuk Consul

No one seems to be calling add_from_early_node_map anywhere from the kernel.

Also, deleting this function decreases page_alloc.o file size.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>

Reviewed-by on v1 1/2
#2 lore raw
In reply to Kautuk Consul
Quoted 6 lines · Kautuk Consul

No one seems to be calling add_from_early_node_map anywhere from the kernel.

Also, deleting this function decreases page_alloc.o file size.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>