aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTushar Dave <tushar.n.dave@intel.com>2012-07-12 04:56:56 -0400
committerLuis Henriques <luis.henriques@canonical.com>2012-07-23 05:50:32 -0400
commitb19224751a481e3817443d858e482b63d81de40a (patch)
treeec6c90b8cb4a05580b9ce08bea10c381c5b63556
parentbabf7ddc991e4c7d735be6e8bc607864e1366f89 (diff)
e1000e: Correct link check logic for 82571 serdes
BugLink: http://bugs.launchpad.net/bugs/1026850 commit d0efa8f23a644f7cb7d1f8e78dd9a223efa412a3 upstream. SYNCH bit and IV bit of RXCW register are sticky. Before examining these bits, RXCW should be read twice to filter out one-time false events and have correct values for these bits. Incorrect values of these bits in link check logic can cause weird link stability issues if auto-negotiation fails. Reported-by: Dean Nelson <dnelson@redhat.com> Signed-off-by: Tushar Dave <tushar.n.dave@intel.com> Reviewed-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Herton Ronaldo Krzesinski <herton.krzesinski@canonical.com>
-rw-r--r--drivers/net/e1000e/82571.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/e1000e/82571.c b/drivers/net/e1000e/82571.c
index 8295f219243..5278e8456b6 100644
--- a/drivers/net/e1000e/82571.c
+++ b/drivers/net/e1000e/82571.c
@@ -1573,6 +1573,9 @@ static s32 e1000_check_for_serdes_link_82571(struct e1000_hw *hw)
1573 ctrl = er32(CTRL); 1573 ctrl = er32(CTRL);
1574 status = er32(STATUS); 1574 status = er32(STATUS);
1575 rxcw = er32(RXCW); 1575 rxcw = er32(RXCW);
1576 /* SYNCH bit and IV bit are sticky */
1577 udelay(10);
1578 rxcw = er32(RXCW);
1576 1579
1577 if ((rxcw & E1000_RXCW_SYNCH) && !(rxcw & E1000_RXCW_IV)) { 1580 if ((rxcw & E1000_RXCW_SYNCH) && !(rxcw & E1000_RXCW_IV)) {
1578 1581