[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAJd=RBBhEtRW4gxqzyN6PerCFen9mujH5KUb0kx3wMBUYpC0qg@mail.gmail.com>
Date: Sat, 13 Aug 2011 12:31:26 +0800
From: Hillf Danton <dhillf@...il.com>
To: "Koul, Vinod" <vinod.koul@...el.com>
Cc: LKML <linux-kernel@...r.kernel.org>
Subject: [RFC patch resend] DMAengine/Langwell: put dev object in error path
When allocating resources for DMA channel, if error encountered, the dev object
of the relevant DMA device should be put, corresponding to the get operation.
Signed-off-by: Hillf Danton <dhillf@...il.com>
---
--- a/drivers/dma/intel_mid_dma.c Sat Aug 13 11:44:46 2011
+++ intel_mid_dma.c Sat Aug 13 12:39:53 2011
@@ -871,6 +871,7 @@ static int intel_mid_dma_alloc_chan_reso
if (mid->state == SUSPENDED) {
if (dma_resume(mid->pdev)) {
pr_err("ERR_MDMA: resume failed");
+ pm_runtime_put(&mid->pdev->dev);
return -EFAULT;
}
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists