kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: James Hogan <james.hogan@imgtec.com>
To: Paolo Bonzini <pbonzini@redhat.com>, <qemu-devel@nongnu.org>
Cc: <kvm@vger.kernel.org>, Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [PATCH 0/4] QEMU MIPS KVM improvements for v2.1
Date: Thu, 26 Jun 2014 12:27:01 +0100	[thread overview]
Message-ID: <53AC0385.1030309@imgtec.com> (raw)
In-Reply-To: <53ABF1FA.8060703@redhat.com>

On 26/06/14 11:12, Paolo Bonzini wrote:
> Il 26/06/2014 11:44, James Hogan ha scritto:
>> This patchset has a few improvements & minor fixes for MIPS KVM support.
>>
>> Patches 1-2 are fixes for forward compatibility of savevm with MIPS KVM.
>> Patch 3 just corrects comments and an error message.
>> Patch 4 adds errors when the wrong type of kernel is provided.
>>
>> James Hogan (4):
>>   mips/kvm: Init EBase to correct KSEG0
>>   mips_malta: Change default KVM cpu to 24Kc (no FP)
>>   mips_malta: Remove incorrect KVM T&E references
>>   mips_malta: Catch kernels linked at wrong address
>>
>>  hw/mips/mips_malta.c    | 27 +++++++++++++++++++++++----
>>  target-mips/translate.c |  8 +++++++-
>>  2 files changed, 30 insertions(+), 5 deletions(-)
>>
> 
> Looks good, I'm just a bit unsure about patch 2.  Is FPU support on the
> todo list?  Is the idea to add a KVM capability when you add it?

At the moment KVM exposes a certain configuration to the guest,
regardless of what QEMU thinks the configuration is (see
kvm_trap_emul_vcpu_setup()). Patch 2 simply changes QEMU to match what
KVM is emulating.

FP is definitely on the todo list for VZ at least (and should in theory
be doable in T&E too), but I haven't thought too much about the details yet.

I'd guess a KVM capability to indicate that KVM supports the API would
make sense.

Even then there are multiple configurations that might want to be
used/distinguished somehow, e.g.:
* never support FP in guest (probably default for backward compatibility)
* always support FP, always via emulation in hypervisor (all FP
instructions trapping)
* always support FP, using hardware if available (minimal trapping to
guarantee guest sees an FPU)
* support FP only if host supports it, using hardware (minimal trapping
if hardware, trapping to guest OS to emulate FP if not)

Maybe which one of the above is chosen would affect what fields can be
read/written to guest Config registers with GET/SET_ONE_REG API (probing
guest config registers is closely analogous to how VZ hypervisor
controls/probes what features are/can be exposed to the guest).

Cheers
James

      reply	other threads:[~2014-06-26 11:27 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-26  9:44 [PATCH 0/4] QEMU MIPS KVM improvements for v2.1 James Hogan
2014-06-26  9:44 ` [PATCH 1/4] mips/kvm: Init EBase to correct KSEG0 James Hogan
2014-06-27  8:41   ` Aurelien Jarno
2014-06-26  9:44 ` [PATCH 2/4] mips_malta: Change default KVM cpu to 24Kc (no FP) James Hogan
2014-06-27  8:43   ` Aurelien Jarno
2014-06-27 11:33     ` Paolo Bonzini
2014-06-27 15:22       ` [PATCH v2 2/4] mips/kvm: Disable FPU on reset with KVM James Hogan
2014-06-26  9:44 ` [PATCH 3/4] mips_malta: Remove incorrect KVM T&E references James Hogan
2014-06-27  8:43   ` Aurelien Jarno
2014-06-26  9:44 ` [PATCH 4/4] mips_malta: Catch kernels linked at wrong address James Hogan
2014-06-27  8:43   ` Aurelien Jarno
2014-06-26 10:12 ` [PATCH 0/4] QEMU MIPS KVM improvements for v2.1 Paolo Bonzini
2014-06-26 11:27   ` James Hogan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53AC0385.1030309@imgtec.com \
    --to=james.hogan@imgtec.com \
    --cc=aurelien@aurel32.net \
    --cc=kvm@vger.kernel.org \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).