]> www.infradead.org Git - users/dwmw2/linux.git/commit
powerpc/32: Disable KASAN with pages bigger than 16k
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Thu, 28 May 2020 10:17:04 +0000 (10:17 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 22 Jun 2020 07:33:07 +0000 (09:33 +0200)
commit32a65dcf6910a6b8f5544ebf86b2ae27b8ca0fdc
treedc97084f3f6eef47c81cddf0e54e4f5638270005
parentd7c98b30124914727d147da691bc15d31a8859cb
powerpc/32: Disable KASAN with pages bigger than 16k

commit 888468ce725a4cd56d72dc7e5096078f7a9251a0 upstream.

Mapping of early shadow area is implemented by using a single static
page table having all entries pointing to the same early shadow page.
The shadow area must therefore occupy full PGD entries.

The shadow area has a size of 128MB starting at 0xf8000000.
With 4k pages, a PGD entry is 4MB
With 16k pages, a PGD entry is 64MB
With 64k pages, a PGD entry is 1GB which is too big.

Until we rework the early shadow mapping, disable KASAN when the page
size is too big.

Fixes: 2edb16efc899 ("powerpc/32: Add KASAN support")
Cc: stable@vger.kernel.org # v5.2+
Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/7195fcde7314ccbf7a081b356084a69d421b10d4.1590660977.git.christophe.leroy@csgroup.eu
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/powerpc/Kconfig