[U-Boot] [PATCH 2/2] net: mvneta: zero Tx descriptors on init

Stefan Roese sr at denx.de
Mon Jun 18 06:52:29 UTC 2018


On 17.06.2018 13:55, Baruch Siach wrote:
> From: Rabeeh Khoury <rabeeh at solid-run.com>
> 
> Make the initialization sequence consistent with the Linux kernel
> driver.
> 
> Signed-off-by: Rabeeh Khoury <rabeeh at solid-run.com>
> Signed-off-by: Baruch Siach <baruch at tkos.co.il>
> ---
>   drivers/net/mvneta.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/net/mvneta.c b/drivers/net/mvneta.c
> index 316a72b16517..32d02212b66c 100644
> --- a/drivers/net/mvneta.c
> +++ b/drivers/net/mvneta.c
> @@ -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),
> 

Reviewed-by: Stefan Roese <sr at denx.de>

Thanks,
Stefan


More information about the U-Boot mailing list