summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuhiro Iwamatsu <iwamatsu@nigauri.org>2010-10-19 14:03:42 +0900
committerWolfgang Denk <wd@denx.de>2010-11-14 23:17:42 +0100
commitde0b95762a048a6815cd019b3a0e1acf0dbd70f4 (patch)
tree333a30d4717608c155c07a52f394794cdca42724
parent72c4c33e9835f370ec5509c3c18c9d4741de025f (diff)
downloadu-boot-imx-de0b95762a048a6815cd019b3a0e1acf0dbd70f4.zip
u-boot-imx-de0b95762a048a6815cd019b3a0e1acf0dbd70f4.tar.gz
u-boot-imx-de0b95762a048a6815cd019b3a0e1acf0dbd70f4.tar.bz2
net: fec_mxc: Add initialized eth_device structure
This prevents access to the member of eth_device which is not initialized. Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org> CC: Ben Warren <biggerbadderben@gmail.com>
-rw-r--r--drivers/net/fec_mxc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/fec_mxc.c b/drivers/net/fec_mxc.c
index 3f09c2b..c17f937 100644
--- a/drivers/net/fec_mxc.c
+++ b/drivers/net/fec_mxc.c
@@ -710,6 +710,7 @@ static int fec_probe(bd_t *bd)
puts("fec_mxc: not enough malloc memory\n");
return -ENOMEM;
}
+ memset(edev, 0, sizeof(*edev));
edev->priv = fec;
edev->init = fec_init;
edev->send = fec_send;