<feed xmlns='http://www.w3.org/2005/Atom'>
<title>BMC/Intel-BMC/linux.git/arch/x86/include/asm/virtext.h, branch dev</title>
<subtitle>Intel OpenBMC Linux kernel source tree (mirror)</subtitle>
<id>https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev</id>
<link rel='self' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/'/>
<updated>2015-02-04T11:10:42+00:00</updated>
<entry>
<title>x86: Store a per-cpu shadow copy of CR4</title>
<updated>2015-02-04T11:10:42+00:00</updated>
<author>
<name>Andy Lutomirski</name>
<email>luto@amacapital.net</email>
</author>
<published>2014-10-24T22:58:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=1e02ce4cccdcb9688386e5b8d2c9fa4660b45389'/>
<id>urn:sha1:1e02ce4cccdcb9688386e5b8d2c9fa4660b45389</id>
<content type='text'>
Context switches and TLB flushes can change individual bits of CR4.
CR4 reads take several cycles, so store a shadow copy of CR4 in a
per-cpu variable.

To avoid wasting a cache line, I added the CR4 shadow to
cpu_tlbstate, which is already touched in switch_mm.  The heaviest
users of the cr4 shadow will be switch_mm and __switch_to_xtra, and
__switch_to_xtra is called shortly after switch_mm during context
switch, so the cacheline is likely to be hot.

Signed-off-by: Andy Lutomirski &lt;luto@amacapital.net&gt;
Reviewed-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Cc: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Andrea Arcangeli &lt;aarcange@redhat.com&gt;
Cc: Vince Weaver &lt;vince@deater.net&gt;
Cc: "hillf.zj" &lt;hillf.zj@alibaba-inc.com&gt;
Cc: Valdis Kletnieks &lt;Valdis.Kletnieks@vt.edu&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@kernel.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Link: http://lkml.kernel.org/r/3a54dd3353fffbf84804398e00dfdc5b7c1afd7d.1414190806.git.luto@amacapital.net
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
<entry>
<title>x86: Clean up cr4 manipulation</title>
<updated>2015-02-04T11:10:41+00:00</updated>
<author>
<name>Andy Lutomirski</name>
<email>luto@amacapital.net</email>
</author>
<published>2014-10-24T22:58:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=375074cc736ab1d89a708c0a8d7baa4a70d5d476'/>
<id>urn:sha1:375074cc736ab1d89a708c0a8d7baa4a70d5d476</id>
<content type='text'>
CR4 manipulation was split, seemingly at random, between direct
(write_cr4) and using a helper (set/clear_in_cr4).  Unfortunately,
the set_in_cr4 and clear_in_cr4 helpers also poke at the boot code,
which only a small subset of users actually wanted.

This patch replaces all cr4 access in functions that don't leave cr4
exactly the way they found it with new helpers cr4_set_bits,
cr4_clear_bits, and cr4_set_bits_and_update_boot.

Signed-off-by: Andy Lutomirski &lt;luto@amacapital.net&gt;
Reviewed-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Cc: Andrea Arcangeli &lt;aarcange@redhat.com&gt;
Cc: Vince Weaver &lt;vince@deater.net&gt;
Cc: "hillf.zj" &lt;hillf.zj@alibaba-inc.com&gt;
Cc: Valdis Kletnieks &lt;Valdis.Kletnieks@vt.edu&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@kernel.org&gt;
Cc: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Link: http://lkml.kernel.org/r/495a10bdc9e67016b8fd3945700d46cfd5c12c2f.1414190806.git.luto@amacapital.net
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
<entry>
<title>Disintegrate asm/system.h for X86</title>
<updated>2012-03-28T17:11:12+00:00</updated>
<author>
<name>David Howells</name>
<email>dhowells@redhat.com</email>
</author>
<published>2012-03-28T17:11:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=f05e798ad4c09255f590f5b2c00a7ca6c172f983'/>
<id>urn:sha1:f05e798ad4c09255f590f5b2c00a7ca6c172f983</id>
<content type='text'>
Disintegrate asm/system.h for X86.

Signed-off-by: David Howells &lt;dhowells@redhat.com&gt;
Acked-by: H. Peter Anvin &lt;hpa@zytor.com&gt;
cc: x86@kernel.org
</content>
</entry>
<entry>
<title>KVM: SVM: Move EFER and MSR constants to generic x86 code</title>
<updated>2009-03-24T09:02:46+00:00</updated>
<author>
<name>Alexander Graf</name>
<email>agraf@suse.de</email>
</author>
<published>2008-11-25T19:17:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=9962d032bbff0268f22068787831405f8468c8b4'/>
<id>urn:sha1:9962d032bbff0268f22068787831405f8468c8b4</id>
<content type='text'>
MSR_EFER_SVME_MASK, MSR_VM_CR and MSR_VM_HSAVE_PA are set in KVM
specific headers. Linux does have nice header files to collect
EFER bits and MSR IDs, so IMHO we should put them there.

While at it, I also changed the naming scheme to match that
of the other defines.

(introduced in v6)

Acked-by: Joerg Roedel &lt;joro@8bytes.org&gt;
Signed-off-by: Alexander Graf &lt;agraf@suse.de&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
<entry>
<title>x86: cpu_emergency_svm_disable() function</title>
<updated>2008-12-31T14:52:30+00:00</updated>
<author>
<name>Eduardo Habkost</name>
<email>ehabkost@redhat.com</email>
</author>
<published>2008-11-17T21:03:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=0f3e9eeba0ea212bbea88790729d054b700ab91e'/>
<id>urn:sha1:0f3e9eeba0ea212bbea88790729d054b700ab91e</id>
<content type='text'>
This function can be used by the reboot or kdump code to forcibly
disable SVM on the CPU.

Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
<entry>
<title>KVM: SVM: move svm_hardware_disable() code to asm/virtext.h</title>
<updated>2008-12-31T14:52:30+00:00</updated>
<author>
<name>Eduardo Habkost</name>
<email>ehabkost@redhat.com</email>
</author>
<published>2008-11-17T21:03:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=2c8dceebb238680d5577500f8283397d41ca5590'/>
<id>urn:sha1:2c8dceebb238680d5577500f8283397d41ca5590</id>
<content type='text'>
Create cpu_svm_disable() function.

Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
<entry>
<title>KVM: SVM: move has_svm() code to asm/virtext.h</title>
<updated>2008-12-31T14:52:29+00:00</updated>
<author>
<name>Eduardo Habkost</name>
<email>ehabkost@redhat.com</email>
</author>
<published>2008-11-17T21:03:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=63d1142f8f69e39468bc6079ab2239e902828134'/>
<id>urn:sha1:63d1142f8f69e39468bc6079ab2239e902828134</id>
<content type='text'>
Use a trick to keep the printk()s on has_svm() working as before. gcc
will take care of not generating code for the 'msg' stuff when the
function is called with a NULL msg argument.

Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
<entry>
<title>x86: cpu_emergency_vmxoff() function</title>
<updated>2008-12-31T14:52:29+00:00</updated>
<author>
<name>Eduardo Habkost</name>
<email>ehabkost@redhat.com</email>
</author>
<published>2008-11-17T21:03:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=6aa07a0d77f6aafbe69e4e8609ffaf2b7ee1b591'/>
<id>urn:sha1:6aa07a0d77f6aafbe69e4e8609ffaf2b7ee1b591</id>
<content type='text'>
Add cpu_emergency_vmxoff() and its friends: cpu_vmx_enabled() and
__cpu_emergency_vmxoff().

Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
<entry>
<title>x86: asm/virtext.h: add cpu_vmxoff() inline function</title>
<updated>2008-12-31T14:52:29+00:00</updated>
<author>
<name>Eduardo Habkost</name>
<email>ehabkost@redhat.com</email>
</author>
<published>2008-11-17T21:03:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=1e9931146c748420343aeefadb3bb17bd1c14a37'/>
<id>urn:sha1:1e9931146c748420343aeefadb3bb17bd1c14a37</id>
<content type='text'>
Unfortunately we can't use exactly the same code from vmx
hardware_disable(), because the KVM function uses the
__kvm_handle_fault_on_reboot() tricks.

Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
<entry>
<title>KVM: VMX: move cpu_has_kvm_support() to an inline on asm/virtext.h</title>
<updated>2008-12-31T14:52:28+00:00</updated>
<author>
<name>Eduardo Habkost</name>
<email>ehabkost@redhat.com</email>
</author>
<published>2008-11-17T21:03:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=6210e37b122583643da335c0389f74098713e5ca'/>
<id>urn:sha1:6210e37b122583643da335c0389f74098713e5ca</id>
<content type='text'>
It will be used by core code on kdump and reboot, to disable
vmx if needed.

Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Avi Kivity &lt;avi@redhat.com&gt;
</content>
</entry>
</feed>
