]> git.ipfire.org Git - thirdparty/kernel/stable.git/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)
committerSasha Levin <alexander.levin@verizon.com>
Thu, 7 Dec 2017 02:20:13 +0000 (21:20 -0500)
commit78d36a51aff258a26c4c2c12c4d86de0fae64e3a
treec52ad92b305f86b94aafea335ae592d4f10263bd
parent76af872c855e1021df82326e20dfc452d25e851c
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>
arch/mips/kernel/setup.c