From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthias Kaehlcke Date: Sun, 24 Jan 2010 11:07:29 +0100 Subject: [U-Boot] [PATCH 04/12] fec_mxc: Fix return values of fec_probe() In-Reply-To: References: Message-ID: <20100124100729.GJ18402@darwin> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de fec_mxc: Return 1 from fec_probe() upon successfully initialization and 0 in case of failure Signed-off-by: Matthias Kaehlcke --- drivers/net/fec_mxc.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/fec_mxc.c b/drivers/net/fec_mxc.c index 19116f2..dc8a020 100644 --- a/drivers/net/fec_mxc.c +++ b/drivers/net/fec_mxc.c @@ -667,7 +667,7 @@ static int fec_probe(bd_t *bd) edev = (struct eth_device *)malloc(sizeof(struct eth_device)); if (!edev) { puts("fec_imx27: not enough malloc memory!\n"); - return -ENOMEM; + return 0; } edev->priv = fec; edev->init = fec_init; @@ -732,7 +732,7 @@ static int fec_probe(bd_t *bd) memcpy(edev->enetaddr, ethaddr, 6); fec_set_hwaddr(edev, ethaddr); - return 0; + return 1; } int fecmxc_initialize(bd_t *bd) -- 1.6.3.1