mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-22 12:54:37 +00:00
net: mvneta: zero Tx descriptors on init
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>
This commit is contained in:
parent
0f8888b763
commit
318b5d76b6
1 changed files with 1 additions and 0 deletions
|
@ -1708,6 +1708,7 @@ static int mvneta_probe(struct udevice *dev)
|
||||||
buffer_loc.tx_descs = (struct mvneta_tx_desc *)bd_space;
|
buffer_loc.tx_descs = (struct mvneta_tx_desc *)bd_space;
|
||||||
size = roundup(MVNETA_MAX_TXD * sizeof(struct mvneta_tx_desc),
|
size = roundup(MVNETA_MAX_TXD * sizeof(struct mvneta_tx_desc),
|
||||||
ARCH_DMA_MINALIGN);
|
ARCH_DMA_MINALIGN);
|
||||||
|
memset(buffer_loc.tx_descs, 0, size);
|
||||||
buffer_loc.rx_descs = (struct mvneta_rx_desc *)
|
buffer_loc.rx_descs = (struct mvneta_rx_desc *)
|
||||||
((phys_addr_t)bd_space + size);
|
((phys_addr_t)bd_space + size);
|
||||||
size += roundup(MVNETA_MAX_RXD * sizeof(struct mvneta_rx_desc),
|
size += roundup(MVNETA_MAX_RXD * sizeof(struct mvneta_rx_desc),
|
||||||
|
|
Loading…
Add table
Reference in a new issue