[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080726150155.GA3562@localhost.localdomain>
Date: Sun, 27 Jul 2008 00:02:20 +0900
From: Akinobu Mita <akinobu.mita@...il.com>
To: Russell King - ARM Linux <linux@....linux.org.uk>
Cc: akpm@...ux-foundation.org, torvalds@...ux-foundation.org,
tim@...sik3.uni-rostock.de, linux-kernel@...r.kernel.org
Subject: [PATCH] nwflash: fix build errors and warning
On Sat, Jul 26, 2008 at 03:18:08PM +0100, Russell King - ARM Linux wrote:
> On Fri, Jul 25, 2008 at 01:48:18AM -0700, akpm@...ux-foundation.org wrote:
> > From: Akinobu Mita <akinobu.mita@...il.com>
> >
> > Signed-off-by: Akinobu Mita <akinobu.mita@...il.com>
> > Cc: Russell King <linux@....linux.org.uk>
> > Cc: Tim Schmielau <tim@...sik3.uni-rostock.de>
> > Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
>
> Argh... Are people now submitting untested patches as a rule?
>
> drivers/char/nwflash.c: In function 'flash_read':
> drivers/char/nwflash.c:129: error: 'p' undeclared (first use in this function)
> drivers/char/nwflash.c:129: error: (Each undeclared identifier is reported only once
> drivers/char/nwflash.c:129: error: for each function it appears in.)
> drivers/char/nwflash.c:129: error: 'count' undeclared (first use in this function)
> drivers/char/nwflash.c:136: warning: passing argument 4 of 'simple_read_from_buffer' discards qualifiers from pointer target type
> make[2]: *** [drivers/char/nwflash.o] Error 1
> make[1]: *** [drivers/char] Error 2
> make: *** [drivers] Error 2
Sorry. I'm preparing cross compiler. But this patch should fix this
problem.
From: Akinobu Mita <akinobu.mita@...il.com>
Subject: nwflash: fix build errors and warning
The commit 6ee8928d94841aa764aeaf645ad16daff811dc26
(nwflash: use simple_read_from_buffer()) broke nwflash.
drivers/char/nwflash.c: In function 'flash_read':
drivers/char/nwflash.c:129: error: 'p' undeclared (first use in this function)
drivers/char/nwflash.c:129: error: (Each undeclared identifier is reported only once
drivers/char/nwflash.c:129: error: for each function it appears in.)
drivers/char/nwflash.c:129: error: 'count' undeclared (first use in this function)
drivers/char/nwflash.c:136: warning: passing argument 4 of 'simple_read_from_buffer' discards qualifiers from pointer target type
make[2]: *** [drivers/char/nwflash.o] Error 1
make[1]: *** [drivers/char] Error 2
make: *** [drivers] Error 2
Signed-off-by: Akinobu Mita <akinobu.mita@...il.com>
---
drivers/char/nwflash.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
Index: 2.6-mm/drivers/char/nwflash.c
===================================================================
--- 2.6-mm.orig/drivers/char/nwflash.c
+++ 2.6-mm/drivers/char/nwflash.c
@@ -126,14 +126,15 @@ static ssize_t flash_read(struct file *f
if (flashdebug)
printk(KERN_DEBUG "flash_read: flash_read: offset=0x%lX, "
- "buffer=%p, count=0x%X.\n", p, buf, count);
+ "buffer=%p, count=0x%zX.\n", *ppos, buf, size);
/*
* We now lock against reads and writes. --rmk
*/
if (mutex_lock_interruptible(&nwflash_mutex))
return -ERESTARTSYS;
- ret = simple_read_from_buffer(buf, size, ppos, FLASH_BASE, gbFlashSize);
+ ret = simple_read_from_buffer(buf, size, ppos, (void *)FLASH_BASE,
+ gbFlashSize);
mutex_unlock(&nwflash_mutex);
return ret;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists