]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
smsc95xx: mark link down on startup and let PHY interrupt deal with carrier changes
authorPaolo Pisati <paolo.pisati@canonical.com>
Mon, 23 Apr 2012 04:05:20 +0000 (04:05 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 12 May 2012 16:32:03 +0000 (09:32 -0700)
commit 07d69d4238418746a7b85c5d05ec17c658a2a390 upstream.

Without this patch sysfs reports the cable as present

flag@flag-desktop:~$ cat /sys/class/net/eth0/carrier
1

while it's not:

flag@flag-desktop:~$ sudo mii-tool eth0
eth0: no link

Tested on my Beagle XM.

v2: added mantainer to the list of recipient

Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Acked-by: Steve Glendinning <steve.glendinning@shawell.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/usb/smsc95xx.c

index d45520e6dd48808b36faa0ce4ebc11600f9dd9ad..f1e77b153beb85c7ec4da9fc90a70ff48946ff5f 100644 (file)
@@ -1191,7 +1191,7 @@ static const struct driver_info smsc95xx_info = {
        .rx_fixup       = smsc95xx_rx_fixup,
        .tx_fixup       = smsc95xx_tx_fixup,
        .status         = smsc95xx_status,
-       .flags          = FLAG_ETHER | FLAG_SEND_ZLP,
+       .flags          = FLAG_ETHER | FLAG_SEND_ZLP | FLAG_LINK_INTR,
 };
 
 static const struct usb_device_id products[] = {