NIC not properly initialized in uboot code

Bug #507887 reported by Oliver Grawert
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
uboot-imx (Ubuntu)
High
Oliver Grawert
Lucid
High
Oliver Grawert

Bug Description

with the recent uboot 2009.08 with freescale patches applied the FEC NIC doesnt get properly initialized under the running system this results in:

SIOCSIFFLAGS Cannot assign requested address

when running ifconfig eth0 up.

the NIC reportse a hardware address of 00:00:00:00:00:00
trying to initialize the NIC manually at the uboot prompt with setenv ethaddr (using the address printed on the label on the board) does not change the situation.
the file mxc_fec.c in the uboot code also seems to have many inconsistencies and some errors that show up during build.

Oliver Grawert (ogra)
tags: added: armel
Changed in uboot-imx (Ubuntu):
milestone: none → lucid-alpha-3
importance: Undecided → High
Alexander Sack (asac)
Changed in uboot-imx (Ubuntu Lucid):
assignee: nobody → Oliver Grawert (ogra)
Alexander Sack (asac)
Changed in uboot-imx (Ubuntu Lucid):
status: New → Confirmed
Revision history for this message
Oliver Grawert (ogra) wrote :

using:

setenv ethaddr <some random MAC address>
setenv ipaddr <a valid IP of the net the NIC is connected to>

seems to help. but indeed thats not usable in the automated SD card boot we are using since it would enforce to type in the IP each time you boot through serial console ... automated setting of the MAC and initializing of the NIC needs to work as it does under redboot.

Revision history for this message
Terry Lv (r65388) wrote :

Hi All,

  Pls try the patch attached.

  u-boot will not initilized network unless the user has use it to fetch data. If you need to set fec mac addr to fec register, pls apply this patch and set the "fec_addr" environment variable.

  This patch will check if fec_addr exists and set its value to fec register in booting.

  Thanks~~

Yours
Terry

Revision history for this message
Oliver Grawert (ogra) wrote :

hmm, i dont see any code providing the mxc_fec_set_mac_from_env() function in either the 2009.01 nor the 2009.08 trees, but i'm doing a testbuild nontheless now ... will report back soon ...

Revision history for this message
Oliver Grawert (ogra) wrote :

as i expected:

cpu/arm_cortexa8/mx51/libmx51.a(generic.o): In function `cpu_eth_init':
cpu/arm_cortexa8/mx51/generic.c:261: undefined reference to `mxc_fec_set_mac_from_env'

is there another patch i'm missing that is not in the BSP ?

Revision history for this message
Oliver Grawert (ogra) wrote :

note btw that we are currently having to use the latest 2009.01 uboot with the patches from the RC BSP (from dec. 9) due to bug #506761
(the error above shows up in a 2009.08 testbuild from the latest BSP as well though)

Revision history for this message
Alexander Sack (asac) wrote :

terry, the patch seem to be incomplete; please check comments #3, #4 and #5

Revision history for this message
Alexander Sack (asac) wrote :

we are going for redboot for imx lucid ... until all bugs are fixed for uboot.

Changed in uboot-imx (Ubuntu Lucid):
status: Confirmed → Won't Fix
Changed in uboot-imx (Ubuntu):
milestone: lucid-alpha-3 → later
Paul Larson (pwlars)
tags: added: patch-needswork
Revision history for this message
Jamie Bennett (jamiebennett) wrote :

Is this still an issue with using u-boot-linaro?

tags: added: imx51
Revision history for this message
Oliver Grawert (ogra) wrote :

uboot-imx was removed from the archive, invalidating the task.

Changed in uboot-imx (Ubuntu):
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers