From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rusty Russell Subject: Re: [patches] [PATCH] [21/22] x86_64: Extend bzImage protocol for relocatable bzImage Date: Tue, 01 May 2007 13:59:41 +1000 Message-ID: <1177991981.28659.44.camel@localhost.localdomain> References: <20070428758.455116000@suse.de> <20070428175909.1D09D151CA@wotan.suse.de> <46338D72.70402@garzik.org> <4634483E.9030307@goop.org> <1177902195.30071.203.camel@localhost.localdomain> <463572B7.90202@zytor.com> <1177909434.30071.216.camel@localhost.localdomain> <1177990722.28659.39.camel@localhost.localdomain> <4636B7DE.5050005@zytor.com> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4636B7DE.5050005@zytor.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: virtualization-bounces@lists.linux-foundation.org Errors-To: virtualization-bounces@lists.linux-foundation.org To: "H. Peter Anvin" Cc: Jeff Garzik , patches@x86-64.org, linux-kernel@vger.kernel.org, Vivek Goyal , "Eric W. Biederman" , virtualization List-Id: virtualization@lists.linuxfoundation.org On Mon, 2007-04-30 at 20:45 -0700, H. Peter Anvin wrote: > Rusty Russell wrote: > > > > It'd be nicer if there were a "struct boot_params" declaration, but we > > can't have everything. > > It's in my patchset-under-development. Ah ha: excellent! > > +typedef unsigned long long u64; > > typedef uint32_t u32; > > typedef uint16_t u16; > > typedef uint8_t u8; > > Why not uint64_t to go along with all the other defines? Because then it's a PITA to printf(): x86-64 has uint64_t as "unsigned long". So the lguest64 guys will add all kinds of horrible casts. This has the same effect, but ironically is more portable. Rusty. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1946488AbXEAECG (ORCPT ); Tue, 1 May 2007 00:02:06 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1946440AbXEAEBt (ORCPT ); Tue, 1 May 2007 00:01:49 -0400 Received: from ozlabs.org ([203.10.76.45]:41453 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1946506AbXEAEAB (ORCPT ); Tue, 1 May 2007 00:00:01 -0400 Subject: Re: [patches] [PATCH] [21/22] x86_64: Extend bzImage protocol for relocatable bzImage From: Rusty Russell To: "H. Peter Anvin" Cc: "Eric W. Biederman" , Jeremy Fitzhardinge , Jeff Garzik , Andi Kleen , patches@x86-64.org, Vivek Goyal , linux-kernel@vger.kernel.org, virtualization In-Reply-To: <4636B7DE.5050005@zytor.com> References: <20070428758.455116000@suse.de> <20070428175909.1D09D151CA@wotan.suse.de> <46338D72.70402@garzik.org> <4634483E.9030307@goop.org> <1177902195.30071.203.camel@localhost.localdomain> <463572B7.90202@zytor.com> <1177909434.30071.216.camel@localhost.localdomain> <1177990722.28659.39.camel@localhost.localdomain> <4636B7DE.5050005@zytor.com> Content-Type: text/plain Date: Tue, 01 May 2007 13:59:41 +1000 Message-Id: <1177991981.28659.44.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.10.1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2007-04-30 at 20:45 -0700, H. Peter Anvin wrote: > Rusty Russell wrote: > > > > It'd be nicer if there were a "struct boot_params" declaration, but we > > can't have everything. > > It's in my patchset-under-development. Ah ha: excellent! > > +typedef unsigned long long u64; > > typedef uint32_t u32; > > typedef uint16_t u16; > > typedef uint8_t u8; > > Why not uint64_t to go along with all the other defines? Because then it's a PITA to printf(): x86-64 has uint64_t as "unsigned long". So the lguest64 guys will add all kinds of horrible casts. This has the same effect, but ironically is more portable. Rusty.