From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1IgI7a-0004Wc-Nb for mharc-grub-devel@gnu.org; Fri, 12 Oct 2007 06:51:58 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IgI7Y-0004Uo-91 for grub-devel@gnu.org; Fri, 12 Oct 2007 06:51:56 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IgI7W-0004Rj-5Z for grub-devel@gnu.org; Fri, 12 Oct 2007 06:51:54 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IgI7V-0004RF-Vr for grub-devel@gnu.org; Fri, 12 Oct 2007 06:51:54 -0400 Received: from smtp-vbr2.xs4all.nl ([194.109.24.22]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IgI7V-0008DC-Eo for grub-devel@gnu.org; Fri, 12 Oct 2007 06:51:53 -0400 Received: from localhost.localdomain (249-174.surfsnel.dsl.internl.net [145.99.174.249]) by smtp-vbr2.xs4all.nl (8.13.8/8.13.8) with ESMTP id l9CApmK3008234 for ; Fri, 12 Oct 2007 12:51:49 +0200 (CEST) (envelope-from mgerards@xs4all.nl) From: Marco Gerards To: The development of GRUB 2 References: <20071001145354.GA1483@thorin> <20071011225845.GA3512@thorin> Mail-Copies-To: mgerards@xs4all.nl Date: Fri, 12 Oct 2007 12:52:42 +0200 In-Reply-To: <20071011225845.GA3512@thorin> (Robert Millan's message of "Fri, 12 Oct 2007 00:58:45 +0200") Message-ID: <87r6k0vc3p.fsf@xs4all.nl> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by XS4ALL Virus Scanner X-detected-kernel: by monty-python.gnu.org: FreeBSD 4.6-4.9 Subject: Re: [PATCH] generic ELF version of grub-mkimage 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: Fri, 12 Oct 2007 10:51:56 -0000 Robert Millan writes: > Woops. I've been pointed out that cross-compiles were actually working and > should be preserved. I propose this new patch which integrates endianess > conversion macros with include/grub/types.h. > > -- > 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 /.) > > 2007-10-12 Robert Millan > > * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference > to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c. > > * include/grub/types.h (#ifdef GRUB_CPU_WORDS_BIGENDIAN): Define > grub_host_to_target16, grub_host_to_target32, grub_host_to_target64, > grub_target_to_host16, grub_target_to_host32 and grub_target_to_host64. > (#else): Likewise. This syntax is wrong. It should have been something like: > * include/grub/types.h (#ifdef GRUB_CPU_WORDS_BIGENDIAN): Define > grub_host_to_target16, grub_host_to_target32, grub_host_to_target64, > grub_target_to_host16, grub_target_to_host32 and grub_target_to_host64. > (#else): Likewise. * include/grub/types.h (grub_host_to_target16): New macro. (grub_host_to_target32): Likewise. etc... If you are not sure, better wait a few days before committing a patch. Or ask me to double check it. > * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN): > Renamed from to ... > (GRUB_MOD_ALIGN): ...this. Update all users. > > * util/elf/grub-mkimage.c: Replace grub_cpu_to_be16, grub_cpu_to_be32, > grub_be_to_cpu16 and grub_be_to_cpu32 macros with grub_host_to_target16, > grub_host_to_target32, grub_target_to_host16 and grub_target_to_host32, > respectively. You know quite well that this is wrong. You have to mention which function you changed. If you use diff -up this is easy to see from the patch. -- Marco