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]
Date:   Fri, 29 Jun 2018 07:33:27 -0700
From:   Fenghua Yu <fenghua.yu@...el.com>
To:     "Thomas Gleixner" <tglx@...utronix.de>,
        "Ingo Molnar" <mingo@...hat.com>, "H Peter Anvin" <hpa@...or.com>
Cc:     "Ashok Raj" <ashok.raj@...el.com>,
        "Alan Cox" <alan@...ux.intel.com>,
        "Dave Hansen" <dave.hansen@...el.com>,
        "Peter Zijlstra" <peterz@...radead.org>,
        "Rafael Wysocki" <rafael.j.wysocki@...el.com>,
        "Tony Luck" <tony.luck@...el.com>,
        "Ravi V Shankar" <ravi.v.shankar@...el.com>,
        "linux-kernel" <linux-kernel@...r.kernel.org>,
        "x86" <x86@...nel.org>, Fenghua Yu <fenghua.yu@...el.com>
Subject: [PATCH v2 4/4] x86/split_lock: Disable #AC for split locked accesses

By default, #AC for split lock is enabled. In some cases (e.g. system
hang when firmware hits split lock), user may want to opt-out of the
feature.

Kernel parameter "ac_split_lock_off" disables the feature during boot time.

Signed-off-by: Fenghua Yu <fenghua.yu@...el.com>
---
 Documentation/admin-guide/kernel-parameters.txt | 4 ++++
 arch/x86/kernel/cpu/test_ctl.c                  | 9 +++++++++
 2 files changed, 13 insertions(+)

diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index efc7aa7a0670..7bf3b37dccdb 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -4086,6 +4086,10 @@
 	spia_pedr=
 	spia_peddr=
 
+	ac_split_lock_off [X86]
+			Disable #AC exception for split locked accesses.
+			By default, this feature is enabled in kernel.
+
 	srcutree.counter_wrap_check [KNL]
 			Specifies how frequently to check for
 			grace-period sequence counter wrap for the
diff --git a/arch/x86/kernel/cpu/test_ctl.c b/arch/x86/kernel/cpu/test_ctl.c
index f12e8b24215d..4e6ed267e8b7 100644
--- a/arch/x86/kernel/cpu/test_ctl.c
+++ b/arch/x86/kernel/cpu/test_ctl.c
@@ -85,3 +85,12 @@ void setup_ac_split_lock(void)
 		pr_info_once("#AC for split lock is disabled\n");
 	}
 }
+
+static __init int ac_split_lock_off(char *str)
+{
+	enable_ac_split_lock = false;
+
+	return 0;
+}
+
+early_param("ac_split_lock_off", ac_split_lock_off);
-- 
2.5.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ