public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
* Build warning in todays linus/master
@ 2011-03-21 11:01 Jamie Iles
  2011-03-21 11:40 ` Will Deacon
  2011-03-21 11:58 ` Russell King - ARM Linux
  0 siblings, 2 replies; 4+ messages in thread
From: Jamie Iles @ 2011-03-21 11:01 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Will,

I'm getting a build warning on todays master build for my V6K platform:

  CC      arch/arm/mm/mmu.o
arch/arm/mm/mmu.c: In function 'create_36bit_mapping':
arch/arm/mm/mmu.c:601:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
arch/arm/mm/mmu.c:614:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
arch/arm/mm/mmu.c:621:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
arch/arm/mm/mmu.c: In function 'create_mapping':
arch/arm/mm/mmu.c:662:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
arch/arm/mm/mmu.c:670:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
arch/arm/mm/mmu.c:690:10: warning: format '%08lx' expects type 'long unsigned int', but argument 2 has type 'unsigned int'

Which is introduced by (3a6b16 [ARM: 6675/1: use phys_addr_t instead of 
unsigned long in conversion code]), because phys_addr_t is a u32 
(!CONFIG_PHYS_ADDR_T_64BIT).  I guess a cast to u64 in the printk()'s in 
arch/arm/mm/mmu.c would fix these up, is that the right approach?

Jamie

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Build warning in todays linus/master
  2011-03-21 11:01 Build warning in todays linus/master Jamie Iles
@ 2011-03-21 11:40 ` Will Deacon
  2011-03-21 11:50   ` Jamie Iles
  2011-03-21 11:58 ` Russell King - ARM Linux
  1 sibling, 1 reply; 4+ messages in thread
From: Will Deacon @ 2011-03-21 11:40 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Jamie,

> I'm getting a build warning on todays master build for my V6K platform:
> 
>   CC      arch/arm/mm/mmu.o
> arch/arm/mm/mmu.c: In function 'create_36bit_mapping':
> arch/arm/mm/mmu.c:601:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:614:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:621:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> 2 has type 'unsigned int'
> arch/arm/mm/mmu.c: In function 'create_mapping':
> arch/arm/mm/mmu.c:662:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:670:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:690:10: warning: format '%08lx' expects type 'long unsigned int', but argument 2 has
> type 'unsigned int'
> 
> Which is introduced by (3a6b16 [ARM: 6675/1: use phys_addr_t instead of
> unsigned long in conversion code]), because phys_addr_t is a u32
> (!CONFIG_PHYS_ADDR_T_64BIT).  I guess a cast to u64 in the printk()'s in
> arch/arm/mm/mmu.c would fix these up, is that the right approach?

It looks like one of the LPAE preparation patches has been merged
(i.e. the one which replaces unsigned long with phys_addr_t) but the
conversion specifier fixes are not yet in mainline, although they do
live in -next.

It's unfortunate that this generates warnings but I don't think you
can avoid the ordering requirements of these patches.

For now, you could try cherry-picking the rest of that patch series
from -next:

ad6b9c9 ARM: 6671/1: LPAE: use phys_addr_t instead of unsigned long in outercache functions
cae6292 ARM: 6672/1: LPAE: use phys_addr_t instead of unsigned long in mapping functions
f60892d ARM: 6673/1: LPAE: use phys_addr_t instead of unsigned long for start of membanks
29a3819 ARM: 6674/1: LPAE: use long long format when printing physical addresses and ptes

These are all in Russell's -devel branch so hopefully they'll find their
way upstream soon.

Thanks for spotting this,

Will

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Build warning in todays linus/master
  2011-03-21 11:40 ` Will Deacon
@ 2011-03-21 11:50   ` Jamie Iles
  0 siblings, 0 replies; 4+ messages in thread
From: Jamie Iles @ 2011-03-21 11:50 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Mar 21, 2011 at 11:40:52AM -0000, Will Deacon wrote:
> Hi Jamie,
> 
> > I'm getting a build warning on todays master build for my V6K platform:
> > 
> >   CC      arch/arm/mm/mmu.o
> > arch/arm/mm/mmu.c: In function 'create_36bit_mapping':
> > arch/arm/mm/mmu.c:601:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> > 2 has type 'unsigned int'
> > arch/arm/mm/mmu.c:614:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> > 2 has type 'unsigned int'
> > arch/arm/mm/mmu.c:621:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> > 2 has type 'unsigned int'
> > arch/arm/mm/mmu.c: In function 'create_mapping':
> > arch/arm/mm/mmu.c:662:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> > 2 has type 'unsigned int'
> > arch/arm/mm/mmu.c:670:10: warning: format '%08llx' expects type 'long long unsigned int', but argument
> > 2 has type 'unsigned int'
> > arch/arm/mm/mmu.c:690:10: warning: format '%08lx' expects type 'long unsigned int', but argument 2 has
> > type 'unsigned int'
> > 
> > Which is introduced by (3a6b16 [ARM: 6675/1: use phys_addr_t instead of
> > unsigned long in conversion code]), because phys_addr_t is a u32
> > (!CONFIG_PHYS_ADDR_T_64BIT).  I guess a cast to u64 in the printk()'s in
> > arch/arm/mm/mmu.c would fix these up, is that the right approach?
> 
> It looks like one of the LPAE preparation patches has been merged
> (i.e. the one which replaces unsigned long with phys_addr_t) but the
> conversion specifier fixes are not yet in mainline, although they do
> live in -next.

Ahh, I thought I'd seen something like that on the lists before but 
obviously couldn't find the right one!  Thanks for pointing me at the 
right patches though.

Jamie

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Build warning in todays linus/master
  2011-03-21 11:01 Build warning in todays linus/master Jamie Iles
  2011-03-21 11:40 ` Will Deacon
@ 2011-03-21 11:58 ` Russell King - ARM Linux
  1 sibling, 0 replies; 4+ messages in thread
From: Russell King - ARM Linux @ 2011-03-21 11:58 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Mar 21, 2011 at 11:01:05AM +0000, Jamie Iles wrote:
> Hi Will,
> 
> I'm getting a build warning on todays master build for my V6K platform:
> 
>   CC      arch/arm/mm/mmu.o
> arch/arm/mm/mmu.c: In function 'create_36bit_mapping':
> arch/arm/mm/mmu.c:601:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:614:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:621:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
> arch/arm/mm/mmu.c: In function 'create_mapping':
> arch/arm/mm/mmu.c:662:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:670:10: warning: format '%08llx' expects type 'long long unsigned int', but argument 2 has type 'unsigned int'
> arch/arm/mm/mmu.c:690:10: warning: format '%08lx' expects type 'long unsigned int', but argument 2 has type 'unsigned int'
> 
> Which is introduced by (3a6b16 [ARM: 6675/1: use phys_addr_t instead of 
> unsigned long in conversion code]), because phys_addr_t is a u32 
> (!CONFIG_PHYS_ADDR_T_64BIT).  I guess a cast to u64 in the printk()'s in 
> arch/arm/mm/mmu.c would fix these up, is that the right approach?

Please leave well alone until I've merged everything in my tree.  Thanks.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-03-21 11:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-21 11:01 Build warning in todays linus/master Jamie Iles
2011-03-21 11:40 ` Will Deacon
2011-03-21 11:50   ` Jamie Iles
2011-03-21 11:58 ` Russell King - ARM Linux

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox