mirror of
https://github.com/torvalds/linux.git
synced 2024-11-30 16:11:38 +00:00
ASoC: sh: rz-ssi: Trivial fixes
Merge series from Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>: This patch series aims to fix trivial issues found in rz-ssi driver.
This commit is contained in:
commit
3838bf828b
@ -59,9 +59,7 @@
|
||||
#define SSIFSR_RDC_MASK 0x3f
|
||||
#define SSIFSR_RDC_SHIFT 8
|
||||
|
||||
#define SSIFSR_TDC(x) (((x) & 0x1f) << 24)
|
||||
#define SSIFSR_TDE BIT(16)
|
||||
#define SSIFSR_RDC(x) (((x) & 0x1f) << 8)
|
||||
#define SSIFSR_RDF BIT(0)
|
||||
|
||||
#define SSIOFR_LRCONT BIT(8)
|
||||
@ -978,22 +976,24 @@ static int rz_ssi_probe(struct platform_device *pdev)
|
||||
|
||||
/* Error Interrupt */
|
||||
ssi->irq_int = platform_get_irq_byname(pdev, "int_req");
|
||||
if (ssi->irq_int < 0)
|
||||
return dev_err_probe(&pdev->dev, -ENODEV,
|
||||
"Unable to get SSI int_req IRQ\n");
|
||||
if (ssi->irq_int < 0) {
|
||||
rz_ssi_release_dma_channels(ssi);
|
||||
return ssi->irq_int;
|
||||
}
|
||||
|
||||
ret = devm_request_irq(&pdev->dev, ssi->irq_int, &rz_ssi_interrupt,
|
||||
0, dev_name(&pdev->dev), ssi);
|
||||
if (ret < 0)
|
||||
if (ret < 0) {
|
||||
rz_ssi_release_dma_channels(ssi);
|
||||
return dev_err_probe(&pdev->dev, ret,
|
||||
"irq request error (int_req)\n");
|
||||
}
|
||||
|
||||
if (!rz_ssi_is_dma_enabled(ssi)) {
|
||||
/* Tx and Rx interrupts (pio only) */
|
||||
ssi->irq_tx = platform_get_irq_byname(pdev, "dma_tx");
|
||||
if (ssi->irq_tx < 0)
|
||||
return dev_err_probe(&pdev->dev, -ENODEV,
|
||||
"Unable to get SSI dma_tx IRQ\n");
|
||||
return ssi->irq_tx;
|
||||
|
||||
ret = devm_request_irq(&pdev->dev, ssi->irq_tx,
|
||||
&rz_ssi_interrupt, 0,
|
||||
@ -1004,8 +1004,7 @@ static int rz_ssi_probe(struct platform_device *pdev)
|
||||
|
||||
ssi->irq_rx = platform_get_irq_byname(pdev, "dma_rx");
|
||||
if (ssi->irq_rx < 0)
|
||||
return dev_err_probe(&pdev->dev, -ENODEV,
|
||||
"Unable to get SSI dma_rx IRQ\n");
|
||||
return ssi->irq_rx;
|
||||
|
||||
ret = devm_request_irq(&pdev->dev, ssi->irq_rx,
|
||||
&rz_ssi_interrupt, 0,
|
||||
@ -1016,13 +1015,16 @@ static int rz_ssi_probe(struct platform_device *pdev)
|
||||
}
|
||||
|
||||
ssi->rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL);
|
||||
if (IS_ERR(ssi->rstc))
|
||||
if (IS_ERR(ssi->rstc)) {
|
||||
rz_ssi_release_dma_channels(ssi);
|
||||
return PTR_ERR(ssi->rstc);
|
||||
}
|
||||
|
||||
reset_control_deassert(ssi->rstc);
|
||||
pm_runtime_enable(&pdev->dev);
|
||||
ret = pm_runtime_resume_and_get(&pdev->dev);
|
||||
if (ret < 0) {
|
||||
rz_ssi_release_dma_channels(ssi);
|
||||
pm_runtime_disable(ssi->dev);
|
||||
reset_control_assert(ssi->rstc);
|
||||
return dev_err_probe(ssi->dev, ret, "pm_runtime_resume_and_get failed\n");
|
||||
|
Loading…
Reference in New Issue
Block a user