Skip to content

Commit

Permalink
bcm2708_fb: remove unnecessary initialization of result
Browse files Browse the repository at this point in the history
static analysis by cppcheck detected an unnecessary initialization
of variable 'result' which is re-assigned almost immediately after
the initialization.  Remove the redundant initialization.

[drivers/video/fbdev/bcm2708_fb.c:406]: (performance) Variable
  'result' is reassigned a value before the old one has been used.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
  • Loading branch information
Colin Ian King authored and popcornmix committed Sep 14, 2015
1 parent 020b3c7 commit 51a3a0c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/video/fbdev/bcm2708_fb.c
Expand Up @@ -420,7 +420,7 @@ static int bcm2708_fb_blank(int blank_mode, struct fb_info *info)

static int bcm2708_fb_pan_display(struct fb_var_screeninfo *var, struct fb_info *info)
{
s32 result = -1;
s32 result;
info->var.xoffset = var->xoffset;
info->var.yoffset = var->yoffset;
result = bcm2708_fb_set_par(info);
Expand Down

0 comments on commit 51a3a0c

Please sign in to comment.