staging: sm750fb: remove unnecessary goto
PATCH 1/1 staging: sm750fb: remove unnecessary goto
The goto exit statement jumps directly to the following label. Remove the unnecessary jump and label, and simplify the conditional block.
Signed-off-by Haasham Khan <[email protected]>
--- drivers/staging/sm750fb/sm750.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/staging/sm750fb/sm750.c +1 -4
@@ -815,12 +815,9 @@ static int lynxfb_set_fbinfo(struct fb_info *info, int index) var->vmode =FB_VMODE_NONINTERLACED ; ret =fb_alloc_cmap (&info->cmap,256 ,0 ); -if (ret <0 ) { +if (ret <0 )dev_err (info->device,"Could not allocate memory for cmap.\n" ); - goto exit; - } -exit:lynxfb_ops_check_var (var, info);return ret; }
Signature · 1 line
2.53.0