Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b0f40ea0 authored by Matthew Wilcox's avatar Matthew Wilcox Committed by Tony Luck
Browse files

[IA64] Fix DISCONTIGMEM without VIRTUAL_MEM_MAP



make allnoconfig currently fails to build because it selects DISCONTIGMEM
without VIRTUAL_MEM_MAP.  I see no particular reason this combination
ought to fail, so I fixed it by:

 - Including memory_model.h in all circumstances, except when both
   DISCONTIGMEM and VIRTUAL_MEM_MAP are enabled.
 - Defining ia64_pfn_valid() to 1 unless VIRTUAL_MEM_MAP is enabled

Signed-off-by: default avatarMatthew Wilcox <matthew@wil.cx>
Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
parent 17e77b1c
Loading
Loading
Loading
Loading
+5 −6
Original line number Diff line number Diff line
@@ -101,7 +101,7 @@ do { \

#ifdef CONFIG_VIRTUAL_MEM_MAP
extern int ia64_pfn_valid (unsigned long pfn);
#elif defined(CONFIG_FLATMEM)
#else
# define ia64_pfn_valid(pfn) 1
#endif

@@ -110,11 +110,10 @@ extern struct page *vmem_map;
#ifdef CONFIG_DISCONTIGMEM
# define page_to_pfn(page)	((unsigned long) (page - vmem_map))
# define pfn_to_page(pfn)	(vmem_map + (pfn))
#else
# include <asm-generic/memory_model.h>
#endif
#endif

#if defined(CONFIG_FLATMEM) || defined(CONFIG_SPARSEMEM)
/* FLATMEM always configures mem_map (mem_map = vmem_map if necessary) */
#else
# include <asm-generic/memory_model.h>
#endif