public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH -mmotm] asiliantfb: fix ISO declaration/code warning
       [not found] <200902181018.n1IAISW7012483@imap1.linux-foundation.org>
@ 2009-02-18 19:12 ` Randy Dunlap
  2009-02-18 19:34   ` Andres Salomon
  0 siblings, 1 reply; 2+ messages in thread
From: Randy Dunlap @ 2009-02-18 19:12 UTC (permalink / raw)
  To: linux-kernel; +Cc: Andrew Morton, Andres Salomon

From: Randy Dunlap <randy.dunlap@oracle.com>

Move data declaration before any code:

drivers/video/asiliantfb.c:515: warning: ISO C90 forbids mixed declarations and code

(from asiliantfb-fix-cmap-memory-leaks.patch)

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
---
 drivers/video/asiliantfb.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- mmotm-2009-0218-0215.orig/drivers/video/asiliantfb.c
+++ mmotm-2009-0218-0215/drivers/video/asiliantfb.c
@@ -507,12 +507,13 @@ static struct fb_var_screeninfo asiliant
 
 static int __devinit init_asiliant(struct fb_info *p, unsigned long addr)
 {
+	int err;
+
 	p->fix			= asiliantfb_fix;
 	p->fix.smem_start	= addr;
 	p->var			= asiliantfb_var;
 	p->fbops		= &asiliantfb_ops;
 	p->flags		= FBINFO_DEFAULT;
-	int err;
 
 	err = fb_alloc_cmap(&p->cmap, 256, 0);
 	if (err) {


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

* Re: [PATCH -mmotm] asiliantfb: fix ISO declaration/code warning
  2009-02-18 19:12 ` [PATCH -mmotm] asiliantfb: fix ISO declaration/code warning Randy Dunlap
@ 2009-02-18 19:34   ` Andres Salomon
  0 siblings, 0 replies; 2+ messages in thread
From: Andres Salomon @ 2009-02-18 19:34 UTC (permalink / raw)
  To: Randy Dunlap; +Cc: linux-kernel, Andrew Morton

On Wed, 18 Feb 2009 11:12:54 -0800
Randy Dunlap <randy.dunlap@oracle.com> wrote:

> From: Randy Dunlap <randy.dunlap@oracle.com>
> 
> Move data declaration before any code:
> 
> drivers/video/asiliantfb.c:515: warning: ISO C90 forbids mixed
> declarations and code
> 
> (from asiliantfb-fix-cmap-memory-leaks.patch)
> 
> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>


Looks obviously correct to me.

Acked-by: Andres Salomon <dilinger@debian.org>


> ---
>  drivers/video/asiliantfb.c |    3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> --- mmotm-2009-0218-0215.orig/drivers/video/asiliantfb.c
> +++ mmotm-2009-0218-0215/drivers/video/asiliantfb.c
> @@ -507,12 +507,13 @@ static struct fb_var_screeninfo asiliant
>  
>  static int __devinit init_asiliant(struct fb_info *p, unsigned long
> addr) {
> +	int err;
> +
>  	p->fix			= asiliantfb_fix;
>  	p->fix.smem_start	= addr;
>  	p->var			= asiliantfb_var;
>  	p->fbops		= &asiliantfb_ops;
>  	p->flags		= FBINFO_DEFAULT;
> -	int err;
>  
>  	err = fb_alloc_cmap(&p->cmap, 256, 0);
>  	if (err) {
> 

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

end of thread, other threads:[~2009-02-18 19:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <200902181018.n1IAISW7012483@imap1.linux-foundation.org>
2009-02-18 19:12 ` [PATCH -mmotm] asiliantfb: fix ISO declaration/code warning Randy Dunlap
2009-02-18 19:34   ` Andres Salomon

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