diff --git a/[refs] b/[refs] index 6a993f4711dd..10429afcdd78 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ff3c536291ce96ef6f45704cd37eaed71127dd42 +refs/heads/master: a2b89b596c5a0b288adac84b17bdda6bde8d144e diff --git a/trunk/lib/swiotlb.c b/trunk/lib/swiotlb.c index f8eebd489149..78330c37a61b 100644 --- a/trunk/lib/swiotlb.c +++ b/trunk/lib/swiotlb.c @@ -497,8 +497,10 @@ swiotlb_alloc_coherent(struct device *hwdev, size_t size, printk("hwdev DMA mask = 0x%016Lx, dev_addr = 0x%016Lx\n", (unsigned long long)*hwdev->dma_mask, (unsigned long long)dev_addr); - panic("swiotlb_alloc_coherent: allocated memory is out of " - "range for device"); + + /* DMA_TO_DEVICE to avoid memcpy in unmap_single */ + unmap_single(hwdev, ret, size, DMA_TO_DEVICE); + return NULL; } *dma_handle = dev_addr; return ret;