]> git.baikalelectronics.ru Git - kernel.git/commit
usbnet: mcs7830: rework link state detection
authorOctavian Purdila <octavian.purdila@intel.com>
Mon, 23 Dec 2013 17:06:31 +0000 (19:06 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 31 Dec 2013 21:53:51 +0000 (16:53 -0500)
commit001acfd90601f2703b528c542b188cbec0badc70
tree4c78e69f9027583e2a4e812f18489eb8447761a3
parentf9cad54d8aa70383ee377def7de2a87334be3d86
usbnet: mcs7830: rework link state detection

Even with the quirks in commit 8aa68d34 (mcs7830: Fix link state
detection) there are still spurious link-down events for some chips
where the false link-down events count go over a few hundreds.

This patch takes a more conservative approach and only looks at
link-down events where the link-down state is not combined with other
states (e.g. half/full speed, pending frames in SRAM or TX status
information valid). In all other cases we assume the link is up.

Tested on MCS7830CV-DA (USB ID 9710:7830).

Cc: Ondrej Zary <linux@rainbow-software.org>
Cc: Michael Leun <lkml20120218@newton.leun.net>
Cc: Ming Lei <ming.lei@canonical.com>
Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/mcs7830.c