Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 365362
b: refs/heads/master
c: 8be6585
h: refs/heads/master
v: v3
  • Loading branch information
Jiang Liu authored and Linus Torvalds committed Apr 29, 2013
1 parent 12dbff1 commit 7d23fc8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 24 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 66f62594216a8df661239e233736997dba074bbe
refs/heads/master: 8be65857f2a4c1f83ef6d2714b7a6428a6fa386c
26 changes: 3 additions & 23 deletions trunk/arch/m32r/mm/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,7 @@
#include <asm/mmu_context.h>
#include <asm/setup.h>
#include <asm/tlb.h>

/* References to section boundaries */
extern char _text, _etext, _edata;
extern char __init_begin, __init_end;
#include <asm/sections.h>

pgd_t swapper_pg_dir[1024];

Expand Down Expand Up @@ -184,17 +181,7 @@ void __init mem_init(void)
*======================================================================*/
void free_initmem(void)
{
unsigned long addr;

addr = (unsigned long)(&__init_begin);
for (; addr < (unsigned long)(&__init_end); addr += PAGE_SIZE) {
ClearPageReserved(virt_to_page(addr));
init_page_count(virt_to_page(addr));
free_page(addr);
totalram_pages++;
}
printk (KERN_INFO "Freeing unused kernel memory: %dk freed\n", \
(int)(&__init_end - &__init_begin) >> 10);
free_initmem_default(0);
}

#ifdef CONFIG_BLK_DEV_INITRD
Expand All @@ -204,13 +191,6 @@ void free_initmem(void)
*======================================================================*/
void free_initrd_mem(unsigned long start, unsigned long end)
{
unsigned long p;
for (p = start; p < end; p += PAGE_SIZE) {
ClearPageReserved(virt_to_page(p));
init_page_count(virt_to_page(p));
free_page(p);
totalram_pages++;
}
printk (KERN_INFO "Freeing initrd memory: %ldk freed\n", (end - start) >> 10);
free_reserved_area(start, end, 0, "initrd");
}
#endif

0 comments on commit 7d23fc8

Please sign in to comment.