[PATCH] kernel-doc for kernel/dma.c
[safe/jmp/linux-2.6] / include / asm-i386 / mmzone.h
index 74f595d..61b0733 100644 (file)
@@ -14,7 +14,7 @@ extern struct pglist_data *node_data[];
 
 #ifdef CONFIG_X86_NUMAQ
        #include <asm/numaq.h>
-#else  /* summit or generic arch */
+#elif defined(CONFIG_ACPI_SRAT)/* summit or generic arch */
        #include <asm/srat.h>
 #endif
 
@@ -38,10 +38,16 @@ static inline void get_memcfg_numa(void)
 }
 
 extern int early_pfn_to_nid(unsigned long pfn);
+extern void numa_kva_reserve(void);
 
 #else /* !CONFIG_NUMA */
+
 #define get_memcfg_numa get_memcfg_numa_flat
 #define get_zholes_size(n) (0)
+
+static inline void numa_kva_reserve(void)
+{
+}
 #endif /* CONFIG_NUMA */
 
 #ifdef CONFIG_DISCONTIGMEM
@@ -70,8 +76,6 @@ static inline int pfn_to_nid(unsigned long pfn)
 #endif
 }
 
-#define node_localnr(pfn, nid)         ((pfn) - node_data[nid]->node_start_pfn)
-
 /*
  * Following are macros that each numa implmentation must define.
  */
@@ -86,21 +90,6 @@ static inline int pfn_to_nid(unsigned long pfn)
 /* XXX: FIXME -- wli */
 #define kern_addr_valid(kaddr) (0)
 
-#define pfn_to_page(pfn)                                               \
-({                                                                     \
-       unsigned long __pfn = pfn;                                      \
-       int __node  = pfn_to_nid(__pfn);                                \
-       &NODE_DATA(__node)->node_mem_map[node_localnr(__pfn,__node)];   \
-})
-
-#define page_to_pfn(pg)                                                        \
-({                                                                     \
-       struct page *__page = pg;                                       \
-       struct zone *__zone = page_zone(__page);                        \
-       (unsigned long)(__page - __zone->zone_mem_map)                  \
-               + __zone->zone_start_pfn;                               \
-})
-
 #ifdef CONFIG_X86_NUMAQ            /* we have contiguous memory on NUMA-Q */
 #define pfn_valid(pfn)          ((pfn) < num_physpages)
 #else