From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JndKf-0008Ro-Ir for qemu-devel@nongnu.org; Sun, 20 Apr 2008 13:28:05 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JndKd-0008PZ-7B for qemu-devel@nongnu.org; Sun, 20 Apr 2008 13:28:04 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JndKd-0008PQ-2P for qemu-devel@nongnu.org; Sun, 20 Apr 2008 13:28:03 -0400 Received: from ug-out-1314.google.com ([66.249.92.171]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JndKc-0007Bo-OX for qemu-devel@nongnu.org; Sun, 20 Apr 2008 13:28:02 -0400 Received: by ug-out-1314.google.com with SMTP id m2so513660uge.4 for ; Sun, 20 Apr 2008 10:27:55 -0700 (PDT) Message-ID: Date: Sun, 20 Apr 2008 19:27:55 +0200 From: "andrzej zaborowski" Subject: Re: [Qemu-devel] [PATCH] Set memory size per machine In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org On 20/04/2008, Blue Swirl wrote: > On 4/20/08, andrzej zaborowski wrote: > > This patch lets a machine decide on the amount of space it'll use in > > phys_ram_base in addition to that specified with "-m", default is > > zero. Currently that amount was the maximum of BIOS size + VGA RAM > > size over all machines of all archs, and that was not enough for the > > MusicPal and even if extended it may be not enough for a machine > > supported in the future. > > > > This also lets a machine OR the specified value with a RAMSIZE_FIXED > > flag to indicate that it ignores the value given with "-m" (true for > > almost half of the machines in qemu). > > In addition to minimum, higher level code could handle the maximum > memory size supported, like sun4m.c does currently. Then I'd use > ram_min and ram_max or something similar. ram_require doesn't set a minimum for the "-m" value, this value is passed as is to machine->init. It only set the maximum RAM the machine can use in addition to that specified with "-m". I can add ram_min and ram_max but that would as far as I can tell be used only by sun4m.c at the moment. > > > +#define RAMSIZE_FIXED (1 << 0) > > + size_t ram_require; > > + const char *boot_letters; > > boot_letters? Oops, this was an idea I gave up (for this patch) for QEMUMachine to optionally specify allowed -boot values against main() could validate. Regards -- Please do not print this email unless absolutely necessary. Spread environmental awareness.