Loading drivers/staging/android/ion/ion.c +3 −9 Original line number Original line Diff line number Diff line Loading @@ -298,7 +298,7 @@ static struct sg_table *ion_map_dma_buf(struct dma_buf_attachment *attachment, { { struct ion_dma_buf_attachment *a = attachment->priv; struct ion_dma_buf_attachment *a = attachment->priv; struct sg_table *table; struct sg_table *table; int ret, count, map_attrs; int count, map_attrs; struct ion_buffer *buffer = attachment->dmabuf->priv; struct ion_buffer *buffer = attachment->dmabuf->priv; table = a->table; table = a->table; Loading @@ -318,16 +318,10 @@ static struct sg_table *ion_map_dma_buf(struct dma_buf_attachment *attachment, map_attrs); map_attrs); } } if (count <= 0) { if (count <= 0) ret = -ENOMEM; return ERR_PTR(-ENOMEM); goto err; } return table; return table; err: free_duped_table(table); return ERR_PTR(ret); } } static void ion_unmap_dma_buf(struct dma_buf_attachment *attachment, static void ion_unmap_dma_buf(struct dma_buf_attachment *attachment, Loading Loading
drivers/staging/android/ion/ion.c +3 −9 Original line number Original line Diff line number Diff line Loading @@ -298,7 +298,7 @@ static struct sg_table *ion_map_dma_buf(struct dma_buf_attachment *attachment, { { struct ion_dma_buf_attachment *a = attachment->priv; struct ion_dma_buf_attachment *a = attachment->priv; struct sg_table *table; struct sg_table *table; int ret, count, map_attrs; int count, map_attrs; struct ion_buffer *buffer = attachment->dmabuf->priv; struct ion_buffer *buffer = attachment->dmabuf->priv; table = a->table; table = a->table; Loading @@ -318,16 +318,10 @@ static struct sg_table *ion_map_dma_buf(struct dma_buf_attachment *attachment, map_attrs); map_attrs); } } if (count <= 0) { if (count <= 0) ret = -ENOMEM; return ERR_PTR(-ENOMEM); goto err; } return table; return table; err: free_duped_table(table); return ERR_PTR(ret); } } static void ion_unmap_dma_buf(struct dma_buf_attachment *attachment, static void ion_unmap_dma_buf(struct dma_buf_attachment *attachment, Loading