Skip to contentSkip to conversation

crypto: cavium remove casting dma_alloc

PATCH In review Vasyl Gomonovych 2 participants 2 messages Jun 23, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 crypto: cavium remove casting dma_alloc

From: Vasyl <[email protected]>

Generated by: alloc_cast.cocci

---
 drivers/crypto/cavium/cpt/cptvf_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/crypto/cavium/cpt/cptvf_main.c +1 -1
index 0f72e9abdefe..e9b5c4c70317 100644
@@ -233,7 +233,7 @@ static int alloc_command_queues(struct cpt_vf *cptvf,
 
 			c_size = (rem_q_size > qcsize_bytes) ? qcsize_bytes :
 					rem_q_size;
-			curr->head = (u8 *)dma_alloc_coherent(&pdev->dev,
+			curr->head = dma_alloc_coherent(&pdev->dev,
 							      c_size + CPT_NEXT_CHUNK_PTR_SIZE,
 							      &curr->dma_addr,
 							      GFP_KERNEL);
Signature · 1 line
2.17.1
maintainer
#1 lore raw

From: Vasyl Gomonovych <[email protected]>
Date: Sun, 23 Jun 2019 22:48:49 +0200

drivers/crypto/cavium/cpt/cptvf_main.c static int alloc_command_queues(struct cpt_vf *cptvf, · line 239

Quoted 9 lines
drivers/crypto/cavium/cpt/cptvf_main.c +1 -1
@@ -233,7 +233,7 @@ static int alloc_command_queues(struct cpt_vf *cptvf,
 
 			c_size = (rem_q_size > qcsize_bytes) ? qcsize_bytes :
 					rem_q_size;
-			curr->head = (u8 *)dma_alloc_coherent(&pdev->dev,
+			curr->head = dma_alloc_coherent(&pdev->dev,
 							      c_size + CPT_NEXT_CHUNK_PTR_SIZE,
 							      &curr->dma_addr,
 							      GFP_KERNEL);

Please fix up the indentation of the 2nd, 3rd, and 4th line of the call if you do this. Each of those lines should start precisely at the first column after the openning parenthesis of the first line.

Thank you.