kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] KVM: PPC: Book3S: MMIO support for Little Endian guests
@ 2013-10-08 14:12 Cédric Le Goater
  2013-10-08 14:12 ` [PATCH v2 1/3] KVM: PPC: Book3S: add helper routine to load guest instructions Cédric Le Goater
                   ` (2 more replies)
  0 siblings, 3 replies; 47+ messages in thread
From: Cédric Le Goater @ 2013-10-08 14:12 UTC (permalink / raw)
  To: agraf, paulus; +Cc: kvm-ppc, kvm, Cédric Le Goater

MIO emulation reads the last instruction executed by the guest
and then emulates. If the guest is running in Little Endian mode,
the instruction needs to be byte-swapped before being emulated.

The first patches add simple helper routines to load instructions from 
the guest. It prepares ground for the byte-swapping of instructions 
when reading memory from Little Endian guests. 

The last patch enables the MMIO support by byte-swapping the last 
instruction if the guest is Little Endian.

This patchset is based on Alex Graf's kvm-ppc-queue branch. It has been 
tested with anton's patchset for Big Endian and Little Endian HV guests 
and Big Endian PR guests. 

Changes in v2:

 - replaced rldicl. by andi. to test the MSR_LE bit in the guest
   exit paths. (Paul Mackerras)

 - moved the byte swapping logic to kvmppc_handle_load() and 
   kvmppc_handle_load() by changing the is_bigendian parameter
   meaning. (Paul Mackerras)

Thanks,

C.	

Cédric Le Goater (3):
  KVM: PPC: Book3S: add helper routine to load guest instructions
  KVM: PPC: Book3S: add helper routines to detect endian
  KVM: PPC: Book3S: MMIO emulation support for little endian guests

 arch/powerpc/include/asm/kvm_book3s.h   |   33 +++++++++++++++++++++++++++++--
 arch/powerpc/include/asm/kvm_ppc.h      |   10 +++++-----
 arch/powerpc/kvm/book3s_64_mmu_hv.c     |    2 +-
 arch/powerpc/kvm/book3s_hv_rmhandlers.S |   11 +++++++++++
 arch/powerpc/kvm/book3s_pr.c            |    2 +-
 arch/powerpc/kvm/book3s_segment.S       |   10 ++++++++++
 arch/powerpc/kvm/emulate.c              |    1 -
 arch/powerpc/kvm/powerpc.c              |   16 +++++++++++----
 8 files changed, 71 insertions(+), 14 deletions(-)

-- 
1.7.10.4

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

end of thread, other threads:[~2014-01-09 10:55 UTC | newest]

Thread overview: 47+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-08 14:12 [PATCH v2 0/3] KVM: PPC: Book3S: MMIO support for Little Endian guests Cédric Le Goater
2013-10-08 14:12 ` [PATCH v2 1/3] KVM: PPC: Book3S: add helper routine to load guest instructions Cédric Le Goater
2013-10-08 14:12 ` [PATCH v2 2/3] KVM: PPC: Book3S: add helper routines to detect endian Cédric Le Goater
2013-10-08 14:12 ` [PATCH v2 3/3] KVM: PPC: Book3S: MMIO emulation support for little endian guests Cédric Le Goater
2013-10-08 14:25   ` Alexander Graf
2013-10-08 15:07     ` Cedric Le Goater
2013-10-08 15:31       ` [PATCH v3 " Cédric Le Goater
2013-10-08 15:36         ` Alexander Graf
2013-10-08 16:10           ` Cedric Le Goater
2013-10-08 16:43             ` [PATCH v4 0/3] KVM: PPC: Book3S: MMIO support for Little Endian guests Cédric Le Goater
2013-10-08 16:43             ` [PATCH v4 1/3] KVM: PPC: Book3S: add helper routine to load guest instructions Cédric Le Goater
2013-10-08 16:43             ` [PATCH v4 2/3] KVM: PPC: Book3S: add helper routines to detect endian order Cédric Le Goater
2013-10-08 16:43             ` [PATCH v4 3/3] KVM: PPC: Book3S: MMIO emulation support for little endian guests Cédric Le Goater
2013-10-08 23:31     ` [PATCH v2 " Paul Mackerras
2013-10-08 23:46       ` Alexander Graf
2013-10-09  5:59         ` Paul Mackerras
2013-10-09  8:29           ` Alexander Graf
2013-10-09  8:42             ` Cedric Le Goater
2013-10-10 10:16             ` Paul Mackerras
2013-11-04 11:44               ` Alexander Graf
2013-11-05 12:28                 ` Cedric Le Goater
2013-11-05 13:01                   ` Alexander Graf
2013-11-05 17:22                     ` [PATCH v5 0/6] KVM: PPC: Book3S: MMIO support for Little Endian guests Cédric Le Goater
2013-11-05 17:22                     ` [PATCH v5 1/6] KVM: PPC: Book3S: add helper routine to load guest instructions Cédric Le Goater
2013-11-05 17:22                     ` [PATCH v5 2/6] KVM: PPC: Book3S: add helper routines to detect endian Cédric Le Goater
2014-01-02 20:05                       ` Alexander Graf
2014-01-08 17:22                         ` Cedric Le Goater
2013-11-05 17:22                     ` [PATCH v5 3/6] KVM: PPC: Book3S: MMIO emulation support for little endian guests Cédric Le Goater
2014-01-02 20:22                       ` Alexander Graf
2014-01-08 17:23                         ` Cedric Le Goater
2014-01-08 17:34                           ` Alexander Graf
2014-01-08 17:40                             ` Cedric Le Goater
2014-01-08 17:35                           ` [PATCH v6] " Cédric Le Goater
2014-01-09 10:02                           ` [PATCH v7] " Cédric Le Goater
2014-01-09 10:17                             ` Alexander Graf
2014-01-09 10:33                               ` Cedric Le Goater
2014-01-09 10:51                                 ` [PATCH v8] " Cédric Le Goater
2014-01-09 10:55                                   ` Alexander Graf
2013-11-05 17:22                     ` [PATCH v5 4/6] KVM: PPC: Book3S: modify kvmppc_need_byteswap() for little endian host Cédric Le Goater
2013-11-08 14:36                       ` [PATCH v5.1 " Cedric Le Goater
2014-01-02 20:28                         ` Alexander Graf
2014-01-02 20:25                       ` [PATCH v5 " Alexander Graf
2013-11-05 17:22                     ` [PATCH v5 5/6] powerpc: add Split Little Endian bit to MSR Cédric Le Goater
2013-11-05 17:22                     ` [PATCH v5 6/6] KVM: PPC: Book3S: modify byte loading when guest uses Split Little Endian Cédric Le Goater
2014-01-02 20:26                       ` Alexander Graf
2013-11-06  5:55                     ` [PATCH v2 3/3] KVM: PPC: Book3S: MMIO emulation support for little endian guests Paul Mackerras
2013-11-08 14:29                       ` Cedric Le Goater

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).