mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-29 16:10:58 +00:00
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>
This commit is contained in:
parent
72c4c33e98
commit
de0b95762a
1 changed files with 1 additions and 0 deletions
|
@ -710,6 +710,7 @@ static int fec_probe(bd_t *bd)
|
||||||
puts("fec_mxc: not enough malloc memory\n");
|
puts("fec_mxc: not enough malloc memory\n");
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
}
|
}
|
||||||
|
memset(edev, 0, sizeof(*edev));
|
||||||
edev->priv = fec;
|
edev->priv = fec;
|
||||||
edev->init = fec_init;
|
edev->init = fec_init;
|
||||||
edev->send = fec_send;
|
edev->send = fec_send;
|
||||||
|
|
Loading…
Reference in a new issue