qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Dave Hansen <dave@linux.vnet.ibm.com>
To: Anthony Liguori <aliguori@us.ibm.com>
Cc: Amit Shah <amit.shah@redhat.com>,
	Anthony Liguori <aliguori@linux.vnet.ibm.com>,
	qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] set VIRTIO_BALLOON_F_MUST_TELL_HOST unconditionally
Date: Fri, 15 Apr 2011 09:36:55 -0700	[thread overview]
Message-ID: <1302885415.16562.3358.camel@nimitz> (raw)
In-Reply-To: <4DA87093.7050008@us.ibm.com>

On Fri, 2011-04-15 at 11:21 -0500, Anthony Liguori wrote:
> > This patch makes the "tell host first" logic the only case.  This
> > should make everybody happy, and reduce the amount of untested or
> > untestable code in the kernel.
> 
> It doesn't make me happy.

Darn.

> Why would we do this in QEMU?  This prevents the guest from doing 
> ballooning reclaim during OOM.

What the heck is "ballooning reclaim"?  Could you elaborate a bit on how
this happens?  I think I'm missing some subtlety here.

I think 'tell host first' is the only sane way to do it.  Look at the
'tell host second code':

	release_pages_by_pfn(); // let other kernel users at the pages
	tell_host(); // tell the hypervisor they're used again

At the point we've started using the pages again, we haven't *told* the
host that we're using them.  I think that's potentially a problem.  Is
qemu somehow cool with the guest touching pages that are supposed to be
in the balloon and unusable?

-- Dave

  reply	other threads:[~2011-04-15 16:37 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-15 14:44 [Qemu-devel] [PATCH] set VIRTIO_BALLOON_F_MUST_TELL_HOST unconditionally Dave Hansen
2011-04-15 16:21 ` Anthony Liguori
2011-04-15 16:36   ` Dave Hansen [this message]
2011-04-15 17:17     ` Anthony Liguori
2011-04-15 19:15       ` Dave Hansen
2011-04-15 19:20         ` Anthony Liguori
2011-04-18 15:37           ` Dave Hansen

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=1302885415.16562.3358.camel@nimitz \
    --to=dave@linux.vnet.ibm.com \
    --cc=aliguori@linux.vnet.ibm.com \
    --cc=aliguori@us.ibm.com \
    --cc=amit.shah@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).