Commit a534b679180025aa324ebd63c05516e478551cfd

Authored by Andi Kleen
Committed by Linus Torvalds
1 parent 23d5ea5d3e

x86_64: Remove CLFLUSH in text_poke()

The CLFLUSH for the modified code line in text_poke was supposed
to speed up CPU recovery. Unfortunately it seems to cause hangs
on some VIA C3s (at least on VIA Esther Model 10 Stepping 9)
Remove it.

Thanks to Stefan Becker for reporting/testing.

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 1 changed file with 2 additions and 4 deletions Side-by-side Diff

arch/i386/kernel/alternative.c
... ... @@ -445,9 +445,7 @@
445 445 {
446 446 memcpy(addr, opcode, len);
447 447 sync_core();
448   - /* Not strictly needed, but can speed CPU recovery up. Ignore cross cacheline
449   - case. */
450   - if (cpu_has_clflush)
451   - asm("clflush (%0) " :: "r" (addr) : "memory");
  448 + /* Could also do a CLFLUSH here to speed up CPU recovery; but
  449 + that causes hangs on some VIA CPUs. */
452 450 }