[PATCH] staging: android: ion: Fix compilation warning

Alexey Skidanov alexey.skidanov at intel.com
Sat Sep 8 16:33:40 UTC 2018


Label unlock is defined but not used

Signed-off-by: Alexey Skidanov <alexey.skidanov at intel.com>
---
 drivers/staging/android/ion/ion.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c
index 5fa5363..080ff1c 100644
--- a/drivers/staging/android/ion/ion.c
+++ b/drivers/staging/android/ion/ion.c
@@ -341,17 +341,14 @@ static int ion_dma_buf_begin_cpu_access(struct dma_buf *dmabuf,
 {
 	struct ion_buffer *buffer = dmabuf->priv;
 	struct ion_dma_buf_attachment *a;
-	int ret = 0;
 
 	mutex_lock(&buffer->lock);
 	list_for_each_entry(a, &buffer->attachments, list) {
 		dma_sync_sg_for_cpu(a->dev, a->table->sgl, a->table->nents,
 				    direction);
 	}
-
-unlock:
 	mutex_unlock(&buffer->lock);
-	return ret;
+	return 0;
 }
 
 static int ion_dma_buf_end_cpu_access(struct dma_buf *dmabuf,
-- 
2.7.4



More information about the devel mailing list