Re: [TRIVIAL] fix location of zap_low_mappings

From: Jasper Spaans (
Date: Fri Jun 06 2003 - 09:33:35 EST

On Fri, Jun 06, 2003 at 04:34:43AM -0700, William Lee Irwin III wrote:
> On Fri, Jun 06, 2003 at 11:57:49AM +0200, Jasper Spaans wrote:
> > When compiling current BK 2.5, I get a warning about zap_low_mappings not
> > being declared. Moving it from smp.h to pgtable.h fixes this (and doesn't
> > break my setup).
> > Does anyone object to this fix?

> It's basically not supposed to be visible on UP. Perhaps a better
> approach would be declare it in pgtable.h as you did, stub out the UP
> case with an empty function, and un-#ifdef it from mem_init().

That wouldn't seem right to me:

* in the UP-case, it is explicitly called in mem_init() [mm/init.c]:

void __init mem_init(void)
#ifndef CONFIG_SMP

* in the SMP-case, this call is delayed until
  smp_cpus_done() [kernel/smpboot.c]

These two cases are fine however, as the UP-case defines it in mm/init.c,
and the SMP-case has CONFIG_SMP enabled and includes <smp.h>; the warning
comes from this function being called from acpi_restore_state_mem()
[kernel/acpi/sleep.c]) in the UP-case, in which case it isn't declared in



Jasper Spaans

``Got no clue? Too bad for you.'' - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to More majordomo info at Please read the FAQ at

This archive was generated by hypermail 2b29 : Sat Jun 07 2003 - 22:00:30 EST