linux/arch
Tejun Heo d0c4f57027 bootmem, x86: further fixes for arch-specific bootmem wrapping
Impact: fix new breakages introduced by previous fix

Commit c132937556 tried to clean up
bootmem arch wrapper but it wasn't quite correct.  Before the commit,
the followings were broken.

* Low level interface functions prefixed with __ ignored arch
  preference.

* reserve_bootmem(...) can't be mapped into
  reserve_bootmem_node(NODE_DATA(0)->bdata, ...) because the node is
  not preference here.  The region specified MUST fall into the
  specified region; otherwise, it will panic.

After the commit,

* If allocation fails for the arch preferred node, it should fallback
  to whatever is available.  Instead, it simply failed allocation.

There are too many internal details to allow generic wrapping and
still keep things simple for archs.  Plus, all that arch wants is a
way to prefer certain node over another.

This patch drops the generic wrapping around alloc_bootmem_core() and
add alloc_bootmem_core() instead.  If necessary, arch can define
bootmem_arch_referred_node() macro or function which takes all
allocation information and returns the preferred node.  bootmem
generic code will always try the preferred node first and then
fallback to other nodes as usual.

Breakages noted and changes reviewed by Johannes Weiner.

Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
2009-03-01 16:06:56 +09:00
..
alpha alpha: fix typo in recent early vmalloc change 2009-03-01 16:03:16 +09:00
arm Merge branch 'linus' into x86/apic 2009-02-22 20:05:19 +01:00
avr32 Merge branch 'tj-percpu' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/misc into core/percpu 2009-02-24 21:52:45 +01:00
blackfin
cris
frv
h8300
ia64 Merge branch 'linus' into x86/apic 2009-02-22 20:05:19 +01:00
m32r
m68k m68k: atari - Rename "mfp" to "st_mfp" 2009-02-22 09:23:02 -08:00
m68knommu
mips
mn10300 Merge branch 'linus' into x86/apic 2009-02-22 20:05:19 +01:00
parisc
powerpc Merge branch 'linus' into x86/apic 2009-02-22 20:05:19 +01:00
s390 [S390] fix "mem=" handling in case of standby memory 2009-02-19 15:19:19 +01:00
sh
sparc
um uml: fix vde network backend in user mode linux 2009-02-20 17:57:48 -08:00
x86 bootmem, x86: further fixes for arch-specific bootmem wrapping 2009-03-01 16:06:56 +09:00
xtensa
.gitignore
Kconfig