1
0

190-2-5-e1000e-Fix-wrong-comment-related-to-link-detection.patch 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. From patchwork Fri Jul 21 18:36:24 2017
  2. Content-Type: text/plain; charset="utf-8"
  3. MIME-Version: 1.0
  4. Content-Transfer-Encoding: 7bit
  5. Subject: [2/5] e1000e: Fix wrong comment related to link detection
  6. From: Benjamin Poirier <bpoirier@suse.com>
  7. X-Patchwork-Id: 9857489
  8. Message-Id: <20170721183627.13373-2-bpoirier@suse.com>
  9. To: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
  10. Cc: Lennart Sorensen <lsorense@csclub.uwaterloo.ca>,
  11. intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org,
  12. linux-kernel@vger.kernel.org
  13. Date: Fri, 21 Jul 2017 11:36:24 -0700
  14. Reading e1000e_check_for_copper_link() shows that get_link_status is set to
  15. false after link has been detected. Therefore, it stays TRUE until then.
  16. Signed-off-by: Benjamin Poirier <bpoirier@suse.com>
  17. Tested-by: Aaron Brown <aaron.f.brown@intel.com>
  18. ---
  19. drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++--
  20. 1 file changed, 2 insertions(+), 2 deletions(-)
  21. --- a/drivers/net/ethernet/intel/e1000e/netdev.c
  22. +++ b/drivers/net/ethernet/intel/e1000e/netdev.c
  23. @@ -5067,7 +5067,7 @@ static bool e1000e_has_link(struct e1000
  24. /* get_link_status is set on LSC (link status) interrupt or
  25. * Rx sequence error interrupt. get_link_status will stay
  26. - * false until the check_for_link establishes link
  27. + * true until the check_for_link establishes link
  28. * for copper adapters ONLY
  29. */
  30. switch (hw->phy.media_type) {
  31. @@ -5085,7 +5085,7 @@ static bool e1000e_has_link(struct e1000
  32. break;
  33. case e1000_media_type_internal_serdes:
  34. ret_val = hw->mac.ops.check_for_link(hw);
  35. - link_active = adapter->hw.mac.serdes_has_link;
  36. + link_active = hw->mac.serdes_has_link;
  37. break;
  38. default:
  39. case e1000_media_type_unknown: