]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: partially revert "ARM: 8167/1: extend the reserved memory for initrd to be...
authorCatalin Marinas <catalin.marinas@arm.com>
Fri, 16 Jan 2015 13:56:38 +0000 (13:56 +0000)
committerWill Deacon <will.deacon@arm.com>
Fri, 16 Jan 2015 13:57:33 +0000 (13:57 +0000)
commitf38b7f426b309f371cd1c6fd3e5b68e4daa1a8b8
tree196c3c624f432c0e4f31153c6d6f8b7c38ed3077
parentb0d4eec7f0ac87eea9f8e9af7b75d143e16f6949
arm64: partially revert "ARM: 8167/1: extend the reserved memory for initrd to be page aligned"

This patch partially reverts commit 9368232189d4c6319e410b5d7f2dd23ff1406ac7
(only the arm64 part). There is no guarantee that the boot-loader places other
images like dtb in a different page than initrd start/end, especially when the
kernel is built with 64KB pages. When this happens, such pages must not be
freed. The free_reserved_area() already takes care of rounding up "start" and
rounding down "end" to avoid freeing partially used pages.

Cc: <stable@vger.kernel.org> # 3.17+
Reported-by: Peter Maydell <Peter.Maydell@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/mm/init.c