Skip to content

Commit

Permalink
i2c: ismt: Remove call to memset after dmam_alloc_coherent
Browse files Browse the repository at this point in the history
In commit 518a2f1 ("dma-mapping: zero memory returned from
dma_alloc_*"), dma_alloc_coherent has already zeroed the memory. So
memset is not needed.

Acked-by: Neil Horman <[email protected]>
Signed-off-by: Fuqian Huang <[email protected]>
Signed-off-by: Wolfram Sang <[email protected]>
  • Loading branch information
Yellow-Pay authored and Wolfram Sang committed Aug 1, 2019
1 parent e5738bc commit 34de351
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions drivers/i2c/busses/i2c-ismt.c
Original file line number Diff line number Diff line change
Expand Up @@ -781,8 +781,6 @@ static int ismt_dev_init(struct ismt_priv *priv)
if (!priv->hw)
return -ENOMEM;

memset(priv->hw, 0, (ISMT_DESC_ENTRIES * sizeof(struct ismt_desc)));

priv->head = 0;
init_completion(&priv->cmp);

Expand Down

0 comments on commit 34de351

Please sign in to comment.