Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 126781
b: refs/heads/master
c: 7961233
h: refs/heads/master
i:
  126779: 7b85b03
v: v3
  • Loading branch information
Dmitry Baryshkov authored and Mark Brown committed Jan 5, 2009
1 parent 7841a2a commit a882c56
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 10 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: 05d5e991a7290807e7d62a7d272bb4f37c27c6ae
refs/heads/master: 796123368871e4a838dc0dfd5dbc3cd8981ef429
25 changes: 16 additions & 9 deletions trunk/sound/arm/pxa2xx-ac97-lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -321,10 +321,6 @@ int __devinit pxa2xx_ac97_hw_probe(struct platform_device *dev)
{
int ret;

ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, 0, "AC97", NULL);
if (ret < 0)
goto err;

if (cpu_is_pxa25x() || cpu_is_pxa27x()) {
pxa_gpio_mode(GPIO31_SYNC_AC97_MD);
pxa_gpio_mode(GPIO30_SDATA_OUT_AC97_MD);
Expand All @@ -339,27 +335,38 @@ int __devinit pxa2xx_ac97_hw_probe(struct platform_device *dev)
if (IS_ERR(ac97conf_clk)) {
ret = PTR_ERR(ac97conf_clk);
ac97conf_clk = NULL;
goto err_irq;
goto err_conf;
}
}

ac97_clk = clk_get(&dev->dev, "AC97CLK");
if (IS_ERR(ac97_clk)) {
ret = PTR_ERR(ac97_clk);
ac97_clk = NULL;
goto err_irq;
goto err_clk;
}

return clk_enable(ac97_clk);
ret = clk_enable(ac97_clk);
if (ret)
goto err_clk2;

ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, IRQF_DISABLED, "AC97", NULL);
if (ret < 0)
goto err_irq;

return 0;

err_irq:
GCR |= GCR_ACLINK_OFF;
err_clk2:
clk_put(ac97_clk);
ac97_clk = NULL;
err_clk:
if (ac97conf_clk) {
clk_put(ac97conf_clk);
ac97conf_clk = NULL;
}
free_irq(IRQ_AC97, NULL);
err:
err_conf:
return ret;
}
EXPORT_SYMBOL_GPL(pxa2xx_ac97_hw_probe);
Expand Down

0 comments on commit a882c56

Please sign in to comment.