]> git.baikalelectronics.ru Git - kernel.git/commit
[POWERPC] 85xx: Failure with odd memory sizes and CONFIG_HIGHMEM
authorDale Farnsworth <dale@farnsworth.org>
Wed, 3 Oct 2007 19:01:40 +0000 (12:01 -0700)
committerKumar Gala <galak@kernel.crashing.org>
Mon, 8 Oct 2007 13:38:34 +0000 (08:38 -0500)
commit92ec64403eef2336c877d9121f685e6b1348ec43
tree315a5dab9ff34a0f7a21dce093eb9687852c5a1a
parentdd4d9b4b9a6e582bfc626cbc29b5e228e76db166
[POWERPC] 85xx: Failure with odd memory sizes and CONFIG_HIGHMEM

The CONFIG_FSL_BOOKE mmu setup code fails when CONFIG_HIGHMEM=y
and the 3 fixed TLB entries cannot exactly map the lowmem size.
Each TLB entry can map 4MB, 16MB, 64MB or 256MB, so the failure
is observed when the kernel lowmem size is not equal to the
sum of up to 3 of those values.

Normally, memory is sized in nice numbers, but I observed this
problem while testing a crash dump kernel.  The failure can
also be observed by artificially reducing the kernel's main
memory via the mem= kernel command line parameter.

This commit fixes the problem by setting __initial_memory_limit
in adjust_total_lowmem().

Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
arch/powerpc/mm/fsl_booke_mmu.c