viafb: fix sparse warnings
authorHannes Eder <hannes@hanneseder.net>
Tue, 6 Jan 2009 22:42:32 +0000 (14:42 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 6 Jan 2009 23:59:26 +0000 (15:59 -0800)
Fix this sparse warnings:

  drivers/video/via/viafbdev.c:871:3: warning: returning void-valued expression
  drivers/video/via/viafbdev.c:938:3: warning: returning void-valued expression
  drivers/video/via/viafbdev.c:995:3: warning: returning void-valued expression

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
Cc: Krzysztof Helt <krzysztof.h1@poczta.fm>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/video/via/viafbdev.c

index e21fe5b6f9ffcaa739a3a8faef9dc7db0842cfc1..37b433a08ce8fcaf893b47dcff8719ae4d4d6033 100644 (file)
@@ -870,8 +870,10 @@ static void viafb_fillrect(struct fb_info *info,
        u32 col = 0, rop = 0;
        int pitch;
 
-       if (!viafb_accel)
-               return cfb_fillrect(info, rect);
+       if (!viafb_accel) {
+               cfb_fillrect(info, rect);
+               return;
+       }
 
        if (!rect->width || !rect->height)
                return;
@@ -937,8 +939,10 @@ static void viafb_copyarea(struct fb_info *info,
 
        DEBUG_MSG(KERN_INFO "viafb_copyarea!!\n");
 
-       if (!viafb_accel)
-               return cfb_copyarea(info, area);
+       if (!viafb_accel) {
+               cfb_copyarea(info, area);
+               return;
+       }
 
        if (!area->width || !area->height)
                return;
@@ -994,8 +998,10 @@ static void viafb_imageblit(struct fb_info *info,
        int i;
        int pitch;
 
-       if (!viafb_accel)
-               return cfb_imageblit(info, image);
+       if (!viafb_accel) {
+               cfb_imageblit(info, image);
+               return;
+       }
 
        udata = (u32 *) image->data;