diff options
-rw-r--r-- | drivers/net/jme.c | 6 | ||||
-rw-r--r-- | drivers/net/jme.h | 8 |
2 files changed, 10 insertions, 4 deletions
diff --git a/drivers/net/jme.c b/drivers/net/jme.c index 490bc0feff3d..6996d04e1de4 100644 --- a/drivers/net/jme.c +++ b/drivers/net/jme.c | |||
@@ -439,16 +439,14 @@ jme_check_link(struct net_device *netdev, int testonly) | |||
439 | 439 | ||
440 | if (phylink & PHY_LINK_DUPLEX) { | 440 | if (phylink & PHY_LINK_DUPLEX) { |
441 | jwrite32(jme, JME_TXMCS, TXMCS_DEFAULT); | 441 | jwrite32(jme, JME_TXMCS, TXMCS_DEFAULT); |
442 | jwrite32(jme, JME_TXTRHD, TXTRHD_FULLDUPLEX); | ||
442 | ghc |= GHC_DPX; | 443 | ghc |= GHC_DPX; |
443 | } else { | 444 | } else { |
444 | jwrite32(jme, JME_TXMCS, TXMCS_DEFAULT | | 445 | jwrite32(jme, JME_TXMCS, TXMCS_DEFAULT | |
445 | TXMCS_BACKOFF | | 446 | TXMCS_BACKOFF | |
446 | TXMCS_CARRIERSENSE | | 447 | TXMCS_CARRIERSENSE | |
447 | TXMCS_COLLISION); | 448 | TXMCS_COLLISION); |
448 | jwrite32(jme, JME_TXTRHD, TXTRHD_TXPEN | | 449 | jwrite32(jme, JME_TXTRHD, TXTRHD_HALFDUPLEX); |
449 | ((0x2000 << TXTRHD_TXP_SHIFT) & TXTRHD_TXP) | | ||
450 | TXTRHD_TXREN | | ||
451 | ((8 << TXTRHD_TXRL_SHIFT) & TXTRHD_TXRL)); | ||
452 | } | 450 | } |
453 | 451 | ||
454 | gpreg1 = GPREG1_DEFAULT; | 452 | gpreg1 = GPREG1_DEFAULT; |
diff --git a/drivers/net/jme.h b/drivers/net/jme.h index dc4af5753a9e..b33bc5b0bb4e 100644 --- a/drivers/net/jme.h +++ b/drivers/net/jme.h | |||
@@ -658,6 +658,14 @@ enum jme_txtrhd_shifts { | |||
658 | TXTRHD_TXRL_SHIFT = 0, | 658 | TXTRHD_TXRL_SHIFT = 0, |
659 | }; | 659 | }; |
660 | 660 | ||
661 | enum jme_txtrhd_values { | ||
662 | TXTRHD_FULLDUPLEX = 0x00000000, | ||
663 | TXTRHD_HALFDUPLEX = TXTRHD_TXPEN | | ||
664 | ((0x2000 << TXTRHD_TXP_SHIFT) & TXTRHD_TXP) | | ||
665 | TXTRHD_TXREN | | ||
666 | ((8 << TXTRHD_TXRL_SHIFT) & TXTRHD_TXRL), | ||
667 | }; | ||
668 | |||
661 | /* | 669 | /* |
662 | * RX Control/Status Bits | 670 | * RX Control/Status Bits |
663 | */ | 671 | */ |