From: Amol Lad Date: Fri, 8 Dec 2006 10:40:11 +0000 (-0800) Subject: [PATCH] ioremap balanced with iounmap for drivers/video/fm2fb X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1b3349fa448ce41eda5ae0e6d4dc52837d14ad11;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git [PATCH] ioremap balanced with iounmap for drivers/video/fm2fb ioremap must be balanced by an iounmap and failing to do so can result in a memory leak. Signed-off-by: Amol Lad Cc: "Antonino A. Daplas" Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/video/fm2fb.c b/drivers/video/fm2fb.c index 998374cfae6d..70ff55b14596 100644 --- a/drivers/video/fm2fb.c +++ b/drivers/video/fm2fb.c @@ -283,6 +283,7 @@ static int __devinit fm2fb_probe(struct zorro_dev *z, if (register_framebuffer(info) < 0) { fb_dealloc_cmap(&info->cmap); + iounmap(info->screen_base); framebuffer_release(info); zorro_release_device(z); return -EINVAL;