[lkml]   [2018]   [Nov]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
SubjectRe: [PATCH 06/10] swiotlb: use swiotlb_map_page in swiotlb_map_sg_attrs
Does the patch below make a difference for you?  Assigning an
address to the S/G list is the only functional difference I could
spot. Drivers really should never look at the S/G list on an
error return, but..

diff --git a/kernel/dma/swiotlb.c b/kernel/dma/swiotlb.c
index 75c82f050c9e..a896f46d0c31 100644
--- a/kernel/dma/swiotlb.c
+++ b/kernel/dma/swiotlb.c
@@ -788,7 +788,7 @@ swiotlb_map_sg_attrs(struct device *dev, struct scatterlist *sgl, int nelems,
for_each_sg(sgl, sg, nelems, i) {
dma_addr_t dma_addr;

- dma_add = swiotlb_map_page(dev, sg_page(sg), sg->offset,
+ dma_addr = swiotlb_map_page(dev, sg_page(sg), sg->offset,
sg->length, dir, attrs);
if (dma_addr == DIRECT_MAPPING_ERROR)
goto out_error;
 \ /
  Last update: 2018-11-14 15:14    [W:0.163 / U:8.332 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site