]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net: broadcom: bcm4908_enet: drop unneeded memset()
authorRafał Miłecki <rafal@milecki.pl>
Thu, 11 Feb 2021 12:12:35 +0000 (13:12 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 11 Feb 2021 23:04:17 +0000 (15:04 -0800)
dma_alloc_coherent takes care of zeroing allocated memory

Suggested-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bcm4908_enet.c

index e56348eb188fc37908ea8a1c24131428070338a9..f4e31646d50f150dd6b9b056f3b1ef014cca2876 100644 (file)
@@ -163,8 +163,6 @@ static int bcm4908_dma_alloc_buf_descs(struct bcm4908_enet *enet,
        if (!ring->slots)
                goto err_free_buf_descs;
 
-       memset(ring->cpu_addr, 0, size);
-
        ring->read_idx = 0;
        ring->write_idx = 0;