aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata
diff options
context:
space:
mode:
authorSergei Shtylyov <sshtylyov@ru.mvista.com>2011-10-10 11:09:17 -0400
committerJeff Garzik <jgarzik@redhat.com>2011-10-14 13:01:39 -0400
commit8e3bfdb95ad7440fa2c7eca5551b9169a5cdcf58 (patch)
treefe8db4d9d2479564c341c3d564b634aa3485d097 /drivers/ata
parentc2036033604060adc85098bd0e7179a6b2a7b48c (diff)
pata_at91: call clk_put() on ata_host_activate() failure
pata_at91_probe() forgets to call clk_put() iff ata_host_activate() fails... Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/ata')
-rw-r--r--drivers/ata/pata_at91.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/ata/pata_at91.c b/drivers/ata/pata_at91.c
index 960c7257139..c6d14090a42 100644
--- a/drivers/ata/pata_at91.c
+++ b/drivers/ata/pata_at91.c
@@ -414,10 +414,13 @@ static int __devinit pata_at91_probe(struct platform_device *pdev)
414 414
415 host->private_data = info; 415 host->private_data = info;
416 416
417 return ata_host_activate(host, irq ? gpio_to_irq(irq) : 0, 417 ret = ata_host_activate(host, irq ? gpio_to_irq(irq) : 0,
418 irq ? ata_sff_interrupt : NULL, 418 irq ? ata_sff_interrupt : NULL,
419 irq_flags, &pata_at91_sht); 419 irq_flags, &pata_at91_sht);
420 420
421 if (!ret)
422 return 0;
423
421err_put: 424err_put:
422 clk_put(info->mck); 425 clk_put(info->mck);
423 return ret; 426 return ret;