From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anthony Liguori Subject: Re: KVM usability Date: Tue, 09 Mar 2010 11:27:38 -0600 Message-ID: <4B96850A.40708@codemonkey.ws> References: <1267068445.1726.25.camel@localhost> <1267089644.12790.74.camel@laptop> <1267152599.1726.76.camel@localhost> <20100226090147.GH15885@elte.hu> <4B879A2F.50203@redhat.com> <20100226103545.GA7463@elte.hu> <4B87A6BF.3090301@redhat.com> <20100226111734.GE7463@elte.hu> <4B8813F2.8090208@redhat.com> <20100227105643.GA17425@elte.hu> <4B8C38B8.8010007@codemonkey.ws> <62EE499D-BE5D-4014-80C7-6FB3A0A1C71E@suse.de> <4B8C799A.6000102@codemonkey.ws> <4B964DD0.4090100@redhat.com> <1268145178.2251.12.camel@x200> <6CF4AA9A-5C83-42C2-80BF-AEEFE68A99B6@suse.de> <4B96602D.8050604@codemonkey.ws> <4B9660C6.4080405@redhat.com> <4B9661D1.8040109@codemonkey.ws> <4B968155.5030300@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Alexander Graf , kirkland@canonical.com, Ingo Molnar , "Zhang, Yanmin" , Peter Zijlstra , ming.m.lin@intel.com, sheng.yang@intel.com, Jes Sorensen , KVM General , Zachary Amsden , Gleb Natapov , Arnaldo Carvalho de Melo , Fr??d??ric Weisbecker , Thomas Gleixner , "H. Peter Anvin" , Peter Zijlstra , Arjan van de Ven To: Avi Kivity Return-path: Received: from mail-bw0-f209.google.com ([209.85.218.209]:33259 "EHLO mail-bw0-f209.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751113Ab0CIR1q (ORCPT ); Tue, 9 Mar 2010 12:27:46 -0500 Received: by bwz1 with SMTP id 1so4118848bwz.21 for ; Tue, 09 Mar 2010 09:27:44 -0800 (PST) In-Reply-To: <4B968155.5030300@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 03/09/2010 11:11 AM, Avi Kivity wrote: > On 03/09/2010 04:57 PM, Anthony Liguori wrote: >> On 03/09/2010 08:52 AM, Avi Kivity wrote: >>> On 03/09/2010 04:50 PM, Anthony Liguori wrote: >>>>> It's all in the openSUSE build service. The direct access URL >>>>> (login required FWIW) is here: >>>>> >>>>> https://build.opensuse.org/package/view_file?file=kvm-qemu-default-memsize.patch&package=kvm&project=Virtualization >>>>> >>>>> >>>>> It merely changes DEFAULT_RAM_SIZE in vl.c from 128 to 384 for the >>>>> "kvm" package. >>>> >>>> We should attempt to do three things with default ram size: >>>> >>>> 1) bump it up to a more reasonable number >>>> 2) make it specified in the global default config >>>> 3) make sure we can provide compatibility support for older machine >>>> types >>> >>> It's really sad, the amount of code needed to change a number. >> >> We don't do enough via a config. If we did, we could just have a >> 0.12 config version that got frozen over time. >> >> So really, if we can make the mem readable by global config, and we >> can have machine specific configs, it would simplify the problem in >> the future so that we just had to bump a number. > > Perhaps a json representation of things. We already have the parser. Please no :-) We have a config format, QemuOpts ties nicely into it as does qdev. We just need to represent machine information via QemuOpts and tie -m to manipulating the memory assigned to a machine. IOW, instead of: (machine_init)(ram_addr_t ram_size, const char *boot_device, const char *kernel_filename, const char *kernel_cmdline, const char *initrd_filename, const char *cpu_model) It should be: (machine_init)(QemuOpts *opts); Then we can have a [machine] section in the config where we describe all of these things. Regards, Anthony Liguori