From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NN19u-0008Mz-4h for qemu-devel@nongnu.org; Tue, 22 Dec 2009 04:36:02 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NN19t-0008Mf-Gb for qemu-devel@nongnu.org; Tue, 22 Dec 2009 04:36:01 -0500 Received: from [199.232.76.173] (port=51249 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NN19t-0008MR-Di for qemu-devel@nongnu.org; Tue, 22 Dec 2009 04:36:01 -0500 Received: from hall.aurel32.net ([88.191.82.174]:44377) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NN19s-0000wX-EJ for qemu-devel@nongnu.org; Tue, 22 Dec 2009 04:36:01 -0500 Date: Tue, 22 Dec 2009 10:35:54 +0100 From: Aurelien Jarno Subject: Re: [Qemu-devel] [PATCH master, stable-0.12] Don't load options roms intended to be loaded by the bios in qemu Message-ID: <20091222093554.GC31094@hall.aurel32.net> References: <1261473913-28442-1-git-send-email-avi@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <1261473913-28442-1-git-send-email-avi@redhat.com> Sender: Aurelien Jarno List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: qemu-devel@nongnu.org On Tue, Dec 22, 2009 at 11:25:13AM +0200, Avi Kivity wrote: > The first such option rom will load at address 0, which isn't very nice, > and the second will report a conflict and abort, which is horrible. > > Signed-off-by: Avi Kivity > --- > hw/loader.c | 3 +++ > 1 files changed, 3 insertions(+), 0 deletions(-) > > diff --git a/hw/loader.c b/hw/loader.c > index 2ceb8eb..c6bf0f1 100644 > --- a/hw/loader.c > +++ b/hw/loader.c > @@ -654,6 +654,9 @@ int rom_load_all(void) > Rom *rom; > > QTAILQ_FOREACH(rom, &roms, next) { > + if (!rom->addr) { > + continue; > + } Some roms needs to be loaded at address 0, it's the case for example of the arm versatile bootloader. Adding this code will break the board emulation. > if (addr > rom->addr) { > fprintf(stderr, "rom: requested regions overlap " > "(rom %s. free=0x" TARGET_FMT_plx > -- > 1.6.5.3 > > > > -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net