From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1LoPOG-00018l-Mg for mharc-grub-devel@gnu.org; Mon, 30 Mar 2009 17:51:32 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LoPOF-000181-4X for grub-devel@gnu.org; Mon, 30 Mar 2009 17:51:31 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LoPOA-00015D-FY for grub-devel@gnu.org; Mon, 30 Mar 2009 17:51:30 -0400 Received: from [199.232.76.173] (port=52740 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LoPOA-000158-4P for grub-devel@gnu.org; Mon, 30 Mar 2009 17:51:26 -0400 Received: from c60.cesmail.net ([216.154.195.49]:51782) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_ARCFOUR_SHA1:16) (Exim 4.60) (envelope-from ) id 1LoPO9-00075K-OP for grub-devel@gnu.org; Mon, 30 Mar 2009 17:51:25 -0400 Received: from unknown (HELO smtprelay2.cesmail.net) ([192.168.1.112]) by c60.cesmail.net with ESMTP; 30 Mar 2009 17:51:24 -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 CD7FB34C6A for ; Mon, 30 Mar 2009 17:52:10 -0400 (EDT) From: Pavel Roskin To: The development of GRUB 2 In-Reply-To: <200903310106.25852.okuji@enbug.org> References: <20090306195735.GA9992@thorin> <1238419927.2868.6.camel@mj> <49D0D8C8.4010801@gmail.com> <200903310106.25852.okuji@enbug.org> Content-Type: text/plain Date: Mon, 30 Mar 2009 17:51:22 -0400 Message-Id: <1238449882.6004.50.camel@mj> Mime-Version: 1.0 X-Mailer: Evolution 2.24.5 (2.24.5-1.fc10) Content-Transfer-Encoding: 7bit X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: [PATCH] build 32-bit Linux loader as `linux', rename legacy loader to `linux16' 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, 30 Mar 2009 21:51:31 -0000 On Tue, 2009-03-31 at 01:06 +0900, Yoshinori K. Okuji wrote: > On Monday 30 March 2009 23:35:52 phcoder wrote: > > I confirm. I suppose that this check and message is bypassed with 32-bit > > loading mode. IMO grub2 should provide an equivlent of this check. We > > already have cpuid code. Does anyone know how to determine if kernel is > > i386 or amd64? > > I don't know any reliable way. Some candidates: > > - The ramdisk max value. On 32-bit, initrd may not be loaded onto over 2GB. > This is hard to change in Linux, so we can expect that this will not change. If we are circumventing the standard Linux bootloader, perhaps we should communicate this to the Linux developers. To check architecture in GRUB, we need one bit of information, but that bit should be reliable. Also, it looks like Linux on x86_64 does an extra validation of the CPU in arch/x86/boot/compressed/head_64.S, but if the long mode is not supported, it hangs without printing an error message. -- Regards, Pavel Roskin