From: Ard Biesheuvel <ardb@kernel.org>
To: linux-arm-kernel@lists.infradead.org
Cc: catalin.marinas@arm.com, will@kernel.org, mark.rutland@arm.com,
Ard Biesheuvel <ardb@kernel.org>,
Kefeng Wang <wangkefeng.wang@huawei.com>
Subject: [PATCH 0/2] arm64: permit KASLR in linear region even VArange == PArange
Date: Wed, 15 Dec 2021 15:52:26 +0100 [thread overview]
Message-ID: <20211215145228.953702-1-ardb@kernel.org> (raw)
Kefeng reports in [0] that using PArange to size the randomized linear
region offset leads to cases where randomization is no longer possible
even if the actual placement of DRAM in memory would otherwise have
permitted it.
Instead of using CONFIG_MEMORY_HOTPLUG to choose at build time between
to different behaviors in this regard, let's try addressing this by
reducing the minimum relative aligment between VA and PA in the linear
region, and taking advantage of the space at the base of physical memory
below the first memblock to permit some randomization of the placement
of physical DRAM in the virtual address map.
Cc: Kefeng Wang <wangkefeng.wang@huawei.com>
[0] https://lore.kernel.org/linux-arm-kernel/20211104062747.55206-1-wangkefeng.wang@huawei.com/
Ard Biesheuvel (2):
arm64: simplify rules for defining ARM64_MEMSTART_ALIGN
arm64: kaslr: take free space at start of DRAM into account
arch/arm64/include/asm/kernel-pgtable.h | 27 +++-----------------
arch/arm64/mm/init.c | 3 ++-
2 files changed, 6 insertions(+), 24 deletions(-)
--
2.30.2
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next reply other threads:[~2021-12-15 14:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-15 14:52 Ard Biesheuvel [this message]
2021-12-15 14:52 ` [PATCH 1/2] arm64: simplify rules for defining ARM64_MEMSTART_ALIGN Ard Biesheuvel
2021-12-15 14:52 ` [PATCH 2/2] arm64: kaslr: take free space at start of DRAM into account Ard Biesheuvel
2021-12-16 7:37 ` [PATCH 0/2] arm64: permit KASLR in linear region even VArange == PArange Kefeng Wang
2021-12-16 8:56 ` Ard Biesheuvel
2021-12-16 11:32 ` Kefeng Wang
2022-02-15 2:09 ` Kefeng Wang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211215145228.953702-1-ardb@kernel.org \
--to=ardb@kernel.org \
--cc=catalin.marinas@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=mark.rutland@arm.com \
--cc=wangkefeng.wang@huawei.com \
--cc=will@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.