Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

intelfb: fix sparse warnings

Fix this sparse warnings:

drivers/video/intelfb/intelfbdrv.c:1497:3: warning: returning void-valued expression
drivers/video/intelfb/intelfbdrv.c:1525:3: warning: returning void-valued expression
drivers/video/intelfb/intelfbdrv.c:1544:3: warning: returning void-valued expression
drivers/video/intelfb/intelfbdrv.c:1558: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>

authored by

Hannes Eder and committed by
Linus Torvalds
fd002050 4fa34cd0

+16 -8
+16 -8
drivers/video/intelfb/intelfbdrv.c
··· 1493 1493 DBG_MSG("intelfb_fillrect\n"); 1494 1494 #endif 1495 1495 1496 - if (!ACCEL(dinfo, info) || dinfo->depth == 4) 1497 - return cfb_fillrect(info, rect); 1496 + if (!ACCEL(dinfo, info) || dinfo->depth == 4) { 1497 + cfb_fillrect(info, rect); 1498 + return; 1499 + } 1498 1500 1499 1501 if (rect->rop == ROP_COPY) 1500 1502 rop = PAT_ROP_GXCOPY; ··· 1523 1521 DBG_MSG("intelfb_copyarea\n"); 1524 1522 #endif 1525 1523 1526 - if (!ACCEL(dinfo, info) || dinfo->depth == 4) 1527 - return cfb_copyarea(info, region); 1524 + if (!ACCEL(dinfo, info) || dinfo->depth == 4) { 1525 + cfb_copyarea(info, region); 1526 + return; 1527 + } 1528 1528 1529 1529 intelfbhw_do_bitblt(dinfo, region->sx, region->sy, region->dx, 1530 1530 region->dy, region->width, region->height, ··· 1544 1540 #endif 1545 1541 1546 1542 if (!ACCEL(dinfo, info) || dinfo->depth == 4 1547 - || image->depth != 1) 1548 - return cfb_imageblit(info, image); 1543 + || image->depth != 1) { 1544 + cfb_imageblit(info, image); 1545 + return; 1546 + } 1549 1547 1550 1548 if (dinfo->depth != 8) { 1551 1549 fgcolor = dinfo->pseudo_palette[image->fg_color]; ··· 1560 1554 if (!intelfbhw_do_drawglyph(dinfo, fgcolor, bgcolor, image->width, 1561 1555 image->height, image->data, 1562 1556 image->dx, image->dy, 1563 - dinfo->pitch, info->var.bits_per_pixel)) 1564 - return cfb_imageblit(info, image); 1557 + dinfo->pitch, info->var.bits_per_pixel)) { 1558 + cfb_imageblit(info, image); 1559 + return; 1560 + } 1565 1561 } 1566 1562 1567 1563 static int intelfb_cursor(struct fb_info *info, struct fb_cursor *cursor)