aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/tsec
diff options
context:
space:
mode:
authorJustin Hibbits <jhibbits@FreeBSD.org>2017-04-04 02:37:41 +0000
committerJustin Hibbits <jhibbits@FreeBSD.org>2017-04-04 02:37:41 +0000
commit72b58db80fe4f880f3c23dc8a9bf35754671e2cc (patch)
treecb5051ec034519f90482b75c4c1f0365dd34f123 /sys/dev/tsec
parentb11512cc9cd59cba6b1d5316657b0a0bf31256d5 (diff)
Notes
Diffstat (limited to 'sys/dev/tsec')
-rw-r--r--sys/dev/tsec/if_tsec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/tsec/if_tsec.c b/sys/dev/tsec/if_tsec.c
index fa239e9017f8..fbbb75cf0ce1 100644
--- a/sys/dev/tsec/if_tsec.c
+++ b/sys/dev/tsec/if_tsec.c
@@ -1597,7 +1597,7 @@ tsec_miibus_readreg(device_t dev, int phy, int reg)
rv = TSEC_PHY_READ(sc, TSEC_REG_MIIMSTAT);
TSEC_PHY_UNLOCK();
- if (timeout == 0)
+ if (timeout)
device_printf(dev, "Timeout while reading from PHY!\n");
return (rv);
@@ -1617,7 +1617,7 @@ tsec_miibus_writereg(device_t dev, int phy, int reg, int value)
timeout = tsec_mii_wait(sc, TSEC_MIIMIND_BUSY);
TSEC_PHY_UNLOCK();
- if (timeout == 0)
+ if (timeout)
device_printf(dev, "Timeout while writing to PHY!\n");
return (0);