summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorAndrew Morton <akpm@zip.com.au>2002-09-03 05:34:07 -0700
committerLinus Torvalds <torvalds@home.transmeta.com>2002-09-03 05:34:07 -0700
commit0d0bdc8e6f1cbfddd68f9912666251396ee47142 (patch)
treefa0cbd8b7c88287aa0e15570a8dfc63975f0df15 /include/linux
parent6db13e2bf417233d26da6fda60d15a1abe972c61 (diff)
[PATCH] discontigmem support for ia32 NUMA
- All the support macros which assume a linear mem_map[] have been wrapped in !CONFIG_DISCONTIGMEM. pfn_to_page, page_to_pfn, page_to_phys, pmd_page, kern_addr_valid. - Move some initialsation macros into setup.h so they can be used in the i386 discontig.c (INITRD_START, INITRD_SIZE). - Alternate version of the bootmem allocator - add i386 discontig support and numaq support.
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/bootmem.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/linux/bootmem.h b/include/linux/bootmem.h
index 3bd68c042514..782041f43326 100644
--- a/include/linux/bootmem.h
+++ b/include/linux/bootmem.h
@@ -36,9 +36,10 @@ typedef struct bootmem_data {
extern unsigned long __init bootmem_bootmap_pages (unsigned long);
extern unsigned long __init init_bootmem (unsigned long addr, unsigned long memend);
-extern void __init reserve_bootmem (unsigned long addr, unsigned long size);
extern void __init free_bootmem (unsigned long addr, unsigned long size);
extern void * __init __alloc_bootmem (unsigned long size, unsigned long align, unsigned long goal);
+#ifndef CONFIG_HAVE_ARCH_BOOTMEM_NODE
+extern void __init reserve_bootmem (unsigned long addr, unsigned long size);
#define alloc_bootmem(x) \
__alloc_bootmem((x), SMP_CACHE_BYTES, __pa(MAX_DMA_ADDRESS))
#define alloc_bootmem_low(x) \
@@ -47,6 +48,7 @@ extern void * __init __alloc_bootmem (unsigned long size, unsigned long align, u
__alloc_bootmem((x), PAGE_SIZE, __pa(MAX_DMA_ADDRESS))
#define alloc_bootmem_low_pages(x) \
__alloc_bootmem((x), PAGE_SIZE, 0)
+#endif /* !CONFIG_HAVE_ARCH_BOOTMEM_NODE */
extern unsigned long __init free_all_bootmem (void);
extern unsigned long __init init_bootmem_node (pg_data_t *pgdat, unsigned long freepfn, unsigned long startpfn, unsigned long endpfn);
@@ -54,11 +56,13 @@ extern void __init reserve_bootmem_node (pg_data_t *pgdat, unsigned long physadd
extern void __init free_bootmem_node (pg_data_t *pgdat, unsigned long addr, unsigned long size);
extern unsigned long __init free_all_bootmem_node (pg_data_t *pgdat);
extern void * __init __alloc_bootmem_node (pg_data_t *pgdat, unsigned long size, unsigned long align, unsigned long goal);
+#ifndef CONFIG_HAVE_ARCH_BOOTMEM_NODE
#define alloc_bootmem_node(pgdat, x) \
__alloc_bootmem_node((pgdat), (x), SMP_CACHE_BYTES, __pa(MAX_DMA_ADDRESS))
#define alloc_bootmem_pages_node(pgdat, x) \
__alloc_bootmem_node((pgdat), (x), PAGE_SIZE, __pa(MAX_DMA_ADDRESS))
#define alloc_bootmem_low_pages_node(pgdat, x) \
__alloc_bootmem_node((pgdat), (x), PAGE_SIZE, 0)
+#endif /* !CONFIG_HAVE_ARCH_BOOTMEM_NODE */
#endif /* _LINUX_BOOTMEM_H */