imx51 on board ethernet plug/unplug events not detected

Bug #457878 reported by Paul Larson
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
linux-fsl-imx51 (Ubuntu)
Fix Released
Medium
Bryan Wu
Lucid
Fix Released
Medium
Bryan Wu

Bug Description

The ethernet driver for imx51 does not detect plug/unplug events, so eth0 must be manually activated or deactivated in NM.
Tested last on 2.6.31-105-imx51 #14

Tags: iso-testing
tags: added: iso-testing
Paul Larson (pwlars)
Changed in linux-fsl-imx51 (Ubuntu):
importance: Undecided → Low
Paul Larson (pwlars)
Changed in linux-fsl-imx51 (Ubuntu):
assignee: nobody → Bryan Wu (cooloney)
Revision history for this message
Oliver Grawert (ogra) wrote :

this bug still exists on the new imx51 kernel in lucid

Changed in linux-fsl-imx51 (Ubuntu):
importance: Low → Medium
status: New → Confirmed
milestone: none → lucid-alpha-3
Revision history for this message
Alexander Sack (asac) wrote :

do you have a full dmesg/syslog?

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

are you sure this is the same bug oliver? the bug title sounds like its the LOWER_UP flag that isnt properly working, while what you said in channel feels more like you dont have any driver loaded at all (e.g. no net interface etc.)

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

what i said in the channel referred to the uboot bug #507887, the issue described here is happening under redboot with a working driver, it just doesnt see any plug events.

Revision history for this message
Bryan Wu (cooloney) wrote :

After digging into the fec.c driver and discussing with fsl guys, I found currently the driver does not include link support to imx chips only for Coldfire specific.

There are 2 solutions,
1. change the driver to support imx chips as well as Coldfire.
2. move the whole driver to use generic phylib framework to support almost all the PHY device and link status detection.

Steve Langasek (vorlon)
Changed in linux-fsl-imx51 (Ubuntu Lucid):
milestone: lucid-alpha-3 → ubuntu-10.04-beta-1
Revision history for this message
Dave Martin (dave-martin-arm) wrote :

When an imx51 board is connected to Ethernet via a _hub_ (not a switch), very low throughput is observed between the board and the local network, often 100-200 kB/s.

There might be an autonegotiation problem related to the lack of plug/unplug events (or this might be caused by something completely different).

See https://bugs.launchpad.net/ubuntu/+source/linux-fsl-imx51/+bug/519905

Steve Langasek (vorlon)
Changed in linux-fsl-imx51 (Ubuntu Lucid):
milestone: ubuntu-10.04-beta-1 → ubuntu-10.04-beta-2
Revision history for this message
Alexander Sack (asac) wrote :

dropping from RC bug list. unfortunately, seems more and more unlikely that we will get the complete fix from upstream in time. If we get it soon we might consider this still.

Changed in linux-fsl-imx51 (Ubuntu Lucid):
status: Confirmed → Won't Fix
Changed in linux-fsl-imx51 (Ubuntu):
status: Confirmed → Triaged
Bryan Wu (cooloney)
Changed in linux-fsl-imx51 (Ubuntu Lucid):
status: Won't Fix → In Progress
Revision history for this message
Bryan Wu (cooloney) wrote :
Download full text (5.4 KiB)

I already added the phylib supporting and ethtool carrier detection in fec.c driver. Here is my git tree containing those patches:
http://kernel.ubuntu.com/git?p=roc/ubuntu-lucid.git;a=shortlog;h=refs/heads/fec;pg=0

Please find my kernel package here for testing:
http://people.canonical.com/~roc/kernel/fec/

Booting with networking cable plugged in:
---
roc@babbage:~$ uname -a
Linux babbage 2.6.31-605-imx51 #10~fec+phylib Wed Mar 24 16:19:20 CST 2010 armv7l GNU/Linux
roc@babbage:~$ dmesg | grep eth0
eth0: Freescale FEC PHY driver [SMSC LAN8700] (mii_bus:phy_addr=0:00, irq=-1)
eth0: no IPv6 routers present
roc@babbage:~$ dmesg | tail
type=1505 audit(1269420454.019:10): operation="profile_load" pid=527 name=/usr/bin/evince-thumbnailer
type=1505 audit(1269420454.109:11): operation="profile_load" pid=540 name=/usr/lib/cups/backend/cups-pdf
PHY: 0:00 - Link is Up - 100/Full
lp: driver loaded but no devices found
ppdev: user-space parallel port driver
DMFC high resolution has set, will not change
mxc_ipu mxc_ipu: Channel already disabled 9
mxc_ipu mxc_ipu: Channel already uninitialized 9
DMFC high resolution has set, will not change
eth0: no IPv6 routers present
roc@babbage:~$ ifconfig
eth0 Link encap:Ethernet HWaddr 00:04:9f:00:e8:c8
          inet addr:192.168.0.102 Bcast:192.168.0.255 Mask:255.255.255.0
          inet6 addr: fe80::204:9fff:fe00:e8c8/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:37 errors:0 dropped:0 overruns:0 frame:0
          TX packets:29 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:9868 (9.8 KB) TX bytes:4661 (4.6 KB)
          Base address:0xe000

lo Link encap:Local Loopback
          inet addr:127.0.0.1 Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING MTU:16436 Metric:1
          RX packets:4 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:240 (240.0 B) TX bytes:240 (240.0 B)

roc@babbage:~$ nm-tool

NetworkManager Tool

State: connected

- Device: eth0 [Auto eth0] ----------------------------------------------------
  Type: Wired
  Driver: fec
  State: connected
  Default: yes
  HW Address: 00:04:9F:00:E8:C8

  Capabilities:
    Carrier Detect: yes
    Speed: 100 Mb/s

  Wired Properties
    Carrier: on

  IPv4 Settings:
    Address: 192.168.0.102
    Prefix: 24 (255.255.255.0)
    Gateway: 192.168.0.1

    DNS: 202.109.14.5
    DNS: 124.74.213.68
----

Remove the cable:
---
roc@babbage:~$ dmesg | tail
type=1505 audit(1269420454.109:11): operation="profile_load" pid=540 name=/usr/lib/cups/backend/cups-pdf
PHY: 0:00 - Link is Up - 100/Full
lp: driver loaded but no devices found
ppdev: user-space parallel port driver
DMFC high resolution has set, will not change
mxc_ipu mxc_ipu: Channel already disabled 9
mxc_ipu mxc_ipu: Channel already uninitialized 9
DMFC high resolution has set, will not change
eth0: no IPv6 routers present
PHY...

Read more...

Revision history for this message
Tobin Davis (gruemaster) wrote :

Preliminary testing looks positive. Will do some more extensive testing throughout the day.

Revision history for this message
Dave Martin (dave-martin-arm) wrote :

woohoo

It looks like Bryan's test kernel may fix my ethernet-slowness-with-dumb-hub issue!
(See https://bugs.launchpad.net/ubuntu/+source/linux-fsl-imx51/+bug/519905)

Revision history for this message
Paul Larson (pwlars) wrote :

I am able to successfully get plug/unplug events with the test kernel as well

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux-fsl-imx51 - 2.6.31-606.11

---------------
linux-fsl-imx51 (2.6.31-606.11) lucid; urgency=low

  [ Bryan Wu ]

  * [Config]: turn off CONFIG_FIXED_PHY for fsl-imx51
    - LP: #457878
  * [Config] built in SMSC_PHY driver for fsl-imx51
    - LP: #457878

  [ Upstream Kernel Changes ]

  * netdev/fec.c: add phylib supporting to enable carrier detection
    - LP: #457878
  * netdev/fec: fix compiling warning
    - LP: #457878
 -- Stefan Bader <email address hidden> Fri, 26 Mar 2010 22:00:03 +0100

Changed in linux-fsl-imx51 (Ubuntu Lucid):
status: In Progress → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

The current lucid-proposed kernel changes the fix for this, needs re-testing.

Changed in linux-fsl-imx51 (Ubuntu):
milestone: ubuntu-10.04-beta-2 → none
Changed in linux-fsl-imx51 (Ubuntu Lucid):
status: Fix Released → In Progress
Revision history for this message
Martin Pitt (pitti) wrote :

Sorry, I rejected the lucid-proposed upload because it is older than lucid-security. Closing again for now, then. Please clarify the status of this bug if it should get another SRU.

Changed in linux-fsl-imx51 (Ubuntu Lucid):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.