[U-Boot] [PATCH 1/2] drivers/net/at91_emac.c: increase timeout for autonegotiation

Ben Warren biggerbadderben at gmail.com
Tue Oct 12 08:33:11 CEST 2010


  Hi Andreas,

On 10/7/2010 12:44 AM, Andreas Bießmann wrote:
> This patch increases timeout for autonegotiation from 1 second to 3 seconds.
> Some boards (e.g. at91rm9200ek) did not negotiate within 1 second.
>
> Signed-off-by: Andreas Bießmann<andreas.devel at googlemail.com>
> ---
>   drivers/net/at91_emac.c |    2 +-
>   1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/at91_emac.c b/drivers/net/at91_emac.c
> index ca2b16b..4626398 100644
> --- a/drivers/net/at91_emac.c
> +++ b/drivers/net/at91_emac.c
> @@ -220,7 +220,7 @@ static int at91emac_phy_reset(struct eth_device *netdev)
>   	at91emac_write(emac, CONFIG_DRIVER_AT91EMAC_PHYADDR, MII_BMCR,
>   		(BMCR_ANENABLE | BMCR_ANRESTART));
>
> -	for (i = 0; i<  100000 / 100; i++) {
> +	for (i = 0; i<  30000; i++) {
>   		at91emac_read(emac, CONFIG_DRIVER_AT91EMAC_PHYADDR,
>   			MII_BMSR,&status);
>   		if (status&  BMSR_ANEGCOMPLETE)
Applied to net repo.

thanks,
Ben


More information about the U-Boot mailing list