aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma/intel_mid_dma.c
diff options
context:
space:
mode:
authorAdrian Hunter <adrian.hunter@intel.com>2011-12-16 04:01:39 -0500
committerVinod Koul <vinod.koul@linux.intel.com>2011-12-23 11:20:57 -0500
commit2a0ff7a602714990b10a8749e908dad48401138e (patch)
treedf445b369f9404496e763fa3507110cfcb47371a /drivers/dma/intel_mid_dma.c
parent1fded07513ea57b5ee128958ff119e05588b7227 (diff)
dmaengine: intel_mid_dma: error path fix
Add missing iounmap in error path. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Diffstat (limited to 'drivers/dma/intel_mid_dma.c')
-rw-r--r--drivers/dma/intel_mid_dma.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/dma/intel_mid_dma.c b/drivers/dma/intel_mid_dma.c
index d4b961677e02..bbcd470c3236 100644
--- a/drivers/dma/intel_mid_dma.c
+++ b/drivers/dma/intel_mid_dma.c
@@ -1104,7 +1104,8 @@ static int mid_setup_dma(struct pci_dev *pdev)
1104 LNW_PERIPHRAL_MASK_SIZE); 1104 LNW_PERIPHRAL_MASK_SIZE);
1105 if (dma->mask_reg == NULL) { 1105 if (dma->mask_reg == NULL) {
1106 pr_err("ERR_MDMA:Can't map periphral intr space !!\n"); 1106 pr_err("ERR_MDMA:Can't map periphral intr space !!\n");
1107 return -ENOMEM; 1107 err = -ENOMEM;
1108 goto err_ioremap;
1108 } 1109 }
1109 } else 1110 } else
1110 dma->mask_reg = NULL; 1111 dma->mask_reg = NULL;
@@ -1201,6 +1202,9 @@ static int mid_setup_dma(struct pci_dev *pdev)
1201err_engine: 1202err_engine:
1202 free_irq(pdev->irq, dma); 1203 free_irq(pdev->irq, dma);
1203err_irq: 1204err_irq:
1205 if (dma->mask_reg)
1206 iounmap(dma->mask_reg);
1207err_ioremap:
1204 pci_pool_destroy(dma->dma_pool); 1208 pci_pool_destroy(dma->dma_pool);
1205err_dma_pool: 1209err_dma_pool:
1206 pr_err("ERR_MDMA:setup_dma failed: %d\n", err); 1210 pr_err("ERR_MDMA:setup_dma failed: %d\n", err);