[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH] qemu: New XML to disable memory merge at guest startup



On 25/04/13 22:14, Eric Blake wrote:
On 04/17/2013 08:54 AM, Eric Blake wrote:
On 04/17/2013 08:22 AM, Osier Yang wrote:
QEMU introduced command line "-mem-merge=on|off" (defaults to on) to
enable/disable the memory merge (KSM) at guest startup. This exposes
it by new XML:
   <memoryBacking>
     <nosharepages/>
   </memoryBacking>

The XML tag is same with what we used internally for old RHEL.
Good - that means that RHEL 6 (and any other downstream distro that was
already borrowing the RHEL extension) will not break when rebasing to
pick up this change from upstream in place of their downstream extension
(RHEL will actually want to add a followup patch on top of this that
_also_ tries the older -redhat-disable-KSM downstream spelling of the
option, but that's a problem for RHEL and not this list).

+ if (strstr(help, "-mem-merge"))
+        virQEMUCapsSet(qemuCaps, QEMU_CAPS_MEM_MERGE);
This would only scrape the existence of -mem-merge in qemu 1.2 and
earlier, since we don't read -help in 1.3 and later.  But qemu 1.2
doesn't have -mem-merge, so this bit will never get set.  You need to
instead populate the new capability based on a QMP probe, not string
scraping.  But I don't know offhand what that probe would be; you may
need to ask on the qemu list.
And we have a winner.  We are getting query-command-line-options for
qemu 1.5, and it looks easy enough that distros may be able to backport
it into earlier qemu (again, I'll leave it up to Red Hat internal lists
on whether it will be backported to RHEL).

https://lists.gnu.org/archive/html/qemu-devel/2013-04/msg05040.html

Looking forward to v2.
Do you need help writing the src/qemu/qemu_monitor_json.c changes needed
to utilize the new query-command-line-options QMP command, since I kind
of spearheaded the design review on the qemu list?

I don't have much time before the beginning of May.  Appreciated if
you can do it. Or I can take it if it's delayed. :-)

Regards,
Osier


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]