Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f731fd08 authored by Manu Gautam's avatar Manu Gautam Committed by Stephen Boyd
Browse files

USB: dwc3-msm: Specify DMA masks



DWC3 core now assigns device's dma_mask same as that of its
parent device.

Change-Id: If245b40b37d892877338f628d2580e502026749e
Signed-off-by: default avatarManu Gautam <mgautam@codeaurora.org>
parent 941d1080
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -474,7 +474,6 @@ EXPORT_SYMBOL(dwc3_notify_event);

#define DWC3_ALIGN_MASK		(16 - 1)

static u64 dwc3_dma_mask = DMA_BIT_MASK(64);
static int dwc3_probe(struct platform_device *pdev)
{
	struct device_node	*node = pdev->dev.of_node;
@@ -498,11 +497,6 @@ static int dwc3_probe(struct platform_device *pdev)
	dwc = PTR_ALIGN(mem, DWC3_ALIGN_MASK + 1);
	dwc->mem = mem;

	if (!dev->dma_mask)
		dev->dma_mask = &dwc3_dma_mask;
	if (!dev->coherent_dma_mask)
		dev->coherent_dma_mask = DMA_BIT_MASK(64);

	dwc->notify_event = notify_event;
	res = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
	if (!res) {
+6 −0
Original line number Diff line number Diff line
@@ -2655,6 +2655,7 @@ unreg_chrdev:
static int dwc3_msm_probe(struct platform_device *pdev)
{
	struct device_node *node = pdev->dev.of_node;
	struct device	*dev = &pdev->dev;
	struct dwc3_msm *mdwc;
	struct resource *res;
	void __iomem *tcsr;
@@ -2669,6 +2670,11 @@ static int dwc3_msm_probe(struct platform_device *pdev)
		return -ENOMEM;
	}

	if (!dev->dma_mask)
		dev->dma_mask = &dev->coherent_dma_mask;
	if (!dev->coherent_dma_mask)
		dev->coherent_dma_mask = DMA_BIT_MASK(64);

	platform_set_drvdata(pdev, mdwc);
	mdwc->dev = &pdev->dev;