mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/4] x86: Add and use support for clflushopt
@ 2014-02-26 19:06 Ross Zwisler
  2014-02-26 19:06 ` [PATCH 1/4] x86: Add " Ross Zwisler
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Ross Zwisler @ 2014-02-26 19:06 UTC (permalink / raw)
  To: linux-kernel; +Cc: Ross Zwisler, H Peter Anvin, Ingo Molnar, Thomas Gleixner

This patch series adds support for the new clflushopt instruction and then
uses it in a few appropriate places in x86 specific code.  It does this using
the alternatives mechanism, so any platforms without support for clflushopt
will continue to use clflush instead.

clflushopt was announced in the document "Intel Architecture Instruction Set
Extensions Programming Reference" with Ref # 319433-018.

http://download-software.intel.com/sites/default/files/managed/50/1a/319433-018.pdf

clflushopt has the same flushing behavior as clflush, but has more relaxed
ordering.  clflushopt must be explicitly ordered by sfence or mfence.

The inline assembly for clflushopt was implemented using %P so that the
generated addresses will always be absolute instead of sometimes being RIP
relative.  This is necessary for the alternatives code to behave correctly.

Ross Zwisler (4):
  x86: Add support for clflushopt
  x86: Use clflushopt in clflush_cache_range
  x86: Use clflushopt in drm_clflush_page
  x86: Use clflushopt in drm_clflush_virt_range

 arch/x86/include/asm/cpufeature.h    |    1 +
 arch/x86/include/asm/special_insns.h |    8 ++++++++
 arch/x86/mm/pageattr.c               |    8 ++++----
 drivers/gpu/drm/drm_cache.c          |   10 ++++++++--
 4 files changed, 21 insertions(+), 6 deletions(-)

-- 
1.7.10.4


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2014-02-27 16:31 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-26 19:06 [PATCH 0/4] x86: Add and use support for clflushopt Ross Zwisler
2014-02-26 19:06 ` [PATCH 1/4] x86: Add " Ross Zwisler
2014-02-27 16:27   ` [tip:x86/cpufeature] x86: Add support for the clflushopt instruction tip-bot for Ross Zwisler
2014-02-26 19:06 ` [PATCH 2/4] x86: Use clflushopt in clflush_cache_range Ross Zwisler
2014-02-27 16:30   ` [tip:x86/cpu] " tip-bot for Ross Zwisler
2014-02-26 19:06 ` [PATCH 3/4] x86: Use clflushopt in drm_clflush_page Ross Zwisler
2014-02-27 16:30   ` [tip:x86/cpu] " tip-bot for Ross Zwisler
2014-02-26 19:06 ` [PATCH 4/4] x86: Use clflushopt in drm_clflush_virt_range Ross Zwisler
2014-02-27 16:30   ` [tip:x86/cpu] " tip-bot for Ross Zwisler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome