Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 110138
b: refs/heads/master
c: 23033fa
h: refs/heads/master
v: v3
  • Loading branch information
Jesse Brandeburg authored and Linus Torvalds committed Oct 3, 2008
1 parent 6d52220 commit 56c0eac
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 15 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: a8f88ff5a5abc2ce9f7d7d2694178b2c617d713a
refs/heads/master: 23033fad5be0a2c7838cb9e1579919b64af713f6
6 changes: 5 additions & 1 deletion trunk/drivers/net/e1000e/ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,10 @@ static void e1000_get_regs(struct net_device *netdev,
regs_buff[11] = er32(TIDV);

regs_buff[12] = adapter->hw.phy.type; /* PHY type (IGP=1, M88=0) */

/* ethtool doesn't use anything past this point, so all this
* code is likely legacy junk for apps that may or may not
* exist */
if (hw->phy.type == e1000_phy_m88) {
e1e_rphy(hw, M88E1000_PHY_SPEC_STATUS, &phy_data);
regs_buff[13] = (u32)phy_data; /* cable length */
Expand All @@ -447,7 +451,7 @@ static void e1000_get_regs(struct net_device *netdev,
regs_buff[22] = adapter->phy_stats.receive_errors;
regs_buff[23] = regs_buff[13]; /* mdix mode */
}
regs_buff[21] = adapter->phy_stats.idle_errors; /* phy idle errors */
regs_buff[21] = 0; /* was idle_errors */
e1e_rphy(hw, PHY_1000T_STATUS, &phy_data);
regs_buff[24] = (u32)phy_data; /* phy local receiver status */
regs_buff[25] = regs_buff[24]; /* phy remote receiver status */
Expand Down
13 changes: 0 additions & 13 deletions trunk/drivers/net/e1000e/netdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -2954,9 +2954,6 @@ void e1000e_update_stats(struct e1000_adapter *adapter)
struct e1000_hw *hw = &adapter->hw;
struct pci_dev *pdev = adapter->pdev;
unsigned long irq_flags;
u16 phy_tmp;

#define PHY_IDLE_ERROR_COUNT_MASK 0x00FF

/*
* Prevent stats update while adapter is being reset, or if the pci
Expand Down Expand Up @@ -3045,15 +3042,6 @@ void e1000e_update_stats(struct e1000_adapter *adapter)

/* Tx Dropped needs to be maintained elsewhere */

/* Phy Stats */
if (hw->phy.media_type == e1000_media_type_copper) {
if ((adapter->link_speed == SPEED_1000) &&
(!e1e_rphy(hw, PHY_1000T_STATUS, &phy_tmp))) {
phy_tmp &= PHY_IDLE_ERROR_COUNT_MASK;
adapter->phy_stats.idle_errors += phy_tmp;
}
}

/* Management Stats */
adapter->stats.mgptc += er32(MGTPTC);
adapter->stats.mgprc += er32(MGTPRC);
Expand All @@ -3073,7 +3061,6 @@ static void e1000_phy_read_status(struct e1000_adapter *adapter)
int ret_val;
unsigned long irq_flags;


spin_lock_irqsave(&adapter->stats_lock, irq_flags);

if ((er32(STATUS) & E1000_STATUS_LU) &&
Expand Down

0 comments on commit 56c0eac

Please sign in to comment.