From: Bruce Allan Date: Fri, 16 Dec 2011 00:46:17 +0000 (+0000) Subject: e1000e: use hardware default values for Transmit Control register X-Git-Tag: v2.6.39-400.9.0~423^2~19^2~11^2~361 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=a38aa2c292c3b3da56cee3cf603f593739121234;p=users%2Fjedix%2Flinux-maple.git e1000e: use hardware default values for Transmit Control register This code snippet is simply writing default values to the register which is unnecessary since the values are programmed into the register by default. There is a special case for 80003es2lan needing the Retransmit on Late Collision bit set but that is also done in e1000_init_hw_80003es2lan(). (cherry picked from commit c550b121854eb1300148da1c2c8df6ed0dabdc66) Signed-off-by: Bruce Allan Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher Signed-off-by: Joe Jin --- diff --git a/drivers/net/e1000e/netdev.c b/drivers/net/e1000e/netdev.c index fcab5993dc7e..35038592b3b6 100644 --- a/drivers/net/e1000e/netdev.c +++ b/drivers/net/e1000e/netdev.c @@ -2758,7 +2758,7 @@ static void e1000_configure_tx(struct e1000_adapter *adapter) struct e1000_hw *hw = &adapter->hw; struct e1000_ring *tx_ring = adapter->tx_ring; u64 tdba; - u32 tdlen, tctl, tarc; + u32 tdlen, tarc; /* Setup the HW Tx Head and Tail descriptor pointers */ tdba = tx_ring->dma; @@ -2796,12 +2796,6 @@ static void e1000_configure_tx(struct e1000_adapter *adapter) /* erratum work around: set txdctl the same for both queues */ ew32(TXDCTL(1), er32(TXDCTL(0))); - /* Program the Transmit Control Register */ - tctl = er32(TCTL); - tctl &= ~E1000_TCTL_CT; - tctl |= E1000_TCTL_PSP | E1000_TCTL_RTLC | - (E1000_COLLISION_THRESHOLD << E1000_CT_SHIFT); - if (adapter->flags & FLAG_TARC_SPEED_MODE_BIT) { tarc = er32(TARC(0)); /* @@ -2833,8 +2827,6 @@ static void e1000_configure_tx(struct e1000_adapter *adapter) /* enable Report Status bit */ adapter->txd_cmd |= E1000_TXD_CMD_RS; - ew32(TCTL, tctl); - e1000e_config_collision_dist(hw); }