summaryrefslogtreecommitdiff
path: root/drivers/usb/host/ohci-sm501.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2017-08-25 18:13:09 +0300
committerChristoph Hellwig <hch@lst.de>2017-09-01 12:59:17 +0300
commit2436bdcda53ff4abb7897c87fa29ef3de8055344 (patch)
treeaa9204da61d1e888fea12ac09c948f5d77e793c5 /drivers/usb/host/ohci-sm501.c
parentb32dbc1e0bf0eaa8bdd725491b361d5fc2f57a85 (diff)
downloadlinux-2436bdcda53ff4abb7897c87fa29ef3de8055344.tar.xz
dma-coherent: remove the DMA_MEMORY_MAP and DMA_MEMORY_IO flags
DMA_MEMORY_IO was never used in the tree, so remove it. That means there is no need for the DMA_MEMORY_MAP flag either now, so remove it as well and change dma_declare_coherent_memory to return a normal errno value. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'drivers/usb/host/ohci-sm501.c')
-rw-r--r--drivers/usb/host/ohci-sm501.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/usb/host/ohci-sm501.c b/drivers/usb/host/ohci-sm501.c
index a8b8d8b8d9f3..d4e0f7cd96fa 100644
--- a/drivers/usb/host/ohci-sm501.c
+++ b/drivers/usb/host/ohci-sm501.c
@@ -123,13 +123,12 @@ static int ohci_hcd_sm501_drv_probe(struct platform_device *pdev)
* regular memory. The HCD_LOCAL_MEM flag does just that.
*/
- if (!dma_declare_coherent_memory(dev, mem->start,
+ retval = dma_declare_coherent_memory(dev, mem->start,
mem->start - mem->parent->start,
resource_size(mem),
- DMA_MEMORY_MAP |
- DMA_MEMORY_EXCLUSIVE)) {
+ DMA_MEMORY_EXCLUSIVE);
+ if (retval) {
dev_err(dev, "cannot declare coherent memory\n");
- retval = -ENXIO;
goto err1;
}