]> git.baikalelectronics.ru Git - kernel.git/commit
fec: fix uninitialized rx buffer usage
authorRob Herring <r.herring@freescale.com>
Fri, 5 Feb 2010 08:56:20 +0000 (08:56 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 10 Feb 2010 21:05:42 +0000 (13:05 -0800)
commitd003a61c45c32dae3d945d2a09a9596cd0acbd3c
treece20891b9038d35d21687957491383ed9e167ce8
parentd0639d92a9eceaf29654b4febc98bd7ff002765c
fec: fix uninitialized rx buffer usage

The fec driver was enabling receive buffer descriptor without allocating
the buffers. Make sure the buffer descriptors are initialized to not
start receiving packets.

Open also calls fec_restart after the rx buffers are allocated. With the code
in fec_restart, it zeroes out the buffer descriptors that have just been
setup.

Signed-off-by: Rob Herring <r.herring@freescale.com>
Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/fec.c