qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Bharata B Rao <bharata@linux.vnet.ibm.com>,
	qemu-devel@nongnu.org, qemu-ppc@nongnu.org, thuth@redhat.com,
	imammedo@redhat.com
Subject: Re: [Qemu-devel] [RFC PATCH v0 1/2] kvm: API to obtain max supported mem slots
Date: Thu, 2 Jun 2016 10:41:50 +1000	[thread overview]
Message-ID: <20160602004150.GD15455@voom.fritz.box> (raw)
In-Reply-To: <15984072-dfda-b4e8-f8b7-7b002c054fe5@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1703 bytes --]

On Wed, Jun 01, 2016 at 11:56:07AM +0200, Paolo Bonzini wrote:
> 
> 
> On 01/06/2016 11:51, Bharata B Rao wrote:
> > Introduce kvm_get_max_memslots() API that can be used to obtain the
> > maximum number of memslots supported by KVM.
> > 
> > Signed-off-by: Bharata B Rao <bharata@linux.vnet.ibm.com>
> > ---
> >  include/sysemu/kvm.h | 1 +
> >  kvm-all.c            | 7 +++++++
> >  2 files changed, 8 insertions(+)
> > 
> > diff --git a/include/sysemu/kvm.h b/include/sysemu/kvm.h
> > index 65569ed..ad6f837 100644
> > --- a/include/sysemu/kvm.h
> > +++ b/include/sysemu/kvm.h
> > @@ -527,4 +527,5 @@ int kvm_set_one_reg(CPUState *cs, uint64_t id, void *source);
> >   * Returns: 0 on success, or a negative errno on failure.
> >   */
> >  int kvm_get_one_reg(CPUState *cs, uint64_t id, void *target);
> > +int kvm_get_max_memslots(void);
> >  #endif
> > diff --git a/kvm-all.c b/kvm-all.c
> > index d317dcb..fbd2d93 100644
> > --- a/kvm-all.c
> > +++ b/kvm-all.c
> > @@ -126,6 +126,13 @@ static const KVMCapabilityInfo kvm_required_capabilites[] = {
> >      KVM_CAP_LAST_INFO
> >  };
> >  
> > +int kvm_get_max_memslots(void)
> > +{
> > +    KVMState *s = KVM_STATE(current_machine->accelerator);
> > +
> > +    return s->nr_slots;
> > +}
> > +
> >  static KVMSlot *kvm_get_free_slot(KVMMemoryListener *kml)
> >  {
> >      KVMState *s = kvm_state;
> > 
> 
> Acked-by: Paolo Bonzini <pbonzini@redhat.com>

Thanks for the ack, I've merged this into my tree.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

      reply	other threads:[~2016-06-02  0:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1464774685-7885-1-git-send-email-bharata@linux.vnet.ibm.com>
2016-06-01  9:51 ` [Qemu-devel] [RFC PATCH v0 1/2] kvm: API to obtain max supported mem slots Bharata B Rao
2016-06-01  9:51 ` [Qemu-devel] [RFC PATCH v0 2/2] spapr: Increase max memslots to 512 Bharata B Rao
     [not found] ` <201606010952.u519n7R2025378@mx0a-001b2d01.pphosted.com>
2016-06-01  9:56   ` [Qemu-devel] [RFC PATCH v0 1/2] kvm: API to obtain max supported mem slots Paolo Bonzini
2016-06-02  0:41     ` David Gibson [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=20160602004150.GD15455@voom.fritz.box \
    --to=david@gibson.dropbear.id.au \
    --cc=bharata@linux.vnet.ibm.com \
    --cc=imammedo@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.org \
    --cc=thuth@redhat.com \
    /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).