2008-09-25 05:34:58     U-boot not able to "up" the bfin emac

Document created by Aaronwu Employee on Sep 18, 2013
Version 1Show Document
  • View in full screen mode

2008-09-25 05:34:58     U-boot not able to "up" the bfin emac

Mark Urup (DENMARK)

Message: 62696   

 

My ethernet is working just fine after a cold boot/reset, and also if I just reboot the board with the ethernet still "up".

My problem is mainly that using dhcp, it will sometimes "down" eth0 when the board is rebooting, and thus u-boot hangs.

 

Here is some sample output, where i've manually downed the device, but the problem is the same: u-boot can't "up" the device.

 

Is this a general bug, or just a bug somewhere in my setup (and where might it be)?

 

It's a custom BF537 board, based on the bf537 ezkit.

U-boot version is 1.1.6 (ADI-2008R1)

 

                          _____________________________________

        a8888b.           / Welcome to the uClinux distribution \

       d888888b.         /       _     _                         \

       8P"YP"Y88        /       | |   |_|            __  __ (TM)  |

       8|o||o|88  _____/        | |    _ ____  _   _ \ \/ /       |

       8'    .88       \        | |   | |  _ \| | | | \  /        |

       8`._.' Y8.       \       | |__ | | | | | |_| | /  \        |

      d/      `8b.       \      \____||_|_| |_|\____|/_/\_\       |

     dP   .    Y8b.       \   For embedded processors including   |

    d8:'  "  `::88b        \    the Analog Devices Blackfin      /

   d8"         'Y88b        \___________________________________/

  :8P    '      :888

   8a.   :     _a88P         For further information, check out:

._/"Yaa_:   .| 88P|            - http://blackfin.uclinux.org/

\    YP"    `| 8P  `.          - http://docs.blackfin.uclinux.org/

/     \.___.d|    .'           - http://www.uclinux.org/

`--..__)8888P`._.'  jgs/a:f    - http://www.analog.com/blackfin

                                - http://www.ipthinking.dk

Have fun...

 

 

BusyBox v1.4.1 (2008-09-03 12:31:09 CEST) Built-in shell (msh)

Enter 'help' for a list of built-in commands.

 

root:/> PHY: 0:1f - Link is Up - 100/Full

 

root:/> ping 192.168.102.1

PING 192.168.102.1 (192.168.102.1): 56 data bytes

64 bytes from 192.168.102.1: icmp_seq=0 ttl=64 time=4.2 ms

64 bytes from 192.168.102.1: icmp_seq=1 ttl=64 time=1.1 ms

 

--- 192.168.102.1 ping statistics ---

2 packets transmitted, 2 packets received, 0% packet loss

round-trip min/avg/max = 1.1/2.6/4.2 ms

root:/> ifconfig eth0 down

root:/> PHY: 0:1f - Link is Down

 

root:/> reboot

Restarting system.�

 

U-Boot 1.1.6 (ADI-2008R1) (Aug 28 2008 - 15:57:54)

 

CPU:   ADSP bf537-0.3 (Detected Rev: 0.3)

Board: IP Thinking ipt-shark537

       For support go to: http://ipthinking.dk or

                          http://blackfin.uclinux.org

Clock: VCO: 525 MHz, Core: 525 MHz, System: 131 MHz

RAM:   128 MB

Flash:  0 kB

In:    serial

Out:   serial

Err:   serial

NAND:  128 MiB

Net:   Blackfin EMAC

MAC:   00:50:C2:88:40:06

I2C:   ready

Hit any key to stop autoboot:  0

ipt537_bfin> dhcp

BOOTP broadcast 1

Ethernet: tx error

BOOTP broadcast 2

Ethernet: tx time out

BOOTP broadcast 3

Ethernet: tx time out

BOOTP broadcast 4

Ethernet: tx time out

 

Abort

ipt537_bfin>

QuoteReplyEditDelete

 

 

2008-09-25 05:49:53     Re: U-boot not able to "up" the bfin emac

Mike Frysinger (UNITED STATES)

Message: 62698   

 

you should do a register dump of the EMAC MMRs in the different states before you have u-boot attempt to use the MAC and compare them:

- cold boot

- warm boot w/MAC up

- warm boot w/MAC down

QuoteReplyEditDelete

 

 

2008-09-25 07:34:06     Re: U-boot not able to "up" the bfin emac

Mark Urup (DENMARK)

Message: 62701   

 

There is no change in the EMAC MMC or in the EMAC MAC/SIF register groups if the ethernet is up or down.

 

I just discovered however that the PHY's link and act leds are turned off when it isn't working, and on (ofcourse) when it is.

This makes sense to me, since "ifconfig eth0 down" should turn off the PHY.

 

Unfortunately vdsp does not let me do a copy&paste dump of the registers, but they really are the same (no red digits indicating any changes).

 

How can I make u-boot re-enable the PHY?

QuoteReplyEditDelete

 

 

2008-09-25 07:57:15     Re: U-boot not able to "up" the bfin emac

Mark Urup (DENMARK)

Message: 62703   

 

Just to clarify:

The difference in the registers when the eth is working and not working is only the emac_stat and emac_stky.

 

The other registers stay the same.

Attachments

    Outcomes