Re: [PATCH -next] PNP: fix printk format warnings
- From: Randy Dunlap <randy.dunlap@xxxxxxxxxx>
- Date: Wed, 30 Apr 2008 14:25:39 -0700
Joe Perches wrote:
On Wed, 2008-04-30 at 13:56 -0700, Randy Dunlap wrote:From: Randy Dunlap <randy.dunlap@xxxxxxxxxx>
next-20080430/drivers/pnp/pnpbios/rsparser.c:594: warning: format '%d' expects type 'int', but argument 4 has type 'resource_size_t'
next-20080430/drivers/pnp/pnpbios/rsparser.c:605: warning: format '%d' expects type 'int', but argument 4 has type 'resource_size_t'
resource_size_t can be u64
I know.
I think you need %llu/(unsigned long long)
So the interrupt number or DMA channel may be astronomically huge? OK.
Whatever.
--- next-20080430.orig/drivers/pnp/pnpbios/rsparser.c
+++ next-20080430/drivers/pnp/pnpbios/rsparser.c
@@ -591,7 +591,7 @@ static void pnpbios_encode_irq(struct pn
p[1] = map & 0xff;
p[2] = (map >> 8) & 0xff;
- dev_dbg(&dev->dev, " encode irq %d\n", res->start);
+ dev_dbg(&dev->dev, " encode irq %llu\n", (unsigned long long)res->start);
}
static void pnpbios_encode_dma(struct pnp_dev *dev, unsigned char *p,
@@ -602,7 +602,7 @@ static void pnpbios_encode_dma(struct pn
map = 1 << res->start;
p[1] = map & 0xff;
- dev_dbg(&dev->dev, " encode dma %d\n", res->start);
+ dev_dbg(&dev->dev, " encode dma %llu\n", (unsigned long long)res->start);
}
static void pnpbios_encode_port(struct pnp_dev *dev, unsigned char *p,
--
~Randy
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- References:
- [PATCH -next] PNP: fix printk format warnings
- From: Randy Dunlap
- Re: [PATCH -next] PNP: fix printk format warnings
- From: Joe Perches
- [PATCH -next] PNP: fix printk format warnings
- Prev by Date: Re: [2.6.26 PATCH, RESEND]: fs_stack/eCryptfs: fsstack_copy_* updates
- Next by Date: Re: [RFC][PATCH 3/5] Container Freezer: Implement freezer cgroup subsystem
- Previous by thread: Re: [PATCH -next] PNP: fix printk format warnings
- Next by thread: [no subject]
- Index(es):
Relevant Pages
|