igc: Clean up and optimize watchdog task
Subsystems (2)
PATCH 1/1 igc: Clean up and optimize watchdog task
i225/i226 parts used only one media type copper. The copper media type is not replaceable. Clean up the code accordingly, and remove the obsolete media replacement and reset options.
Signed-off-by Sasha Neftin <[email protected]>
--- drivers/net/ethernet/intel/igc/igc.h | 2 -- drivers/net/ethernet/intel/igc/igc_main.c | 17 ----------------- 2 files changed, 19 deletions(-)
drivers/net/ethernet/intel/igc/igc.h +0 -2
@@ -292,8 +292,6 @@ extern char igc_driver_name[];#define IGC_FLAG_PTP BIT(8)#define IGC_FLAG_WOL_SUPPORTED BIT(8)#define IGC_FLAG_NEED_LINK_UPDATE BIT(9) -#define IGC_FLAG_MEDIA_RESET BIT(10) -#define IGC_FLAG_MAS_ENABLE BIT(12)#define IGC_FLAG_HAS_MSIX BIT(13)#define IGC_FLAG_EEE BIT(14)#define IGC_FLAG_VLAN_PROMISC BIT(15)
drivers/net/ethernet/intel/igc/igc_main.c +0 -17
@@ -5546,25 +5546,8 @@ static void igc_watchdog_task(struct work_struct *work)mod_timer (&adapter->phy_info_timer,round_jiffies (jiffies +2 *HZ )); -/* link is down, time to check for alternate media */ -if (adapter->flags &IGC_FLAG_MAS_ENABLE ) { -if (adapter->flags &IGC_FLAG_MEDIA_RESET ) { -schedule_work (&adapter->reset_task); -/* return immediately */ -return ; - } - }pm_schedule_suspend (netdev->dev.parent,MSEC_PER_SEC *5 ); - -/* also check for alternate media here */ - }else if (!netif_carrier_ok (netdev) && - (adapter->flags &IGC_FLAG_MAS_ENABLE )) { -if (adapter->flags &IGC_FLAG_MEDIA_RESET ) { -schedule_work (&adapter->reset_task); -/* return immediately */ -return ; - } } }
Signature · 6 lines
2.25.1 _______________________________________________ Intel-wired-lan mailing list [email protected] https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
Quoted 9 lines · Sasha Neftin
i225/i226 parts used only one media type copper. The copper media type is not replaceable. Clean up the code accordingly, and remove the obsolete media replacement and reset options.
Signed-off-by Sasha Neftin <[email protected]>--- drivers/net/ethernet/intel/igc/igc.h | 2 -- drivers/net/ethernet/intel/igc/igc_main.c | 17 ----------------- 2 files changed, 19 deletions(-)
Tested-by Naama Meir <[email protected]>
_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan