]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
net: mvneta: zero Tx descriptors on init
authorRabeeh Khoury <rabeeh@solid-run.com>
Tue, 19 Jun 2018 18:36:51 +0000 (21:36 +0300)
committerJoe Hershberger <joe.hershberger@ni.com>
Mon, 2 Jul 2018 19:14:20 +0000 (14:14 -0500)
Make the initialization sequence consistent with the Linux kernel
driver.

Reviewed-by: Stefan Roese <sr@denx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Signed-off-by: Rabeeh Khoury <rabeeh@solid-run.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
drivers/net/mvneta.c

index 254dd04697dbc8668e1dc031c1957f061c92dd75..ab697b9bc76ef5876dfa56da534aa92729f952a7 100644 (file)
@@ -1708,6 +1708,7 @@ static int mvneta_probe(struct udevice *dev)
                buffer_loc.tx_descs = (struct mvneta_tx_desc *)bd_space;
                size = roundup(MVNETA_MAX_TXD * sizeof(struct mvneta_tx_desc),
                                ARCH_DMA_MINALIGN);
+               memset(buffer_loc.tx_descs, 0, size);
                buffer_loc.rx_descs = (struct mvneta_rx_desc *)
                        ((phys_addr_t)bd_space + size);
                size += roundup(MVNETA_MAX_RXD * sizeof(struct mvneta_rx_desc),