kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* KVM: How does is PAT emulation supposed to work?
@ 2015-04-13  5:16 Jan Kiszka
  2015-04-13  6:58 ` [RFC][PATCH] KVM: SVM: Sync g_pat with guest-written PAT value Jan Kiszka
  2015-04-17 16:43 ` KVM: How does is PAT emulation supposed to work? Radim Krčmář
  0 siblings, 2 replies; 27+ messages in thread
From: Jan Kiszka @ 2015-04-13  5:16 UTC (permalink / raw)
  To: kvm

Hi all,

while digging into the PAT topic for Jailhouse, I also wondered how KVM
deals with it. And I'm still not getting it complete - or there is a bug:

KVM intercepts all guest writes to the PAT MSR and instead keeps the
guest value in vcpu->arch.pat. But, besides returning that value back on
read accesses, arch.pat has no other purpose.

On Intel, we only seem to have proper emulation - through hardware -
when VMX supports PAT switching (see vmx_set_msr). On AMD, the situation
is even worse as the g_pat save field is not updated at all on PAT
writes. That seems to be a low hanging fruit to bring svm on the same
support level as vmx.

Or am I missing something?

Jan

PS: If someone has a good idea for a simple test case on machines
without IOMMU (like my current boxes), thus without a chance to use
device pass-through to stress guest PAT settings, I would be all ears.

-- 
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux

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

end of thread, other threads:[~2016-02-09 19:25 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-13  5:16 KVM: How does is PAT emulation supposed to work? Jan Kiszka
2015-04-13  6:58 ` [RFC][PATCH] KVM: SVM: Sync g_pat with guest-written PAT value Jan Kiszka
2015-04-17 16:59   ` Radim Krčmář
2015-04-20 16:14   ` Radim Krčmář
2015-04-20 17:16     ` Radim Krčmář
2015-04-20 17:21       ` Jan Kiszka
2015-04-20 17:33         ` Radim Krčmář
2015-04-20 17:37           ` Jan Kiszka
2015-04-20 17:45             ` Jan Kiszka
2015-04-20 18:33               ` Radim Krčmář
2015-04-20 18:41                 ` Jan Kiszka
2015-04-21 12:10                   ` Radim Krčmář
2015-04-21 12:11                   ` Paolo Bonzini
2015-04-20 17:22       ` Radim Krčmář
2015-04-20 17:25     ` [PATCH v2] " Jan Kiszka
2015-04-20 17:35       ` Radim Krčmář
2015-04-21 11:09       ` Paolo Bonzini
2015-04-21 11:25         ` Jan Kiszka
2015-04-21 11:32           ` Paolo Bonzini
2015-04-21 11:56             ` Jan Kiszka
2015-04-21 12:12               ` Paolo Bonzini
2015-04-21 12:21         ` Radim Krčmář
2015-05-24 15:28           ` Jan Kiszka
2016-02-09 19:25             ` Jan Kiszka
2015-04-17 16:43 ` KVM: How does is PAT emulation supposed to work? Radim Krčmář
2015-04-17 17:12   ` Jan Kiszka
2015-04-17 20:28     ` Radim Krčmář

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).