diff options
author | Bastian Hecht <hechtb@googlemail.com> | 2012-05-14 08:14:40 -0400 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2012-07-06 13:17:03 -0400 |
commit | cb54751d7a706b4a068b798b97e8a815b99fa835 (patch) | |
tree | 20f8979ff9f24b5364ec108cf74bbb26fbd2c699 | |
parent | 271b874ba1512a1b3bd24edbd4e4116c3b5c15ae (diff) |
mtd: sh_flctl: Add missing iounmap()
Add the unmapping for the error case and for the driver removal.
Signed-off-by: Bastian Hecht <hechtb@gmail.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
-rw-r--r-- | drivers/mtd/nand/sh_flctl.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mtd/nand/sh_flctl.c b/drivers/mtd/nand/sh_flctl.c index aa9b8a5e0b8f..a5a60cac7e70 100644 --- a/drivers/mtd/nand/sh_flctl.c +++ b/drivers/mtd/nand/sh_flctl.c | |||
@@ -918,6 +918,7 @@ static int __devinit flctl_probe(struct platform_device *pdev) | |||
918 | 918 | ||
919 | err_chip: | 919 | err_chip: |
920 | pm_runtime_disable(&pdev->dev); | 920 | pm_runtime_disable(&pdev->dev); |
921 | iounmap(flctl->reg); | ||
921 | err_iomap: | 922 | err_iomap: |
922 | kfree(flctl); | 923 | kfree(flctl); |
923 | return ret; | 924 | return ret; |
@@ -929,6 +930,7 @@ static int __devexit flctl_remove(struct platform_device *pdev) | |||
929 | 930 | ||
930 | nand_release(&flctl->mtd); | 931 | nand_release(&flctl->mtd); |
931 | pm_runtime_disable(&pdev->dev); | 932 | pm_runtime_disable(&pdev->dev); |
933 | iounmap(flctl->reg); | ||
932 | kfree(flctl); | 934 | kfree(flctl); |
933 | 935 | ||
934 | return 0; | 936 | return 0; |