]> git.hungrycats.org Git - linux/commit
MIPS: init: Ensure bootmem does not corrupt reserved memory
authorMarcin Nowakowski <marcin.nowakowski@imgtec.com>
Wed, 23 Nov 2016 13:43:45 +0000 (14:43 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 21 Nov 2017 08:21:22 +0000 (09:21 +0100)
commit034347aca034d8c2edd54ed8f6c67753ab2741be
tree8a0681124fa15b28f371c198a462d7f205adf1dd
parenta904ebe92a05dd86517b93bad062076e38890788
MIPS: init: Ensure bootmem does not corrupt reserved memory

[ Upstream commit d9b5b658210f28ed9f70c757d553e679d76e2986 ]

Current init code initialises bootmem allocator with all of the low
memory that it assumes is available, but does not check for reserved
memory block, which can lead to corruption of data that may be stored
there.
Move bootmem's allocation map to a location that does not cross any
reserved regions

Signed-off-by: Marcin Nowakowski <marcin.nowakowski@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/14609/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/mips/kernel/setup.c