Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 1372
b: refs/heads/master
c: 1125ecb
h: refs/heads/master
v: v3
  • Loading branch information
Malli Chilakala authored and Jeff Garzik committed May 13, 2005
1 parent fe97180 commit 80a60c4
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0e6ef3e02b6f07e37ba1c1abc059f8bee4e0847f
refs/heads/master: 1125ecbc0a89db07bb4eb1ba892a23367c3bdeb5
17 changes: 15 additions & 2 deletions trunk/drivers/net/e1000/e1000_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,10 @@ e1000_down(struct e1000_adapter *adapter)
void
e1000_reset(struct e1000_adapter *adapter)
{
struct net_device *netdev = adapter->netdev;
uint32_t pba, manc;
uint16_t fc_high_water_mark = E1000_FC_HIGH_DIFF;
uint16_t fc_low_water_mark = E1000_FC_LOW_DIFF;

/* Repartition Pba for greater than 9k mtu
* To take effect CTRL.RST is required.
Expand All @@ -428,6 +431,16 @@ e1000_reset(struct e1000_adapter *adapter)
break;
}

if((adapter->hw.mac_type != e1000_82573) &&
(adapter->rx_buffer_len > E1000_RXBUFFER_8192)) {
pba -= 8; /* allocate more FIFO for Tx */
/* send an XOFF when there is enough space in the
* Rx FIFO to hold one extra full size Rx packet
*/
fc_high_water_mark = netdev->mtu + ENET_HEADER_SIZE +
ETHERNET_FCS_SIZE + 1;
fc_low_water_mark = fc_high_water_mark + 8;
}


if(adapter->hw.mac_type == e1000_82547) {
Expand All @@ -442,9 +455,9 @@ e1000_reset(struct e1000_adapter *adapter)

/* flow control settings */
adapter->hw.fc_high_water = (pba << E1000_PBA_BYTES_SHIFT) -
E1000_FC_HIGH_DIFF;
fc_high_water_mark;
adapter->hw.fc_low_water = (pba << E1000_PBA_BYTES_SHIFT) -
E1000_FC_LOW_DIFF;
fc_low_water_mark;
adapter->hw.fc_pause_time = E1000_FC_PAUSE_TIME;
adapter->hw.fc_send_xon = 1;
adapter->hw.fc = adapter->hw.original_fc;
Expand Down

0 comments on commit 80a60c4

Please sign in to comment.