lkml.org 
[lkml]   [2015]   [Feb]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 3/3] media/videobuf2-dma-vmalloc: Save output from dma_map_sg
Date
dma_map_sg returns the actual number of areas mapped. Save it on nents.

Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/media/v4l2-core/videobuf2-vmalloc.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/media/v4l2-core/videobuf2-vmalloc.c b/drivers/media/v4l2-core/videobuf2-vmalloc.c
index bcde885..fe18e79 100644
--- a/drivers/media/v4l2-core/videobuf2-vmalloc.c
+++ b/drivers/media/v4l2-core/videobuf2-vmalloc.c
@@ -312,6 +312,7 @@ static struct sg_table *vb2_vmalloc_dmabuf_ops_map(
mutex_unlock(lock);
return ERR_PTR(-EIO);
}
+ sgt->nents = ret;

attach->dma_dir = dma_dir;

--
2.1.4


\
 
 \ /
  Last update: 2015-02-09 17:21    [W:0.886 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site