[Top] [All Lists]

Re: [PATCH] fix some compiler warnings (field width, unused variable)

Subject: Re: [PATCH] fix some compiler warnings (field width, unused variable)
From: Ulrich Eckhardt <>
Date: Wed, 7 Jun 2006 11:03:34 +0200
In-reply-to: <>
Organization: Sator Laser GmbH
Original-recipient: rfc822;
References: <> <> <>
User-agent: KMail/1.9.1
On Thursday 01 June 2006 18:54, Atsushi Nemoto wrote:
>                       printk("initrd extends beyond end of memory "
> -                            "(0x%0*Lx > 0x%0*Lx)\ndisabling initrd\n",
> -                            width,
> -                            (unsigned long long) CPHYSADDR(initrd_end),
> -                            width,
> -                            (unsigned long long) PFN_PHYS(max_low_pfn));
> +                            "(0x%p > 0x%p)\ndisabling initrd\n",
> +                            (void *)CPHYSADDR(initrd_end),
> +                            (void *)PFN_PHYS(max_low_pfn));

I'm not so sure if this is a good idea because some systems have 36 bit 
physical addresses while they only have 32 bit void pointers, so long long is 
probably really the better solution.

I'm wondering if it would be worth having a special flag in printk to indicate 
a physical address ("%lp" perhaps?) so that you don't get the unimportant 
leading zeroes for the bits 36 to 63 for above mentioned platforms.


Visit our website at <>
This Email and any files transmitted with it are confidential and intended 
solely for the use of the individual or entity to whom they are addressed. If 
you have received this Email in error please notify the system manager.

This footnote also confirms that this Email message has been swept by 
MailSweeper for the presence of computer viruses.

<Prev in Thread] Current Thread [Next in Thread>