[U-Boot-Users] [PATCH V2] Fix Ethernet init() return codes.

Haavard Skinnemoen hskinnemoen at atmel.com
Wed Jan 9 17:26:28 CET 2008


On Tue, 08 Jan 2008 17:23:21 -0500
Ben Warren <biggerbadderben at gmail.com> wrote:

> diff --git a/drivers/net/macb.c b/drivers/net/macb.c
> index 95cdc49..6657d22 100644
> --- a/drivers/net/macb.c
> +++ b/drivers/net/macb.c
> @@ -423,12 +423,12 @@ static int macb_init(struct eth_device *netdev,
> bd_t *bd) #endif
>  
>  	if (!macb_phy_init(macb))
> -		return 0;
> +		return -1;
>  
>  	/* Enable TX and RX */
>  	macb_writel(macb, NCR, MACB_BIT(TE) | MACB_BIT(RE));
>  
> -	return 1;
> +	return 0;
>  }
>  
>  static void macb_halt(struct eth_device *netdev)

Acked-by: Haavard Skinnemoen <hskinnemoen at atmel.com>

Will test at the first opportunity...hopefully tonight.

Haavard




More information about the U-Boot mailing list