diff options
author | Brian Norris <computersforpeace@gmail.com> | 2012-11-02 00:46:21 -0700 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2012-12-03 05:15:22 -0500 |
commit | 37e1b022bf1c54daf6849deffb65322299493702 (patch) | |
tree | 6241a97f52712c39e25f7998192abe6953503763 /drivers/ata/pata_mpc52xx.c | |
parent | 58d0ff2f05d6915c455b5fe7c404e299fe34993b (diff) |
pata_mpc52xx: utilize common ata_platform_remove_one()
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/ata/pata_mpc52xx.c')
-rw-r--r-- | drivers/ata/pata_mpc52xx.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/drivers/ata/pata_mpc52xx.c b/drivers/ata/pata_mpc52xx.c index d2c102fd433..ec67f54dc56 100644 --- a/drivers/ata/pata_mpc52xx.c +++ b/drivers/ata/pata_mpc52xx.c @@ -663,18 +663,6 @@ mpc52xx_ata_init_one(struct device *dev, struct mpc52xx_ata_priv *priv, &mpc52xx_ata_sht); } -static struct mpc52xx_ata_priv * -mpc52xx_ata_remove_one(struct device *dev) -{ - struct ata_host *host = dev_get_drvdata(dev); - struct mpc52xx_ata_priv *priv = host->private_data; - - ata_host_detach(host); - - return priv; -} - - /* ======================================================================== */ /* OF Platform driver */ /* ======================================================================== */ @@ -815,11 +803,12 @@ mpc52xx_ata_probe(struct platform_device *op) static int mpc52xx_ata_remove(struct platform_device *op) { - struct mpc52xx_ata_priv *priv; + struct ata_host *host = platform_get_drvdata(op); + struct mpc52xx_ata_priv *priv = host->private_data; int task_irq; /* Deregister the ATA interface */ - priv = mpc52xx_ata_remove_one(&op->dev); + ata_platform_remove_one(op); /* Clean up DMA */ task_irq = bcom_get_task_irq(priv->dmatsk); |