aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mm
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@stericsson.com>2010-05-26 02:37:57 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2010-05-27 05:36:07 -0400
commitea208f646c8fb91c39c852e952fc911e1ad045ab (patch)
treebf4cd875b052996eb13dd30a66647334082b28a2 /arch/arm/mm
parent138de1c44a8e0606501cd8593407e9248e84f1b7 (diff)
ARM: 6144/1: TCM memory bug freeing bug
This fixes a bug in mm/init.c when freeing the TCM compile memory, this was being referred to as a char * which is incorrect: this will dereference the pointer and feed in the value at the location instead of the address to it. Change it to a plain char and use &(char) to reference it. Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> Cc: <stable@kernel.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mm')
-rw-r--r--arch/arm/mm/init.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/arm/mm/init.c b/arch/arm/mm/init.c
index 1ba6cf5a2c02..f6a999465323 100644
--- a/arch/arm/mm/init.c
+++ b/arch/arm/mm/init.c
@@ -678,10 +678,10 @@ void __init mem_init(void)
678void free_initmem(void) 678void free_initmem(void)
679{ 679{
680#ifdef CONFIG_HAVE_TCM 680#ifdef CONFIG_HAVE_TCM
681 extern char *__tcm_start, *__tcm_end; 681 extern char __tcm_start, __tcm_end;
682 682
683 totalram_pages += free_area(__phys_to_pfn(__pa(__tcm_start)), 683 totalram_pages += free_area(__phys_to_pfn(__pa(&__tcm_start)),
684 __phys_to_pfn(__pa(__tcm_end)), 684 __phys_to_pfn(__pa(&__tcm_end)),
685 "TCM link"); 685 "TCM link");
686#endif 686#endif
687 687