summaryrefslogtreecommitdiff
path: root/drivers/usb
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>2013-06-19 15:38:13 (GMT)
committerFelipe Balbi <balbi@ti.com>2013-07-29 10:53:20 (GMT)
commit6904b845e27830ea0dc8d00fada5a3f478924ea3 (patch)
tree390e72521d3528c8fbabaa99239c65810569c7e7 /drivers/usb
parenta6a20885f1e13340e30ec35acfdcf14756ecf03c (diff)
downloadlinux-fsl-qoriq-6904b845e27830ea0dc8d00fada5a3f478924ea3.tar.xz
usb: musb: remove a few is_dma_capable() in init/exit code
This patch removes is_dma_capable() and an ifdef in the init/exit path around init/de-init of the dma_controller. Since we have the empty stubs in the PIO code we can call it without gcc trouble. Earlier we had an ifdef and the is_dma_capable() macro where gcc ignored the if (0) path even that the function was not around :) Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/musb/musb_core.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index a4434d2..b33bed5 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -1764,7 +1764,7 @@ static void musb_free(struct musb *musb)
disable_irq_wake(musb->nIrq);
free_irq(musb->nIrq, musb);
}
- if (is_dma_capable() && musb->dma_controller)
+ if (musb->dma_controller)
dma_controller_destroy(musb->dma_controller);
musb_host_free(musb);
@@ -1840,12 +1840,11 @@ musb_init_controller(struct device *dev, int nIrq, void __iomem *ctrl)
pm_runtime_get_sync(musb->controller);
-#ifndef CONFIG_MUSB_PIO_ONLY
if (use_dma && dev->dma_mask)
musb->dma_controller = dma_controller_create(musb, musb->mregs);
-#endif
+
/* ideally this would be abstracted in platform setup */
- if (!is_dma_capable() || !musb->dma_controller)
+ if (!musb->dma_controller)
dev->dma_mask = NULL;
/* be sure interrupts are disabled before connecting ISR */