|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [PVOPS][PATCH] xen-swiotlb: don't allocate DMA-memory beyond
When running 32-bit pvops-dom0 and a driver tries to allocate a coherent
DMA-memory the xen swiotlb-implementation returned memory beyond 4GB.
This caused for example not working sound on a system with 4 GB and a 64-bit
compatible sound-card with sets the DMA-mask to 64bit.
On bare-metal and the forward-ported xen-dom0 patches from OpenSuse a coherent
DMA-memory is always allocated inside the 32-bit address-range by calling
dma_alloc_coherent_mask.
The attached patch adds the same functionality to xen swiotlb.
Signed-off-by: Ronny Hegewald <Ronny.Hegewald@xxxxxxxxx>
--- arch/x86/xen/pci-swiotlb.c-org 2010-02-01 23:04:42.000000000 +0100
+++ arch/x86/xen/pci-swiotlb.c 2010-02-01 23:20:42.000000000 +0100
@@ -602,7 +602,7 @@ xen_swiotlb_alloc_coherent(struct device
ret = (void *)vstart;
if (hwdev != NULL && hwdev->coherent_dma_mask)
- mask = hwdev->coherent_dma_mask;
+ mask = dma_alloc_coherent_mask(hwdev, flags);
else
mask = DMA_BIT_MASK(32);
swiotlb-32bit-range.patch
Description: Binary data
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-devel] [PVOPS][PATCH] xen-swiotlb: don't allocate DMA-memory beyond 32-bit,
Ronny . Hegewald <=
|
|
|
|
|