diff options
author | Marek Szyprowski <m.szyprowski@samsung.com> | 2011-08-29 02:20:56 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-09-06 14:05:10 -0400 |
commit | ba7fcb0c954921534707f08ebc4d8beeb2eb17e7 (patch) | |
tree | 0dc9929461e4ac2af79ab5bfffb1bdac181ad6c5 /drivers/media/video/s5p-mfc/s5p_mfc_opr.c | |
parent | 035aa1475d6e4afdf97dccf6c6d6059063398b57 (diff) |
[media] media: vb2: dma contig allocator: use dma_addr instread of paddr
Use the correct 'dma_addr' name for the buffer address. 'paddr' suggested
that this is the physical address in system memory. For most ARM platforms
these two are the same, but this is not a generic rule. 'dma_addr' will
also point better to dma-mapping api.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Pawel Osciak <pawel@osciak.com>
Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/s5p-mfc/s5p_mfc_opr.c')
-rw-r--r-- | drivers/media/video/s5p-mfc/s5p_mfc_opr.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/media/video/s5p-mfc/s5p_mfc_opr.c b/drivers/media/video/s5p-mfc/s5p_mfc_opr.c index 7b239168c199..e08b21c50ebf 100644 --- a/drivers/media/video/s5p-mfc/s5p_mfc_opr.c +++ b/drivers/media/video/s5p-mfc/s5p_mfc_opr.c | |||
@@ -1135,7 +1135,7 @@ static int s5p_mfc_run_dec_frame(struct s5p_mfc_ctx *ctx, int last_frame) | |||
1135 | temp_vb = list_entry(ctx->src_queue.next, struct s5p_mfc_buf, list); | 1135 | temp_vb = list_entry(ctx->src_queue.next, struct s5p_mfc_buf, list); |
1136 | temp_vb->used = 1; | 1136 | temp_vb->used = 1; |
1137 | s5p_mfc_set_dec_stream_buffer(ctx, | 1137 | s5p_mfc_set_dec_stream_buffer(ctx, |
1138 | vb2_dma_contig_plane_paddr(temp_vb->b, 0), ctx->consumed_stream, | 1138 | vb2_dma_contig_plane_dma_addr(temp_vb->b, 0), ctx->consumed_stream, |
1139 | temp_vb->b->v4l2_planes[0].bytesused); | 1139 | temp_vb->b->v4l2_planes[0].bytesused); |
1140 | spin_unlock_irqrestore(&dev->irqlock, flags); | 1140 | spin_unlock_irqrestore(&dev->irqlock, flags); |
1141 | index = temp_vb->b->v4l2_buf.index; | 1141 | index = temp_vb->b->v4l2_buf.index; |
@@ -1172,12 +1172,12 @@ static int s5p_mfc_run_enc_frame(struct s5p_mfc_ctx *ctx) | |||
1172 | } | 1172 | } |
1173 | src_mb = list_entry(ctx->src_queue.next, struct s5p_mfc_buf, list); | 1173 | src_mb = list_entry(ctx->src_queue.next, struct s5p_mfc_buf, list); |
1174 | src_mb->used = 1; | 1174 | src_mb->used = 1; |
1175 | src_y_addr = vb2_dma_contig_plane_paddr(src_mb->b, 0); | 1175 | src_y_addr = vb2_dma_contig_plane_dma_addr(src_mb->b, 0); |
1176 | src_c_addr = vb2_dma_contig_plane_paddr(src_mb->b, 1); | 1176 | src_c_addr = vb2_dma_contig_plane_dma_addr(src_mb->b, 1); |
1177 | s5p_mfc_set_enc_frame_buffer(ctx, src_y_addr, src_c_addr); | 1177 | s5p_mfc_set_enc_frame_buffer(ctx, src_y_addr, src_c_addr); |
1178 | dst_mb = list_entry(ctx->dst_queue.next, struct s5p_mfc_buf, list); | 1178 | dst_mb = list_entry(ctx->dst_queue.next, struct s5p_mfc_buf, list); |
1179 | dst_mb->used = 1; | 1179 | dst_mb->used = 1; |
1180 | dst_addr = vb2_dma_contig_plane_paddr(dst_mb->b, 0); | 1180 | dst_addr = vb2_dma_contig_plane_dma_addr(dst_mb->b, 0); |
1181 | dst_size = vb2_plane_size(dst_mb->b, 0); | 1181 | dst_size = vb2_plane_size(dst_mb->b, 0); |
1182 | s5p_mfc_set_enc_stream_buffer(ctx, dst_addr, dst_size); | 1182 | s5p_mfc_set_enc_stream_buffer(ctx, dst_addr, dst_size); |
1183 | spin_unlock_irqrestore(&dev->irqlock, flags); | 1183 | spin_unlock_irqrestore(&dev->irqlock, flags); |
@@ -1200,7 +1200,7 @@ static void s5p_mfc_run_init_dec(struct s5p_mfc_ctx *ctx) | |||
1200 | s5p_mfc_set_dec_desc_buffer(ctx); | 1200 | s5p_mfc_set_dec_desc_buffer(ctx); |
1201 | mfc_debug(2, "Header size: %d\n", temp_vb->b->v4l2_planes[0].bytesused); | 1201 | mfc_debug(2, "Header size: %d\n", temp_vb->b->v4l2_planes[0].bytesused); |
1202 | s5p_mfc_set_dec_stream_buffer(ctx, | 1202 | s5p_mfc_set_dec_stream_buffer(ctx, |
1203 | vb2_dma_contig_plane_paddr(temp_vb->b, 0), | 1203 | vb2_dma_contig_plane_dma_addr(temp_vb->b, 0), |
1204 | 0, temp_vb->b->v4l2_planes[0].bytesused); | 1204 | 0, temp_vb->b->v4l2_planes[0].bytesused); |
1205 | spin_unlock_irqrestore(&dev->irqlock, flags); | 1205 | spin_unlock_irqrestore(&dev->irqlock, flags); |
1206 | dev->curr_ctx = ctx->num; | 1206 | dev->curr_ctx = ctx->num; |
@@ -1219,7 +1219,7 @@ static void s5p_mfc_run_init_enc(struct s5p_mfc_ctx *ctx) | |||
1219 | s5p_mfc_set_enc_ref_buffer(ctx); | 1219 | s5p_mfc_set_enc_ref_buffer(ctx); |
1220 | spin_lock_irqsave(&dev->irqlock, flags); | 1220 | spin_lock_irqsave(&dev->irqlock, flags); |
1221 | dst_mb = list_entry(ctx->dst_queue.next, struct s5p_mfc_buf, list); | 1221 | dst_mb = list_entry(ctx->dst_queue.next, struct s5p_mfc_buf, list); |
1222 | dst_addr = vb2_dma_contig_plane_paddr(dst_mb->b, 0); | 1222 | dst_addr = vb2_dma_contig_plane_dma_addr(dst_mb->b, 0); |
1223 | dst_size = vb2_plane_size(dst_mb->b, 0); | 1223 | dst_size = vb2_plane_size(dst_mb->b, 0); |
1224 | s5p_mfc_set_enc_stream_buffer(ctx, dst_addr, dst_size); | 1224 | s5p_mfc_set_enc_stream_buffer(ctx, dst_addr, dst_size); |
1225 | spin_unlock_irqrestore(&dev->irqlock, flags); | 1225 | spin_unlock_irqrestore(&dev->irqlock, flags); |
@@ -1255,7 +1255,7 @@ static int s5p_mfc_run_init_dec_buffers(struct s5p_mfc_ctx *ctx) | |||
1255 | temp_vb = list_entry(ctx->src_queue.next, struct s5p_mfc_buf, list); | 1255 | temp_vb = list_entry(ctx->src_queue.next, struct s5p_mfc_buf, list); |
1256 | mfc_debug(2, "Header size: %d\n", temp_vb->b->v4l2_planes[0].bytesused); | 1256 | mfc_debug(2, "Header size: %d\n", temp_vb->b->v4l2_planes[0].bytesused); |
1257 | s5p_mfc_set_dec_stream_buffer(ctx, | 1257 | s5p_mfc_set_dec_stream_buffer(ctx, |
1258 | vb2_dma_contig_plane_paddr(temp_vb->b, 0), | 1258 | vb2_dma_contig_plane_dma_addr(temp_vb->b, 0), |
1259 | 0, temp_vb->b->v4l2_planes[0].bytesused); | 1259 | 0, temp_vb->b->v4l2_planes[0].bytesused); |
1260 | spin_unlock_irqrestore(&dev->irqlock, flags); | 1260 | spin_unlock_irqrestore(&dev->irqlock, flags); |
1261 | dev->curr_ctx = ctx->num; | 1261 | dev->curr_ctx = ctx->num; |