Skip to content

Commit 998bcae

Browse files
Carmichael561Wolfram Sang
authored andcommitted
i2c: cpm: remove casting dma_alloc
Generated by: alloc_cast.cocci Signed-off-by: Vasyl Gomonovych <gomonovych@gmail.com> Acked-by: Jochen Friedrich <jochen@scram.de> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
1 parent 0038617 commit 998bcae

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎drivers/i2c/busses/i2c-cpm.c‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -540,7 +540,9 @@ static int cpm_i2c_setup(struct cpm_i2c *cpm)
540540
}
541541
out_be32(&rbdf[i].cbd_bufaddr, ((cpm->rxdma[i] + 1) & ~1));
542542

543-
cpm->txbuf[i] = (unsigned char *)dma_alloc_coherent(&cpm->ofdev->dev, CPM_MAX_READ + 1, &cpm->txdma[i], GFP_KERNEL);
543+
cpm->txbuf[i] = dma_alloc_coherent(&cpm->ofdev->dev,
544+
CPM_MAX_READ + 1,
545+
&cpm->txdma[i], GFP_KERNEL);
544546
if (!cpm->txbuf[i]) {
545547
ret = -ENOMEM;
546548
goto out_muram;

0 commit comments

Comments
 (0)