diff options
author | stroese <stroese> | 2004-07-02 14:36:35 +0000 |
---|---|---|
committer | stroese <stroese> | 2004-07-02 14:36:35 +0000 |
commit | 18f71f27aea4b10c7cb53731a5d401c5a78027fc (patch) | |
tree | 9c061cd2ed8a85cf7f56866655d0b3e1296ebdc9 /cpu/ppc4xx/405gp_enet.c | |
parent | 78953f2f93a17fb87aa5c67df385ef1104c1c692 (diff) | |
download | u-boot-imx-18f71f27aea4b10c7cb53731a5d401c5a78027fc.zip u-boot-imx-18f71f27aea4b10c7cb53731a5d401c5a78027fc.tar.gz u-boot-imx-18f71f27aea4b10c7cb53731a5d401c5a78027fc.tar.bz2 |
Fix bug in 405 ethernet driver; allocated data not cleared!
Diffstat (limited to 'cpu/ppc4xx/405gp_enet.c')
-rw-r--r-- | cpu/ppc4xx/405gp_enet.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/cpu/ppc4xx/405gp_enet.c b/cpu/ppc4xx/405gp_enet.c index 572af62..9d8e2b6 100644 --- a/cpu/ppc4xx/405gp_enet.c +++ b/cpu/ppc4xx/405gp_enet.c @@ -944,6 +944,7 @@ int ppc_4xx_eth_initialize (bd_t * bis) "Cannot allocate eth_device %d\n", eth_num); return (-1); } + memset(dev, 0, sizeof(*dev)); /* Allocate our private use data */ hw = (EMAC_405_HW_PST) malloc (sizeof (*hw)); if (hw == NULL) { @@ -953,6 +954,7 @@ int ppc_4xx_eth_initialize (bd_t * bis) free (dev); return (-1); } + memset(hw, 0, sizeof(*hw)); switch (eth_num) { case 0: |