Skip to contentSkip to conversation

: ifdef highmem code

PATCH New Juan Quintela 1 participant 1 message Mar 27, 2003 MIPS

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 : ifdef highmem code

Hi
this patch applies on top of the:

[PATCH]: remove pgd_base

Later, Juan.

ifdef var names & fixrange_init function that are only needed in the CONFIG_HIGHMEM case.

 build/arch/mips/mm/init.c |    4 ++++
 1 files changed, 4 insertions(+)
build/arch/mips/mm/init.c renamed from build/arch/mips/mm/init.c~ifdef_higmem_only_code +4 -0
diff -puN build/arch/mips/mm/init.c~ifdef_higmem_only_code build/arch/mips/mm/init.c
@@ -161,6 +161,7 @@ void show_mem(void)
 extern char _ftext, _etext, _fdata, _edata;
 extern char __init_begin, __init_end;
 
+#ifdef CONFIG_HIGHMEM
 static void __init fixrange_init (unsigned long start, unsigned long end,
 	pgd_t *pgd_base)
 {
@@ -189,13 +190,16 @@ static void __init fixrange_init (unsign
 		j = 0;
 	}
 }
+#endif
 
 void __init pagetable_init(void)
 {
+#ifdef CONFIG_HIGHMEM
 	unsigned long vaddr;
 	pgd_t *pgd;
 	pmd_t *pmd;
 	pte_t *pte;
+#endif
 
 	/* Initialize the entire pgd.  */
 	pgd_init((unsigned long)swapper_pg_dir);

_

Signature · 2 lines
In theory, practice and theory are the same, but in practice they 
are different -- Larry McVoy