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

video: fbdev-VIA: Deletion of an unnecessary check before the function call "framebuffer_release"

The framebuffer_release() 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 <elfring@users.sourceforge.net>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

authored by

Markus Elfring and committed by
Tomi Valkeinen
77284951 3163e4cd

+1 -2
+1 -2
drivers/video/fbdev/via/viafbdev.c
··· 1937 1937 out_dealloc_cmap: 1938 1938 fb_dealloc_cmap(&viafbinfo->cmap); 1939 1939 out_fb1_release: 1940 - if (viafbinfo1) 1941 - framebuffer_release(viafbinfo1); 1940 + framebuffer_release(viafbinfo1); 1942 1941 out_fb_release: 1943 1942 i2c_bus_free(viaparinfo->shared); 1944 1943 framebuffer_release(viafbinfo);