[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating proc
From: |
Li, Liang Z |
Subject: |
Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process |
Date: |
Fri, 17 Jun 2016 00:54:28 +0000 |
> >>>> + chunk = TARGET_PAGE_SIZE;
> >>>> + }
> >>>> + }
> >>>> +}
> >>>> +
> >>>> +static void balloon_bulk_pages(ram_addr_t base_pfn, unsigned long
> >>> *bitmap,
> >>>> + unsigned long len, int page_shift,
> >>>> +bool deflate) { #if defined(__linux__)
> >>>
> >>> Why do you need this #if here?
> >>>
> >> Ooh, it is wrong to add the '#if' here, will remove.
> >>
> > No, it is needed, just follow the code in balloon_page().
> > only Linux support the madvise().
>
> I think it is not needed anymore today and the #if in balloon_page could be
> removed, too: As far as I can see, the #if there is from the early days, when
> there was no wrapper around madvise() yet. But nowadays, we've got the
> qemu_madvise() wrapper which takes care of either using madvise(),
> posix_madvise() or doing nothing, so the virtio-balloon code should be able
> to work without the #if now.
>
> Thomas
You are right! I will remove both of them.
Thanks!
Liang
- [Qemu-devel] [QEMU 0/7] Fast balloon and fast live migration, Liang Li, 2016/06/13
- [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process, Liang Li, 2016/06/13
- Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process, Thomas Huth, 2016/06/14
- Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process, Li, Liang Z, 2016/06/14
- Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process, Li, Liang Z, 2016/06/14
- Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process, Thomas Huth, 2016/06/14
- Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process,
Li, Liang Z <=
Re: [Qemu-devel] [QEMU 1/7] balloon: speed up inflating & deflating process, Michael S. Tsirkin, 2016/06/19
[Qemu-devel] [QEMU 2/7] virtio-balloon: add drop cache support, Liang Li, 2016/06/13
[Qemu-devel] [QEMU 4/7] balloon: get free page info from guest, Liang Li, 2016/06/13
[Qemu-devel] [QEMU 3/7] Add the hmp and qmp interface for dropping cache, Liang Li, 2016/06/13