Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 142310
b: refs/heads/master
c: 82a72d1
h: refs/heads/master
v: v3
  • Loading branch information
Mike Rapoport authored and David Woodhouse committed Mar 20, 2009
1 parent 2fee4ea commit 725a236
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b2ed3680553b451e5c45064de26ea8fa5201c6d4
refs/heads/master: 82a72d108b4fbcc8f651b7c4e34c6f18a605d58d
2 changes: 1 addition & 1 deletion trunk/drivers/mtd/nand/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ config MTD_NAND_ATMEL_ECC_NONE
endchoice

config MTD_NAND_PXA3xx
bool "Support for NAND flash devices on PXA3xx"
tristate "Support for NAND flash devices on PXA3xx"
depends on MTD_NAND && PXA3xx
help
This enables the driver for the NAND flash device found on
Expand Down
10 changes: 10 additions & 0 deletions trunk/drivers/mtd/nand/pxa3xx_nand.c
Original file line number Diff line number Diff line change
Expand Up @@ -1079,6 +1079,7 @@ static int pxa3xx_nand_probe(struct platform_device *pdev)

this = &info->nand_chip;
mtd->priv = info;
mtd->owner = THIS_MODULE;

info->clk = clk_get(&pdev->dev, NULL);
if (IS_ERR(info->clk)) {
Expand Down Expand Up @@ -1187,6 +1188,7 @@ static int pxa3xx_nand_remove(struct platform_device *pdev)
{
struct mtd_info *mtd = platform_get_drvdata(pdev);
struct pxa3xx_nand_info *info = mtd->priv;
struct resource *r;

platform_set_drvdata(pdev, NULL);

Expand All @@ -1199,6 +1201,14 @@ static int pxa3xx_nand_remove(struct platform_device *pdev)
info->data_buff, info->data_buff_phys);
} else
kfree(info->data_buff);

iounmap(info->mmio_base);
r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(r->start, resource_size(r));

clk_disable(info->clk);
clk_put(info->clk);

kfree(mtd);
return 0;
}
Expand Down

0 comments on commit 725a236

Please sign in to comment.