]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
x86/bugs: Avoid warning when overriding return thunk
authorPawan Gupta <pawan.kumar.gupta@linux.intel.com>
Wed, 11 Jun 2025 17:29:31 +0000 (10:29 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 28 Aug 2025 14:25:54 +0000 (16:25 +0200)
commita37fdf1d998abff0770ddc25836908cf311814e9
tree05cdc0a44f679fcb3e28cffaee8ff8ef9bef8f10
parenta574240178f6bebd5a1538a1442c9c2e3cc85c52
x86/bugs: Avoid warning when overriding return thunk

[ Upstream commit 9f85fdb9fc5a1bd308a10a0a7d7e34f2712ba58b ]

The purpose of the warning is to prevent an unexpected change to the return
thunk mitigation. However, there are legitimate cases where the return
thunk is intentionally set more than once. For example, ITS and SRSO both
can set the return thunk after retbleed has set it. In both the cases
retbleed is still mitigated.

Replace the warning with an info about the active return thunk.

Suggested-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://lore.kernel.org/20250611-eibrs-fix-v4-3-5ff86cac6c61@linux.intel.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/x86/kernel/cpu/bugs.c