pata_samsung_cf: fix ata_host_activate() failure handling
Subsystems (2)
PATCH 1/1 pata_samsung_cf: fix ata_host_activate() failure handling
Add missing clk_disable() call to ata_host_activate() failure path.
--- drivers/ata/pata_samsung_cf.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
drivers/ata/pata_samsung_cf.c +7 -3
@@ -594,9 +594,13 @@ static int __init pata_s3c_probe(structplatform_set_drvdata (pdev, host); -return ata_host_activate (host, info->irq, - info->irq ? pata_s3c_irq :NULL , -0 , &pata_s3c_sht); + ret =ata_host_activate (host, info->irq, + info->irq ? pata_s3c_irq :NULL , +0 , &pata_s3c_sht); +if (ret) + goto stop_clk; + +return 0 ; stop_clk:clk_disable (info->clk);
Quoted 6 lines · Tejun Heo
Add missing
clk_disable()call toata_host_activate()failure path.Cc Ben Dooks <[email protected]>Cc Kukjin Kim <[email protected]>Signed-off-by Bartlomiej Zolnierkiewicz <[email protected]>
Best regards,
Jingoo Han
Quoted 27 lines
--- drivers/ata/pata_samsung_cf.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)Index:
b/drivers/ata/pata_samsung_cf.c
===================================================================drivers/ata/pata_samsung_cf.c +7
-4@@ -594,9 +594,13 @@ static int __init pata_s3c_probe(structplatform_set_drvdata (pdev, host); -return ata_host_activate (host, info->irq, - info->irq ? pata_s3c_irq :NULL , -0 , &pata_s3c_sht); + ret =ata_host_activate (host, info->irq, + info->irq ? pata_s3c_irq :NULL , +0 , &pata_s3c_sht); +if (ret) + goto stop_clk; + +return 0 ; stop_clk:clk_disable (info->clk); --
Hi,
Tejun, could you please also pick this one?
Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics
Quoted 40 lines · Jingoo Han
Quoted 6 lines · Tejun Heo
Add missing
clk_disable()call toata_host_activate()failure path.Cc Ben Dooks <[email protected]>Cc Kukjin Kim <[email protected]>Signed-off-by Bartlomiej Zolnierkiewicz <[email protected]>Reviewed-by Jingoo Han <[email protected]>Best regards,
Jingoo HanQuoted 27 lines
--- drivers/ata/pata_samsung_cf.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)Index:
b/drivers/ata/pata_samsung_cf.c
===================================================================drivers/ata/pata_samsung_cf.c +7
-4@@ -594,9 +594,13 @@ static int __init pata_s3c_probe(structplatform_set_drvdata (pdev, host); -return ata_host_activate (host, info->irq, - info->irq ? pata_s3c_irq :NULL , -0 , &pata_s3c_sht); + ret =ata_host_activate (host, info->irq, + info->irq ? pata_s3c_irq :NULL , +0 , &pata_s3c_sht); +if (ret) + goto stop_clk; + +return 0 ; stop_clk:clk_disable (info->clk); --
Tejun Heo
AppliedQuoted 5 lines · Bartlomiej Zolnierkiewicz
Add missing
clk_disable()call toata_host_activate()failure path.Cc Ben Dooks <[email protected]>Cc Kukjin Kim <[email protected]>Signed-off-by Bartlomiej Zolnierkiewicz <[email protected]>
Applied to libata/for-3.15-fixes.
Thanks.
Signature · 1 line
tejun