summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/ti/tlan.c
diff options
context:
space:
mode:
authorFuqian Huang <huangfq.daxian@gmail.com>2019-07-15 06:19:11 +0300
committerDavid S. Miller <davem@davemloft.net>2019-07-15 21:06:27 +0300
commit3a5ee3b30126bd7dc5d6299f3a985d4fefcf42c9 (patch)
treebc48ce9996493d2db1151e6d200037db8076a69f /drivers/net/ethernet/ti/tlan.c
parentcef86f1536b02e61e699f53b5f8782067481580d (diff)
downloadlinux-3a5ee3b30126bd7dc5d6299f3a985d4fefcf42c9.tar.xz
ethernet: remove redundant memset
kvzalloc already zeroes the memory during the allocation. pci_alloc_consistent calls dma_alloc_coherent directly. In commit 518a2f1925c3 ("dma-mapping: zero memory returned from dma_alloc_*"), dma_alloc_coherent has already zeroed the memory. So the memset after these function is not needed. Signed-off-by: Fuqian Huang <huangfq.daxian@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/ti/tlan.c')
-rw-r--r--drivers/net/ethernet/ti/tlan.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/net/ethernet/ti/tlan.c b/drivers/net/ethernet/ti/tlan.c
index b4ab1a5f6cd0..78f0f2d59e22 100644
--- a/drivers/net/ethernet/ti/tlan.c
+++ b/drivers/net/ethernet/ti/tlan.c
@@ -855,7 +855,6 @@ static int tlan_init(struct net_device *dev)
dev->name);
return -ENOMEM;
}
- memset(priv->dma_storage, 0, dma_size);
priv->rx_list = (struct tlan_list *)
ALIGN((unsigned long)priv->dma_storage, 8);
priv->rx_list_dma = ALIGN(priv->dma_storage_dma, 8);