diff options
author | Huang Shijie <b32955@freescale.com> | 2013-01-23 03:20:53 -0500 |
---|---|---|
committer | Artem Bityutskiy <artem.bityutskiy@linux.intel.com> | 2013-02-04 03:06:31 -0500 |
commit | 26738ddb8553f0883c949310337abcf5b353f63d (patch) | |
tree | 583cf6b5e18094e15f8cc4d1345501d707735f85 /drivers/mtd | |
parent | 6d2559f8bc297597f8058ee75bdb8060edd5214d (diff) |
mtd: gpmi: fix a dereferencing freed memory error
The patch "490e280 mtd: gpmi-nand: Convert to module_platform_driver()"
introduced a "dereferencing freed memory" error.
This patch fixes it.
Signed-off-by: Huang Shijie <b32955@freescale.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/nand/gpmi-nand/gpmi-nand.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/nand/gpmi-nand/gpmi-nand.c b/drivers/mtd/nand/gpmi-nand/gpmi-nand.c index 631564d0bd46..38c8b8bfc428 100644 --- a/drivers/mtd/nand/gpmi-nand/gpmi-nand.c +++ b/drivers/mtd/nand/gpmi-nand/gpmi-nand.c | |||
@@ -1657,8 +1657,8 @@ exit_nfc_init: | |||
1657 | release_resources(this); | 1657 | release_resources(this); |
1658 | exit_acquire_resources: | 1658 | exit_acquire_resources: |
1659 | platform_set_drvdata(pdev, NULL); | 1659 | platform_set_drvdata(pdev, NULL); |
1660 | kfree(this); | ||
1661 | dev_err(this->dev, "driver registration failed: %d\n", ret); | 1660 | dev_err(this->dev, "driver registration failed: %d\n", ret); |
1661 | kfree(this); | ||
1662 | 1662 | ||
1663 | return ret; | 1663 | return ret; |
1664 | } | 1664 | } |