generic: mt7530: fix EEE patch
authorDENG Qingfang <dqfext@gmail.com>
Fri, 7 May 2021 04:36:03 +0000 (12:36 +0800)
committerHauke Mehrtens <hauke@hauke-m.de>
Sun, 23 May 2021 13:11:38 +0000 (15:11 +0200)
The higher 16-bit of EEE register was overwritten by mistake, fix that.

Fixes: 5b9ba4a93e83 ("generic: mt7530: support adjusting EEE")
Signed-off-by: DENG Qingfang <dqfext@gmail.com>
target/linux/generic/pending-5.4/761-net-dsa-mt7530-Support-EEE-features.patch

index b9ca691f6f1170d4ff909365c13531982d6c8e69..0fd4151ad043c584be445df010c10facb2dbe1b8 100644 (file)
@@ -66,7 +66,7 @@ Signed-off-by: RenĂ© van Dorst <opensource@vdorst.com>
 +              eeecr &= 0xFFFF0000;
 +              if (!e->tx_lpi_enabled)
 +                      eeecr |= LPI_MODE_EN;
-+              eeecr = LPI_THRESH(e->tx_lpi_timer);
++              eeecr |= LPI_THRESH(e->tx_lpi_timer);
 +              mt7530_write(priv, MT7530_PMEEECR_P(port), eeecr);
 +      } else {
 +              priv->eee_enable &= ~(BIT(port));