From: Wei Wang <wei.w.wang@intel.com>
To: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
"mst@redhat.com" <mst@redhat.com>,
"quintela@redhat.com" <quintela@redhat.com>,
"peterx@redhat.com" <peterx@redhat.com>,
"pbonzini@redhat.com" <pbonzini@redhat.com>,
"liliang.opensource@gmail.com" <liliang.opensource@gmail.com>,
"nilal@redhat.com" <nilal@redhat.com>,
"riel@redhat.com" <riel@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v11 7/7] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_HINT
Date: Thu, 21 Feb 2019 09:49:42 +0800 [thread overview]
Message-ID: <5C6E03B6.30309@intel.com> (raw)
In-Reply-To: <20190220131224.GF2608@work-vm>
On 02/20/2019 09:12 PM, Dr. David Alan Gilbert wrote:
> * Wang, Wei W (wei.w.wang@intel.com) wrote:
>> On Friday, December 14, 2018 7:17 PM, Dr. David Alan Gilbert wrote:
>>>> On 12/14/2018 05:56 PM, Dr. David Alan Gilbert wrote:
>>>>> * Wei Wang (wei.w.wang@intel.com) wrote:
>>>>>> On 12/13/2018 11:45 PM, Dr. David Alan Gilbert wrote:
>>>>>>> * Wei Wang (wei.w.wang@intel.com) wrote:
>>>>>>>> The new feature enables the virtio-balloon device to receive
>>>>>>>> hints of guest free pages from the free page vq.
>>>>>>>>
>>>>>>>> A notifier is registered to the migration precopy notifier
>>>>>>>> chain. The notifier calls free_page_start after the migration
>>>>>>>> thread syncs the dirty bitmap, so that the free page
>>>>>>>> optimization starts to clear bits of free pages from the
>>>>>>>> bitmap. It calls the free_page_stop before the migration
>>>>>>>> thread syncs the bitmap, which is the end of the current round
>>>>>>>> of ram save. The free_page_stop is also called to stop the
>>> optimization in the case when there is an error occurred in the process of
>>> ram saving.
>>>>>>>> Note: balloon will report pages which were free at the time of this
>>> call.
>>>>>>>> As the reporting happens asynchronously, dirty bit logging
>>>>>>>> must be enabled before this free_page_start call is made.
>>>>>>>> Guest reporting must be disabled before the migration dirty bitmap
>>> is synchronized.
>>>>>>>> Signed-off-by: Wei Wang <wei.w.wang@intel.com>
>>>>>>>> CC: Michael S. Tsirkin <mst@redhat.com>
>>>>>>>> CC: Dr. David Alan Gilbert <dgilbert@redhat.com>
>>>>>>>> CC: Juan Quintela <quintela@redhat.com>
>>>>>>>> CC: Peter Xu <peterx@redhat.com>
>>>>>>> I think I'm OK for this from the migration side, I'd appreciate
>>>>>>> someone checking the virtio and aio bits.
>>>>>>>
>>>>>>> I'm not too sure how it gets switched on and off - i.e. if we
>>>>>>> get a nice new qemu on a new kernel, what happens when I try and
>>>>>>> migrate to the same qemu on an older kernel without these hints?
>>>>>>>
>>>>>> This feature doesn't rely on the host kernel. Those hints are
>>>>>> reported from the guest kernel.
>>>>>> So migration across different hosts wouldn't affect the use of this
>>> feature.
>>>>>> Please correct me if I didn't get your point.
>>>>> Ah OK, yes; now what about migrating from new->old qemu with a new
>>>>> guest but old machine type?
>>>>>
>>>> I think normally, the source QEMU and destination QEMU should have the
>>>> same QEMU booting parameter. If the destination QEMU doesn't support
>>>> "--device virtio-balloon,free-page-hint=true", which the source QEMU
>>>> has, the destination side QEMU will fail to boot, and migration will
>>>> not happen then.
>>> Ah that's OK; as long as free-page-hint is false by default that will work fine.
>>>
>>> Dave
>>>
>> Hi Dave,
>>
>> Could we have this feature in QEMU 4.0 (freeze on Mar 12)?
> I think so; can you remind me where we're up to:
> a) It looks like you've already got the kernel changes merged -
> correct?
Yes, they were already merged half year ago.
> b) What about the virtio spec changes - where are they upto?
The spec changes are in progress. v1 were posted out, a v2 is in
preparation.
> c) Where are the other reviews upto - I think most are reviewed - is
> it just 7/7 that is missing the review-by?
7/7 is about the virtio changes, and Michael has given the reviewed-by:
http://lists.nongnu.org/archive/html/qemu-devel/2018-12/msg03732.html
Best,
Wei
next prev parent reply other threads:[~2019-02-21 1:44 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-11 8:24 [Qemu-devel] [PATCH v11 0/7] virtio-balloon: free page hint support Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 1/7] bitmap: fix bitmap_count_one Wei Wang
2018-12-13 14:28 ` Dr. David Alan Gilbert
2018-12-14 6:37 ` Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 2/7] bitmap: bitmap_count_one_with_offset Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 3/7] migration: use bitmap_mutex in migration_bitmap_clear_dirty Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 4/7] migration: API to clear bits of guest free pages from the dirty bitmap Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 5/7] migration/ram.c: add a notifier chain for precopy Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 6/7] migration/ram.c: add the free page optimization enable flag Wei Wang
2018-12-11 8:24 ` [Qemu-devel] [PATCH v11 7/7] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_HINT Wei Wang
2018-12-13 15:45 ` Dr. David Alan Gilbert
2018-12-14 6:39 ` Wei Wang
2018-12-14 9:56 ` Dr. David Alan Gilbert
2018-12-14 10:30 ` Wei Wang
2018-12-14 11:17 ` Dr. David Alan Gilbert
2019-02-19 9:18 ` Wang, Wei W
2019-02-20 13:12 ` Dr. David Alan Gilbert
2019-02-21 1:49 ` Wei Wang [this message]
2019-02-21 10:18 ` Dr. David Alan Gilbert
2019-02-22 1:11 ` Wei Wang
2019-03-05 14:50 ` Dr. David Alan Gilbert
2019-03-06 2:04 ` Wei Wang
2018-12-14 21:03 ` [Qemu-devel] [PATCH v11 0/7] virtio-balloon: free page hint support Michael S. Tsirkin
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=5C6E03B6.30309@intel.com \
--to=wei.w.wang@intel.com \
--cc=dgilbert@redhat.com \
--cc=liliang.opensource@gmail.com \
--cc=mst@redhat.com \
--cc=nilal@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peterx@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.com \
--cc=riel@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).