aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch
diff options
context:
space:
mode:
authorScott Roberts <ttocsr@gmail.com>2020-01-23 21:45:53 -0700
committerHauke Mehrtens <hauke@hauke-m.de>2020-01-26 19:20:00 +0100
commita461f984c450a49bce1cac191620a8ee2a3329c0 (patch)
tree50f676499980f8baab2f97a67918ea8f60b07e72 /target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch
parent996f02e5bafad2815e72821c19d41fb5297e4dad (diff)
downloadupstream-a461f984c450a49bce1cac191620a8ee2a3329c0.tar.gz
upstream-a461f984c450a49bce1cac191620a8ee2a3329c0.tar.bz2
upstream-a461f984c450a49bce1cac191620a8ee2a3329c0.zip
kernel: sfp: add Nokia SFP fix from net-next
Add Nokia GPON ONT SFP fix for tx_fault in net-next. Signed-off-by: Scott Roberts <ttocsr@gmail.com>
Diffstat (limited to 'target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch')
-rw-r--r--target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch10
1 files changed, 5 insertions, 5 deletions
diff --git a/target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch b/target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch
index 526c7962cc..46d987344f 100644
--- a/target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch
+++ b/target/linux/generic/pending-4.19/759-net-sfp-re-attempt-probing-for-phy.patch
@@ -35,7 +35,7 @@ Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
[SFP_S_INIT_TX_FAULT] = "init_tx_fault",
[SFP_S_WAIT_LOS] = "wait_los",
[SFP_S_LINK_UP] = "link_up",
-@@ -168,6 +170,12 @@ static const enum gpiod_flags gpio_flags
+@@ -178,6 +180,12 @@ static const enum gpiod_flags gpio_flags
#define N_FAULT_INIT 5
#define N_FAULT 5
@@ -48,7 +48,7 @@ Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
/* SFP module presence detection is poor: the three MOD DEF signals are
* the same length on the PCB, which means it's possible for MOD DEF 0 to
* connect before the I2C bus on MOD DEF 1/2.
-@@ -223,6 +231,7 @@ struct sfp {
+@@ -233,6 +241,7 @@ struct sfp {
unsigned char sm_dev_state;
unsigned short sm_state;
unsigned char sm_fault_retries;
@@ -56,7 +56,7 @@ Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
struct sfp_eeprom_id id;
unsigned int module_power_mW;
-@@ -1340,10 +1349,8 @@ static int sfp_sm_probe_phy(struct sfp *
+@@ -1351,10 +1360,8 @@ static int sfp_sm_probe_phy(struct sfp *
int err;
phy = get_phy_device(sfp->i2c_mii, SFP_PHY_ADDR, is_c45);
@@ -69,7 +69,7 @@ Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
if (IS_ERR(phy)) {
dev_err(sfp->dev, "mdiobus scan returned %ld\n", PTR_ERR(phy));
return PTR_ERR(phy);
-@@ -1785,6 +1792,7 @@ static void sfp_sm_module(struct sfp *sf
+@@ -1802,6 +1809,7 @@ static void sfp_sm_module(struct sfp *sf
static void sfp_sm_main(struct sfp *sfp, unsigned int event)
{
unsigned long timeout;
@@ -77,7 +77,7 @@ Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
/* Some events are global */
if (sfp->sm_state != SFP_S_DOWN &&
-@@ -1857,22 +1865,39 @@ static void sfp_sm_main(struct sfp *sfp,
+@@ -1875,22 +1883,39 @@ static void sfp_sm_main(struct sfp *sfp,
sfp_sm_fault(sfp, SFP_S_INIT_TX_FAULT,
sfp->sm_fault_retries == N_FAULT_INIT);
} else if (event == SFP_E_TIMEOUT || event == SFP_E_TX_CLEAR) {