From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1J9fap-0004pP-GU for mharc-grub-devel@gnu.org; Tue, 01 Jan 2008 06:47:35 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1J9fan-0004ng-Vg for grub-devel@gnu.org; Tue, 01 Jan 2008 06:47:34 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1J9fan-0004mL-30 for grub-devel@gnu.org; Tue, 01 Jan 2008 06:47:33 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1J9fam-0004m5-QM for grub-devel@gnu.org; Tue, 01 Jan 2008 06:47:32 -0500 Received: from aybabtu.com ([69.60.117.155]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1J9fam-0006O5-CG for grub-devel@gnu.org; Tue, 01 Jan 2008 06:47:32 -0500 Received: from [192.168.10.6] (helo=thorin) by aybabtu.com with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1J9fak-0002Qi-8e for grub-devel@gnu.org; Tue, 01 Jan 2008 12:47:31 +0100 Received: from rmh by thorin with local (Exim 4.63) (envelope-from ) id 1J9f76-0002Ti-8w for grub-devel@gnu.org; Tue, 01 Jan 2008 12:16:52 +0100 Date: Tue, 1 Jan 2008 12:16:52 +0100 From: Robert Millan To: The development of GRUB 2 Message-ID: <20080101111652.GA8608@thorin> References: <471E4628.9030706@t-online.de> <20071118112737.GB16674@thorin> <474202DA.4010001@t-online.de> <47790D50.4060000@t-online.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <47790D50.4060000@t-online.de> Organization: free as in freedom X-Message-Flag: Worried about Outlook viruses? Switch to Thunderbird! www.mozilla.com/thunderbird X-Debbugs-No-Ack: true User-Agent: Mutt/1.5.13 (2006-08-11) X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: [PATCH] Fix eisa_mmap evaluation, add memory existence check X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Jan 2008 11:47:34 -0000 On Mon, Dec 31, 2007 at 04:40:00PM +0100, Christian Franke wrote: > This version of the patch contains only the fix for the E801 EISA memory > map. The memory existence check was helpful for testing but is not > really necessary. I think the memory existence check might be good to have (I'd make sure it's not cpu-specific and move it to kern/whatever.c, though). As for the rest.. > But this bug should be fixed, otherwise GRUB2 would crash if BIOS does > not provide the E820 memory map. > > Christian > > > 2007-12-31 Christian Franke > > * kern/i386/pc/init.c (grub_machine_init): Fix > evaluation of eisa_mmap. I don't think I'm the most indicate to review this part of the patch, but since nobody else does... Well you might find this funny, but try a google search for "e801 eisa" and see what the first hit is. :-) > --- grub2.orig/kern/i386/pc/init.c 2007-10-22 22:22:51.359375000 +0200 > +++ grub2/kern/i386/pc/init.c 2007-12-31 16:05:59.953125000 +0100 > @@ -199,13 +199,8 @@ grub_machine_init (void) > > if (eisa_mmap) > { > - if ((eisa_mmap & 0xFFFF) == 0x3C00) > - add_mem_region (0x100000, (eisa_mmap << 16) + 0x100000 * 15); > - else > - { > - add_mem_region (0x100000, (eisa_mmap & 0xFFFF) << 10); > - add_mem_region (0x1000000, eisa_mmap << 16); > - } > + add_mem_region (0x100000, (eisa_mmap & 0xFFFF) << 10); > + add_mem_region (0x1000000, eisa_mmap & ~0xFFFF); > } > else > add_mem_region (0x100000, grub_get_memsize (1) << 10); Ok, as it seems, this comes from: * grub_get_eisa_mmap() : return packed EISA memory map, lower 16 bits is * memory between 1M and 16M in 1K parts, upper 16 bits is * memory above 16M in 64K parts. If error, return zero. So the replacement of "eisa_mmap << 16" seems obviously correct, but the "0x3C00" part you removed is completely misterious to me. Can you explain what was it supposed to be doing or why you removed it? -- Robert Millan I know my rights; I want my phone call! What use is a phone call, if you are unable to speak? (as seen on /.)