video: fbdev: cobalt_lcdfb: Handle return NULL error from devm_ioremap
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Tue, 13 Dec 2016 08:20:52 +0000 (13:50 +0530)
committerBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Wed, 4 Jan 2017 11:58:45 +0000 (12:58 +0100)
commit4dcd19bfabaee8f9f4bcf203afba09b98ccbaf76
treefd7dddec731fd05fdf0045cc6dab08f18ccd96ba
parent04f6152d9fbad5bb78bccd05e798fa2d66c571e9
video: fbdev: cobalt_lcdfb: Handle return NULL error from devm_ioremap

Here, If devm_ioremap will fail. It will return NULL.
Kernel can run into a NULL-pointer dereference.
This error check will avoid NULL pointer dereference.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Acked-by: Yoichi Yuasa <yuasa@linux-mips.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
drivers/video/fbdev/cobalt_lcdfb.c