summaryrefslogtreecommitdiffstats
path: root/drivers/iio
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2020-07-09 15:59:53 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-07-22 09:22:21 +0200
commitf29d784d4d6e65d8bc5b6608e09437ce59822474 (patch)
treeb719da58e94df32e025be609bcaa585c9c9cf93c /drivers/iio
parent072c638a2eb363d767c8bea1b9559ac0bdb389cf (diff)
downloadlinux-stable-f29d784d4d6e65d8bc5b6608e09437ce59822474.tar.gz
linux-stable-f29d784d4d6e65d8bc5b6608e09437ce59822474.tar.bz2
linux-stable-f29d784d4d6e65d8bc5b6608e09437ce59822474.zip
arm64/alternatives: don't patch up internal branches
[ Upstream commit 5679b28142193a62f6af93249c0477be9f0c669b ] Commit f7b93d42945c ("arm64/alternatives: use subsections for replacement sequences") moved the alternatives replacement sequences into subsections, in order to keep the as close as possible to the code that they replace. Unfortunately, this broke the logic in branch_insn_requires_update, which assumed that any branch into kernel executable code was a branch that required updating, which is no longer the case now that the code sequences that are patched in are in the same section as the patch site itself. So the only way to discriminate branches that require updating and ones that don't is to check whether the branch targets the replacement sequence itself, and so we can drop the call to kernel_text_address() entirely. Fixes: f7b93d42945c ("arm64/alternatives: use subsections for replacement sequences") Reported-by: Alexandru Elisei <alexandru.elisei@arm.com> Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Tested-by: Alexandru Elisei <alexandru.elisei@arm.com> Link: https://lore.kernel.org/r/20200709125953.30918-1-ardb@kernel.org Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/iio')
0 files changed, 0 insertions, 0 deletions