Linux PARISC architecture development
 help / color / mirror / Atom feed
From: Helge Deller <deller@gmx.de>
To: John David Anglin <dave@hiauly1.hia.nrc.ca>
Cc: Guy Martin <gmsoft@tuxicoman.be>,
	carlos@systemhalted.org, grundler@parisc-linux.org,
	linux-parisc@vger.kernel.org
Subject: Re: 2.6.28-rcX in pretty bad shape on parisc
Date: Sun, 30 Nov 2008 22:03:51 +0100	[thread overview]
Message-ID: <4932FFB7.4040506@gmx.de> (raw)
In-Reply-To: <20081130202443.7B1154FB4@hiauly1.hia.nrc.ca>

John David Anglin wrote:
> Hi,
> 
> I just pulled and built Kyle's parisc-2.6 tree.  It essentially 2.6.28-rc6
> plus four extra patches (three parisc specific).
> 
> I am seeing these warnings in a 64-bit kernel build:
> 
> drivers/input/keyboard/hilkbd.c: In function 'hil_init_chip':
> drivers/input/keyboard/hilkbd.c:317: warning: format '%08lx' expects type 'long unsigned int', but argument 2 has type 'resource_size_t'
> 
> drivers/net/lasi_82596.c: In function 'lan_init_chip':
> drivers/net/lasi_82596.c:164: warning: format '%lx' expects type 'long unsigned 
> int', but argument 3 has type 'resource_size_t'
> drivers/net/lasi_82596.c:169: warning: format '%lx' expects type 'long unsigned 
> int', but argument 2 has type 'resource_size_t'
> 
> drivers/parisc/ccio-dma.c: In function 'ccio_init_resource':
> drivers/parisc/ccio-dma.c:1403: warning: format '%08lx' expects type 'long unsig
> ned int', but argument 3 has type 'resource_size_t'drivers/parisc/ccio-dma.c:1403: warning: format '%08lx' expects type 'long unsigned int', but argument 4 has type 'resource_size_t'
> drivers/parisc/ccio-dma.c: In function 'ccio_probe':
> drivers/parisc/ccio-dma.c:1554: warning: format '%lx' expects type 'long unsigned int', but argument 3 has type 'resource_size_t'
> 
> drivers/parisc/hppb.c: In function 'hppb_probe':
> drivers/parisc/hppb.c:65: warning: format '%x' expects type 'unsigned int', but argument 2 has type 'resource_size_t'
> drivers/parisc/hppb.c:77: warning: format '%08x' expects type 'unsigned int', but argument 3 has type 'resource_size_t'
> drivers/parisc/hppb.c:77: warning: format '%08x' expects type 'unsigned int', but argument 4 has type 'resource_size_t'
> 
> drivers/parisc/dino.c:822: warning: format '%lx' expects type 'long unsigned int', but argument 4 has type 'resource_size_t'
> drivers/parisc/dino.c:822: warning: format '%lx' expects type 'long unsigned int', but argument 5 has type 'resource_size_t'
> drivers/parisc/dino.c: In function 'dino_common_init':
> drivers/parisc/dino.c:902: warning: format '%lx' expects type 'long unsigned int', but argument 3 has type 'resource_size_t'
> drivers/parisc/dino.c:902: warning: format '%lx' expects type 'long unsigned int', but argument 4 has type 'resource_size_t'
> 
> drivers/parisc/asp.c: In function 'asp_init_chip':
> drivers/parisc/asp.c:85: warning: format '%lx' expects type 'long unsigned int', but argument 4 has type 'resource_size_t'
> 
> drivers/parport/parport_gsc.c: In function 'parport_init_chip':
> drivers/parport/parport_gsc.c:356: warning: format '%lx' expects type 'long unsigned int', but argument 2 has type 'resource_size_t'
> 
> drivers/serial/8250_gsc.c: In function 'serial_init_chip':
> drivers/serial/8250_gsc.c:44: warning: format '%lx' expects type 'long unsigned 
> int', but argument 2 has type 'resource_size_t'
> 
> sound/parisc/harmony.c: In function 'snd_harmony_create':
> sound/parisc/harmony.c:938: warning: format '%lx' expects type 'long unsigned in
> t', but argument 2 has type 'resource_size_t'
> 
> 'resource_size_t' is defined in linux/types.h:
> 
> #ifdef CONFIG_PHYS_ADDR_T_64BIT
> typedef u64 phys_addr_t;
> #else
> typedef u32 phys_addr_t;
> #endif
> 
> typedef phys_addr_t resource_size_t;
> 
> CONFIG_PHYS_ADDR_T_64BIT is defined in linux/autoconf.h, so I have to think
> it is not being included, resulting in incorrect defines for phys_addr_t.
> Is this what needs to be done?

Citing Documentation/printk-formats.txt:
If <type> is dependent on a config option for its size (e.g., sector_t,
blkcnt_t, phys_addr_t, resource_size_t) or is architecture-dependent
for its size (e.g., tcflag_t), use a format specifier of its largest
possible type and explicitly cast to it.  Example:

         printk("test: sector number/total blocks: %llu/%llu\n",
                 (unsigned long long)sector, (unsigned long 
long)blockcount);

So, we should convert everything to (unsigned long long).
I was planning to send such patches soon, but didn't had time yet.

Helge


  reply	other threads:[~2008-11-30 21:03 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-18 20:04 2.6.28-rcX in pretty bad shape on parisc Helge Deller
2008-11-19  1:33 ` Thibaut VARENE
2008-11-19 15:47   ` Helge Deller
2008-11-19  2:31 ` James Bottomley
2008-11-19  9:13   ` Domenico Andreoli
2008-11-19 14:20     ` James Bottomley
2008-11-19 15:12       ` John David Anglin
2008-11-19 16:25     ` Helge Deller
2008-11-19 18:13       ` Helge Deller
2008-11-20  7:55       ` Helge Deller
2008-11-20 12:57         ` Thibaut VARENE
2008-11-20 15:14         ` John David Anglin
2008-11-20  3:51   ` John David Anglin
2008-11-20 16:57     ` John David Anglin
2008-11-22  5:57       ` Grant Grundler
2008-11-22  6:14         ` Grant Grundler
2008-11-22 19:48           ` John David Anglin
2008-11-22 21:37             ` John David Anglin
2008-11-22 23:01               ` James Bottomley
2008-11-23 16:54                 ` John David Anglin
2008-11-22  6:11   ` Grant Grundler
2008-11-23  7:13 ` Grant Grundler
2008-11-23 16:36   ` John David Anglin
2008-11-23 16:57     ` John David Anglin
2008-11-25  2:54       ` John David Anglin
2008-11-25 13:33         ` Carlos O'Donell
2008-11-25 13:58           ` Guy Martin
2008-11-25 14:07             ` Carlos O'Donell
2008-11-26 17:51               ` Guy Martin
2008-11-30 20:24                 ` John David Anglin
2008-11-30 21:03                   ` Helge Deller [this message]
2008-12-02  0:00                     ` John David Anglin
2008-12-01 10:54                       ` Thibaut VARENE
2008-12-03 20:41                         ` Helge Deller
2008-12-08  5:15                         ` Kyle McMartin
2008-12-08 15:23                           ` John David Anglin
2008-12-08 15:34                             ` Kyle McMartin
2008-12-08 15:57                               ` John David Anglin
2008-12-08 16:00                                 ` Kyle McMartin
2008-12-08 16:00                                   ` Kyle McMartin
2008-12-09  3:44                                     ` resource_size_t printk woes Kyle McMartin
2008-12-10  4:05                                       ` John David Anglin
2009-01-01 13:06                                         ` Helge Deller
2009-01-01 17:14                                           ` John David Anglin
2009-01-01 17:32                                             ` Helge Deller
2009-01-01 19:04                                               ` John David Anglin
2009-01-01 22:37                                                 ` John David Anglin
2009-01-01 23:39                                                   ` John David Anglin
2009-01-02  9:14                                                     ` Helge Deller
2009-01-02 16:32                                                       ` John David Anglin
2009-01-02 16:43                                                       ` John David Anglin
2009-01-02 19:50                                                         ` Grant Grundler
2008-12-08  4:50           ` 2.6.28-rcX in pretty bad shape on parisc John David Anglin
2008-12-08  7:50             ` Grant Grundler
2008-12-08 15:16               ` John David Anglin
2008-12-09  4:14               ` Kyle McMartin
2008-12-08 12:39             ` Carlos O'Donell
2008-12-08 14:54               ` John David Anglin
2008-12-08 15:02                 ` Carlos O'Donell
2008-12-08 15:30                   ` John David Anglin
2008-12-08 22:14                   ` Carlos O'Donell
2008-12-08 22:39                     ` John David Anglin
2008-12-09  0:01                       ` Carlos O'Donell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4932FFB7.4040506@gmx.de \
    --to=deller@gmx.de \
    --cc=carlos@systemhalted.org \
    --cc=dave@hiauly1.hia.nrc.ca \
    --cc=gmsoft@tuxicoman.be \
    --cc=grundler@parisc-linux.org \
    --cc=linux-parisc@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox