From a9af8932758ab714e632cfbb65a45c38cac0bd67 Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Fri, 27 May 2011 17:45:22 -0700 Subject: [PATCH] core: fix warnings in core/mem/init.c Fix warnings (that block -Werror) in core/mem/init.c Signed-off-by: H. Peter Anvin --- core/mem/init.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/core/mem/init.c b/core/mem/init.c index 4ee2541..2951bb0 100644 --- a/core/mem/init.c +++ b/core/mem/init.c @@ -1,10 +1,8 @@ #include #include #include -#include #include "malloc.h" - -#include +#include "core.h" #include struct free_arena_header __core_malloc_head[NHEAP]; @@ -19,6 +17,8 @@ int scan_highmem_area(void *data, addr_t start, addr_t len, bool is_ram) struct free_arena_header *fp; addr_t end; + (void)data; + dprintf("start = %x, len = %x, is_ram = %d", start, len, is_ram); if (start < 0x100000 || start > E820_MEM_MAX @@ -45,11 +45,11 @@ int scan_highmem_area(void *data, addr_t start, addr_t len, bool is_ram) return 0; } +#if 0 static void mpool_dump(enum heap heap) { struct free_arena_header *head = &__core_malloc_head[heap]; struct free_arena_header *fp; - void *p = NULL; int size, type, i = 0; addr_t start, end; @@ -64,6 +64,7 @@ static void mpool_dump(enum heap heap) fp = fp->next_free; } } +#endif void mem_init(void) { @@ -92,7 +93,6 @@ void mem_init(void) __inject_free_block(fp); /* Initialize the main heap */ - __com32.cs_memsize = free_high_memory; + __com32.cs_memsize = (size_t)free_high_memory; syslinux_scan_memory(scan_highmem_area, NULL); - } -- 2.7.4