]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
dw_dmac: don't call platform_get_drvdata twice
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Thu, 18 Oct 2012 14:34:10 +0000 (17:34 +0300)
committerVinod Koul <vinod.koul@linux.intel.com>
Mon, 29 Oct 2012 05:14:30 +0000 (10:44 +0530)
There is no need to call platform_get_drvdata twice as we have it already in dw
variable.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
drivers/dma/dw_dmac.c

index ba5e1fac646c73ded075a2ef094d5bad53a2fe74..380e34a59ca4014cc3a43930297043d20bc4bd61 100644 (file)
@@ -1787,7 +1787,7 @@ static void dw_shutdown(struct platform_device *pdev)
 {
        struct dw_dma   *dw = platform_get_drvdata(pdev);
 
-       dw_dma_off(platform_get_drvdata(pdev));
+       dw_dma_off(dw);
        clk_disable_unprepare(dw->clk);
 }
 
@@ -1796,7 +1796,7 @@ static int dw_suspend_noirq(struct device *dev)
        struct platform_device *pdev = to_platform_device(dev);
        struct dw_dma   *dw = platform_get_drvdata(pdev);
 
-       dw_dma_off(platform_get_drvdata(pdev));
+       dw_dma_off(dw);
        clk_disable_unprepare(dw->clk);
 
        return 0;