From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MIYg7-0001p4-Ge for mharc-grub-devel@gnu.org; Sun, 21 Jun 2009 21:50:35 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MIYg5-0001mQ-O4 for grub-devel@gnu.org; Sun, 21 Jun 2009 21:50:33 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MIYg1-0001gp-7d for grub-devel@gnu.org; Sun, 21 Jun 2009 21:50:33 -0400 Received: from [199.232.76.173] (port=51000 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MIYg1-0001ga-0v for grub-devel@gnu.org; Sun, 21 Jun 2009 21:50:29 -0400 Received: from c60.cesmail.net ([216.154.195.49]:3315) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_ARCFOUR_SHA1:16) (Exim 4.60) (envelope-from ) id 1MIYg0-0008Tm-ED for grub-devel@gnu.org; Sun, 21 Jun 2009 21:50:28 -0400 Received: from unknown (HELO smtprelay2.cesmail.net) ([192.168.1.112]) by c60.cesmail.net with ESMTP; 21 Jun 2009 21:50:27 -0400 Received: from [192.168.0.22] (static-72-92-88-10.phlapa.fios.verizon.net [72.92.88.10]) by smtprelay2.cesmail.net (Postfix) with ESMTPSA id B783A34C6A for ; Sun, 21 Jun 2009 21:56:29 -0400 (EDT) From: Pavel Roskin To: The development of GRUB 2 In-Reply-To: <20090621202224.GA25553@thorin> References: <20090621181748.GA21152@thorin> <20090621202224.GA25553@thorin> Content-Type: text/plain Date: Sun, 21 Jun 2009 21:50:25 -0400 Message-Id: <1245635425.9864.55.camel@mj> Mime-Version: 1.0 X-Mailer: Evolution 2.26.2 (2.26.2-1.fc11) Content-Transfer-Encoding: 7bit X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: [PATCH] i386-qemu port 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: Mon, 22 Jun 2009 01:50:33 -0000 On Sun, 2009-06-21 at 22:22 +0200, Robert Millan wrote: > New patch, after a bunch of misc cleanup, turning hardcoded numbers into > macros, improving comments, etc. kernel_img_FORMAT is defined but never used. GRUB_MEMORY_MACHINE_LINK_ADDR doesn't need to be conditional, it's the same for coreboot and qemu. Renaming kernel.elf to kernel.img could be done separately. Since it's a trivial patch, it can be committed without review provided that is compiles. Please don't add trailing whitespace. When compiling for coreboot, a warning appears: /home/proski/src/grub2.git/kern/i386/coreboot/init.c: In function 'grub_arch_modules_addr': /home/proski/src/grub2.git/kern/i386/coreboot/init.c:159: warning: return makes integer from pointer without a cast Compilation for qemu fails when compiling in a separate directory: /home/proski/src/grub2.git/boot/i386/qemu/boot.S:60:32: error: kern/i386/realmode.S: No such file or directory The fix is to use relative path to include realmode.S: #include "../../../kern/i386/realmode.S" Here's my fix for compile warnings and errors. Please incorporate. diff --git a/boot/i386/qemu/boot.S b/boot/i386/qemu/boot.S index 81cdc24..177453b 100644 --- a/boot/i386/qemu/boot.S +++ b/boot/i386/qemu/boot.S @@ -57,7 +57,7 @@ VARIABLE(grub_core_entry_addr) movl grub_core_entry_addr, %edx jmp *%edx -#include "kern/i386/realmode.S" +#include "../../../kern/i386/realmode.S" real_to_prot: .code16 diff --git a/kern/i386/coreboot/init.c b/kern/i386/coreboot/init.c index 89e1e58..8a27c2b 100644 --- a/kern/i386/coreboot/init.c +++ b/kern/i386/coreboot/init.c @@ -156,5 +156,5 @@ grub_addr_t grub_arch_modules_addr (void) { // return ALIGN_UP((grub_addr_t) _end, GRUB_MOD_ALIGN); - return _end; + return (grub_addr_t) _end; } -- Regards, Pavel Roskin