]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
UBUNTU: SAUCE: e1000e: disable force K1-off feature
authorKai-Heng Feng <kai.heng.feng@canonical.com>
Thu, 11 Jul 2019 07:16:46 +0000 (15:16 +0800)
committerAndrea Righi <andrea.righi@canonical.com>
Mon, 15 Feb 2021 07:25:45 +0000 (08:25 +0100)
BugLink: https://bugs.launchpad.net/bugs/1836152
Forwardport from http://mails.dpdk.org/archives/dev/2016-November/050658.html

MAC-PHY desync may occur causing misdetection of link up event.
Disabling K1-off feature can work around the problem.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=204057

Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
(cherry picked from commit 3a818fd5094bd988b371228b12ed33531d727d15
 git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue.git dev-queue)
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
drivers/net/ethernet/intel/e1000e/hw.h
drivers/net/ethernet/intel/e1000e/ich8lan.c

index 69a2329ea463d7bfe428b7e39539e61921680999..084861b1d495d0c4e31f7a5bcf7556cffb372104 100644 (file)
@@ -685,6 +685,7 @@ struct e1000_dev_spec_ich8lan {
        bool kmrn_lock_loss_workaround_enabled;
        struct e1000_shadow_ram shadow_ram[E1000_ICH8_SHADOW_RAM_WORDS];
        bool nvm_k1_enabled;
+       bool disable_k1_off;
        bool eee_disable;
        u16 eee_lp_ability;
        enum e1000_ulp_state ulp_state;
index 6fb46682b058a297c701ab3c14c8dde7a9f670a9..16cd6c7cd8cc87b32e27d2d2ca9c89184b44b0b1 100644 (file)
@@ -1560,6 +1560,9 @@ static s32 e1000_check_for_copper_link_ich8lan(struct e1000_hw *hw)
                                fextnvm6 &= ~E1000_FEXTNVM6_K1_OFF_ENABLE;
                }
 
+               if (hw->dev_spec.ich8lan.disable_k1_off == true)
+                       fextnvm6 &= ~E1000_FEXTNVM6_K1_OFF_ENABLE;
+
                ew32(FEXTNVM6, fextnvm6);
        }