lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251029034554.1839-1-shechenglong@xfusion.com>
Date: Wed, 29 Oct 2025 11:45:52 +0800
From: shechenglong <shechenglong@...sion.com>
To: <mark.rutland@....com>, <catalin.marinas@....com>, <will@...nel.org>
CC: <linux-arm-kernel@...ts.infradead.org>, <linux-kernel@...r.kernel.org>,
	<stone.xulei@...sion.com>, <chenjialong@...sion.com>, <yuxiating@...sion.com>
Subject: [RESEND v2 0/2] arm64: spectre: Fix hard lockup and cleanup mitigation messages

On Wed, Sep 24, 2025 at 08:32:47PM +0800, shechenglong wrote:
> relocate the printk() calls from spectre_v4_mitigations_off() and
> spectre_v2_mitigations_off() into setup_system_capabilities() 
> function, preventing hard lockups that occur when printk() is invoked from scheduler context.
> 
> Link: 
> https://patchwork.kernel.org/project/linux-arm-kernel/patch/2025091806
> 4907.1832-1-shechenglong@...sion.com/
> Suggested-by: Mark Rutland <mark.rutland@....com>
> Suggested-by: Catalin Marinas <catalin.marinas@....com>
> Signed-off-by: shechenglong <shechenglong@...sion.com>

Thanks for the review and suggestions, Will!

This v2 series addresses your comments:
- Fixed the message to use "command-line" consistently
- Created spectre_print_disabled_mitigations() function to handle all spectre mitigation messages
- Added a separate patch to remove the CONFIG_MITIGATE_SPECTRE_BHB option

The series includes two patches:

Patch 1: "fix hard lockup triggered by printk calls within scheduling context"
- Moves printk calls from scheduler context to setup_system_capabilities()
- Prevents hard lockups by avoiding printk in unsafe contexts
- Consolidates spectre mitigation status reporting

Patch 2: "Remove the print when the CONFIG_MITIGATE_SPECTRE_BRANCH_HISTORY Kconfig option is disabled"
- Removes the obsolete CONFIG_MITIGATE_SPECTRE_BHB Kconfig option
- Cleans up the spectre mitigation code as suggested

shechenglong (2):
  arm64: spectre: fix hard lockup triggered by printk calls within scheduling context
  arm64: spectre: Remove the print when the CONFIG_MITIGATE_SPECTRE_BRANCH_HISTORY Kconfig option is disabled

 arch/arm64/include/asm/spectre.h |  2 ++
 arch/arm64/kernel/cpufeature.c   |  7 ++++++-
 arch/arm64/kernel/proton-pack.c  | 28 ++++++++++++++--------------
 3 files changed, 22 insertions(+), 17 deletions(-)

-- 
2.25.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ