Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 290024
b: refs/heads/master
c: e68782e
h: refs/heads/master
v: v3
  • Loading branch information
Bruce Allan authored and Jeff Kirsher committed Feb 7, 2012
1 parent a8dbc26 commit 9d97b50
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 22 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: 9e2d7657e2a8fb40f732563dffb05151ea2d7e01
refs/heads/master: e68782ed789a8e52af410368a185b3768fa64614
28 changes: 7 additions & 21 deletions trunk/drivers/net/ethernet/intel/e1000e/80003es2lan.c
Original file line number Diff line number Diff line change
Expand Up @@ -205,15 +205,20 @@ static s32 e1000_init_mac_params_80003es2lan(struct e1000_adapter *adapter)
{
struct e1000_hw *hw = &adapter->hw;
struct e1000_mac_info *mac = &hw->mac;
struct e1000_mac_operations *func = &mac->ops;

/* Set media type */
/* Set media type and media-dependent function pointers */
switch (adapter->pdev->device) {
case E1000_DEV_ID_80003ES2LAN_SERDES_DPT:
hw->phy.media_type = e1000_media_type_internal_serdes;
mac->ops.check_for_link = e1000e_check_for_serdes_link;
mac->ops.setup_physical_interface =
e1000e_setup_fiber_serdes_link;
break;
default:
hw->phy.media_type = e1000_media_type_copper;
mac->ops.check_for_link = e1000e_check_for_copper_link;
mac->ops.setup_physical_interface =
e1000_setup_copper_link_80003es2lan;
break;
}

Expand All @@ -230,25 +235,6 @@ static s32 e1000_init_mac_params_80003es2lan(struct e1000_adapter *adapter)
/* Adaptive IFS not supported */
mac->adaptive_ifs = false;

/* check for link */
switch (hw->phy.media_type) {
case e1000_media_type_copper:
func->setup_physical_interface = e1000_setup_copper_link_80003es2lan;
func->check_for_link = e1000e_check_for_copper_link;
break;
case e1000_media_type_fiber:
func->setup_physical_interface = e1000e_setup_fiber_serdes_link;
func->check_for_link = e1000e_check_for_fiber_link;
break;
case e1000_media_type_internal_serdes:
func->setup_physical_interface = e1000e_setup_fiber_serdes_link;
func->check_for_link = e1000e_check_for_serdes_link;
break;
default:
return -E1000_ERR_CONFIG;
break;
}

/* set lan id for port to determine which phy lock to use */
hw->mac.ops.set_lan_id(hw);

Expand Down

0 comments on commit 9d97b50

Please sign in to comment.