diff options
author | Sudip Mukherjee <sudipm.mukherjee@gmail.com> | 2015-01-06 07:45:02 -0500 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2015-01-13 06:29:22 -0500 |
commit | 9cb13ba4355936b9c4f8eb3792bff6654e33ed5e (patch) | |
tree | e4ec3bf1319429029ea0104f33ac931389c19d42 /drivers/video | |
parent | 96699b4004f40cc0006794ff0f63ba841a4427fe (diff) |
fbdev: geocode: remove unneeded NULL check
the check for info is not required as we are checking it immediately
after gxfb_init_fbinfo() and lxfb_init_fbinfo() and returnig -ENOMEM
if it is NULL.
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/fbdev/geode/gxfb_core.c | 6 | ||||
-rw-r--r-- | drivers/video/fbdev/geode/lxfb_core.c | 6 |
2 files changed, 4 insertions, 8 deletions
diff --git a/drivers/video/fbdev/geode/gxfb_core.c b/drivers/video/fbdev/geode/gxfb_core.c index 1790f14bab15..124d7c7e2d14 100644 --- a/drivers/video/fbdev/geode/gxfb_core.c +++ b/drivers/video/fbdev/geode/gxfb_core.c | |||
@@ -444,10 +444,8 @@ static int gxfb_probe(struct pci_dev *pdev, const struct pci_device_id *id) | |||
444 | pci_release_region(pdev, 1); | 444 | pci_release_region(pdev, 1); |
445 | } | 445 | } |
446 | 446 | ||
447 | if (info) { | 447 | fb_dealloc_cmap(&info->cmap); |
448 | fb_dealloc_cmap(&info->cmap); | 448 | framebuffer_release(info); |
449 | framebuffer_release(info); | ||
450 | } | ||
451 | return ret; | 449 | return ret; |
452 | } | 450 | } |
453 | 451 | ||
diff --git a/drivers/video/fbdev/geode/lxfb_core.c b/drivers/video/fbdev/geode/lxfb_core.c index 9e1d19d673a1..138da6cb6cbc 100644 --- a/drivers/video/fbdev/geode/lxfb_core.c +++ b/drivers/video/fbdev/geode/lxfb_core.c | |||
@@ -577,10 +577,8 @@ err: | |||
577 | pci_release_region(pdev, 3); | 577 | pci_release_region(pdev, 3); |
578 | } | 578 | } |
579 | 579 | ||
580 | if (info) { | 580 | fb_dealloc_cmap(&info->cmap); |
581 | fb_dealloc_cmap(&info->cmap); | 581 | framebuffer_release(info); |
582 | framebuffer_release(info); | ||
583 | } | ||
584 | 582 | ||
585 | return ret; | 583 | return ret; |
586 | } | 584 | } |