diff options
author | Stefan Roese <sr@denx.de> | 2017-02-16 13:29:08 +0100 |
---|---|---|
committer | Stefan Roese <sr@denx.de> | 2017-03-29 07:42:16 +0200 |
commit | 30edc374ea230d73a92d4dc250bfd0cf60ce81c9 (patch) | |
tree | 152a0ddf1b3ac93745dd8f195b4401b75ac611d0 /drivers/net/mvpp2.c | |
parent | 1fabbd074e8fb0315901c2e0ba04ca2519a5bb6f (diff) | |
download | u-boot-30edc374ea230d73a92d4dc250bfd0cf60ce81c9.zip u-boot-30edc374ea230d73a92d4dc250bfd0cf60ce81c9.tar.gz u-boot-30edc374ea230d73a92d4dc250bfd0cf60ce81c9.tar.bz2 |
net: mvpp2.c: Clear all buffer / descriptor areas before usage
This fixes problems noticed with the PPv2.2 A7k/8k port, when not all
elements of the descriptors had been cleared before use.
Signed-off-by: Stefan Roese <sr@denx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Diffstat (limited to 'drivers/net/mvpp2.c')
-rw-r--r-- | drivers/net/mvpp2.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/mvpp2.c b/drivers/net/mvpp2.c index 06909e6..b9e0fdc 100644 --- a/drivers/net/mvpp2.c +++ b/drivers/net/mvpp2.c @@ -4429,6 +4429,9 @@ static int mvpp2_base_probe(struct udevice *dev) size += RX_BUFFER_SIZE; } + /* Clear the complete area so that all descriptors are cleared */ + memset(bd_space, 0, size); + /* Save base addresses for later use */ priv->base = (void *)dev_get_addr_index(dev, 0); if (IS_ERR(priv->base)) |