From e87d9f295a7f3e9e7aae7a64f8fa9b45ceb1bf1c Mon Sep 17 00:00:00 2001 From: Markus Elfring Date: Sun, 23 Nov 2014 11:00:26 +0100 Subject: video: uvesafb: Deletion of an unnecessary check before the function call "uvesafb_free" The uvesafb_free() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Signed-off-by: Tomi Valkeinen --- drivers/video/fbdev/uvesafb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'drivers/video/fbdev/uvesafb.c') diff --git a/drivers/video/fbdev/uvesafb.c b/drivers/video/fbdev/uvesafb.c index 509d452e8f91..f718627b368f 100644 --- a/drivers/video/fbdev/uvesafb.c +++ b/drivers/video/fbdev/uvesafb.c @@ -1219,8 +1219,7 @@ static int uvesafb_release(struct fb_info *info, int user) uvesafb_vbe_state_restore(par, par->vbe_state_orig); out: atomic_dec(&par->ref_count); - if (task) - uvesafb_free(task); + uvesafb_free(task); return 0; } -- cgit v1.2.3