Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1374546

[PATCH v5 10/14] x86/cpu/intel: remove not needed paravirt_enabled() for f00f work around

From "Luis R. Rodriguez" <mcgrof@kernel.org>
Newsgroups linux.kernel
Subject [PATCH v5 10/14] x86/cpu/intel: remove not needed paravirt_enabled() for f00f work around
Date 2016-04-09 02:00 +0200
Message-ID <rlOtH-4rd-3@gated-at.bofh.it> (permalink)
References <rlOk2-4h2-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


The X86_BUG_F00F work around is responsible for fixing up the error
generated on attempted F00F exploitation from an OOPS to a SIGILL.
There is no reason why this code should not be allowed to run on
PV guest on a F00F-affected CPU -- it would simply never trigger.
The pv_enabled() check was there only to avoid printing the f00f
workaround, so removing the check is purely a cosmetic change.

Suggested-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org>
---
 arch/x86/kernel/cpu/intel.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/cpu/intel.c b/arch/x86/kernel/cpu/intel.c
index f71a34944b56..66509285ffdd 100644
--- a/arch/x86/kernel/cpu/intel.c
+++ b/arch/x86/kernel/cpu/intel.c
@@ -233,7 +233,7 @@ static void intel_workarounds(struct cpuinfo_x86 *c)
 	 * The Quark is also family 5, but does not have the same bug.
 	 */
 	clear_cpu_bug(c, X86_BUG_F00F);
-	if (!paravirt_enabled() && c->x86 == 5 && c->x86_model < 9) {
+	if (c->x86 == 5 && c->x86_model < 9) {
 		static int f00f_workaround_enabled;
 
 		set_cpu_bug(c, X86_BUG_F00F);
-- 
2.7.2

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v5 00/14] x86: remove paravirt_enabled() "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 01:50 +0200
  [PATCH v5 08/14] apm32: remove paravirt_enabled() use "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 01:50 +0200
  [PATCH v5 04/14] x86/rtc: replace paravirt rtc check with platform legacy quirk "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
  [PATCH v5 10/14] x86/cpu/intel: remove not needed paravirt_enabled() for f00f work around "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
  [PATCH v5 07/14] tools/lguest: force disable tboot and apm "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
    Re: [PATCH v5 07/14] tools/lguest: force disable tboot and apm Ingo Molnar <mingo@kernel.org> - 2016-04-13 10:50 +0200
      Re: [PATCH v5 07/14] tools/lguest: force disable tboot and apm "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-13 17:50 +0200
  [PATCH v5 14/14] x86/paravirt: remove paravirt_enabled() "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
  [PATCH v5 02/14] x86/xen: use X86_SUBARCH_XEN for PV guest boots "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
  [PATCH v5 05/14] x86, ACPI: move ACPI_FADT_NO_CMOS_RTC check to ACPI boot code "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
  [PATCH v5 09/14] x86/tboot: remove paravirt_enabled() "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:00 +0200
  Re: [PATCH v5 00/14] x86: remove paravirt_enabled() "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-04-09 02:10 +0200

csiph-web