Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1740565
| Path | csiph.com!goblin2!goblin.stu.neva.ru!news.unit0.net!news.panservice.it!bofh.it!news.nic.it!robomod |
|---|---|
| From | Chunfeng Yun <chunfeng.yun@mediatek.com> |
| Newsgroups | linux.kernel |
| Subject | [PATCH 1/9] usb: xhci-mtk: use dma_set_mask_and_coherent() in probe function |
| Date | Wed, 27 Sep 2017 11:30:02 +0200 |
| Message-ID | <uugPg-t2-19@gated-at.bofh.it> (permalink) |
| X-Original-To | Mathias Nyman <mathias.nyman@intel.com>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Felipe Balbi <felipe.balbi@linux.intel.com>, Rob Herring <robh+dt@kernel.org> |
| X-Uuid | 28a581efcc8747a3b72732fb530e063a-20170927 |
| X-Mailer | git-send-email 1.7.9.5 |
| MIME-Version | 1.0 |
| Content-Type | text/plain |
| X-Mtk | N |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 31 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | Matthias Brugger <matthias.bgg@gmail.com>, Mark Rutland <mark.rutland@arm.com>, Ian Campbell <ijc+devicetree@hellion.org.uk>, Chunfeng Yun <chunfeng.yun@mediatek.com>, <linux-kernel@vger.kernel.org>, <linux-arm-kernel@lists.infradead.org>, <linux-usb@vger.kernel.org>, <linux-mediatek@lists.infradead.org>, <devicetree@vger.kernel.org> |
| X-Original-Date | Wed, 27 Sep 2017 17:22:57 +0800 |
| X-Original-Message-ID | <994382d16d6bdc0f3d7c11b22f1710252e056e34.1506503879.git.chunfeng.yun@mediatek.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1740565 |
Show key headers only | View raw
This patch uses the simpler dma_set_mask_and_coherent() instead of
doing these as separate steps
Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
---
drivers/usb/host/xhci-mtk.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/drivers/usb/host/xhci-mtk.c b/drivers/usb/host/xhci-mtk.c
index 8fb6065..c197a6d 100644
--- a/drivers/usb/host/xhci-mtk.c
+++ b/drivers/usb/host/xhci-mtk.c
@@ -606,15 +606,10 @@ static int xhci_mtk_probe(struct platform_device *pdev)
}
/* Initialize dma_mask and coherent_dma_mask to 32-bits */
- ret = dma_set_coherent_mask(dev, DMA_BIT_MASK(32));
+ ret = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(32));
if (ret)
goto disable_clk;
- if (!dev->dma_mask)
- dev->dma_mask = &dev->coherent_dma_mask;
- else
- dma_set_mask(dev, DMA_BIT_MASK(32));
-
hcd = usb_create_hcd(driver, dev, dev_name(dev));
if (!hcd) {
ret = -ENOMEM;
--
1.7.9.5
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH 1/9] usb: xhci-mtk: use dma_set_mask_and_coherent() in probe function Chunfeng Yun <chunfeng.yun@mediatek.com> - 2017-09-27 11:30 +0200 [PATCH 6/9] usb: xhci-mtk: add optional mcu and dma bus clocks Chunfeng Yun <chunfeng.yun@mediatek.com> - 2017-09-27 11:30 +0200
csiph-web