usb:host:xhci-plat: 64-bit dma addressing support
Subsystems (2)
PATCH 1/1 usb:host:xhci-plat: 64-bit dma addressing support
Use dma_addr_t to support 64-bit plaforms, which access beyond 32 bit address range.
Signed-off-by Bao Truong <[email protected]>
Signed-off-by Feng Kan <[email protected]>
--- drivers/usb/host/xhci-plat.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/usb/host/xhci-plat.c +3 -2
@@ -97,13 +97,14 @@ static int xhci_plat_probe(struct platform_device *pdev) }/* Initialize dma_mask and coherent_dma_mask to 32-bits */ - ret =dma_set_coherent_mask (&pdev->dev,DMA_BIT_MASK (32 )); + ret =dma_set_coherent_mask (&pdev->dev, +DMA_BIT_MASK (sizeof (dma_addr_t)*8 ));if (ret)return ret;if (!pdev->dev.dma_mask) pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;else -dma_set_mask (&pdev->dev,DMA_BIT_MASK (32 )); +dma_set_mask (&pdev->dev,DMA_BIT_MASK (sizeof (dma_addr_t)*8 )); hcd =usb_create_hcd (driver, &pdev->dev,dev_name (&pdev->dev));if (!hcd)
Signature · 1 line
1.9.1
Greg KH
maintainerQuoted 14 lines · Feng Kan
Use
dma_addr_tto support 64-bit plaforms, which access beyond 32 bit address range.Signed-off-by Bao Truong <[email protected]>Signed-off-by Feng Kan <[email protected]>--- drivers/usb/host/xhci-plat.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)drivers/usb/host/xhci-plat.c +0
-0
drivers/usb/host/xhci-plat.c static int xhci_plat_probe(struct platform_device *pdev) · line 101
Quoted 6 lines
drivers/usb/host/xhci-plat.c +2
-1@@ -97,13 +97,14 @@ static int xhci_plat_probe(struct platform_device *pdev) }/* Initialize dma_mask and coherent_dma_mask to 32-bits */ - ret =dma_set_coherent_mask (&pdev->dev,DMA_BIT_MASK (32 )); + ret =dma_set_coherent_mask (&pdev->dev, +DMA_BIT_MASK (sizeof (dma_addr_t)*8 ));
Is the comment still correct now?