Print this page
3014 Intel X540 Support (fix lint)

*** 54,64 **** DEBUGFUNC("ixgbe_init_shared_code"); /* * Set the mac type */ ! ixgbe_set_mac_type(hw); switch (hw->mac.type) { case ixgbe_mac_82598EB: status = ixgbe_init_ops_82598(hw); break; --- 54,66 ---- DEBUGFUNC("ixgbe_init_shared_code"); /* * Set the mac type */ ! status = ixgbe_set_mac_type(hw); ! if (status != IXGBE_SUCCESS) ! return (status); switch (hw->mac.type) { case ixgbe_mac_82598EB: status = ixgbe_init_ops_82598(hw); break;
*** 446,460 **** * Reads a value from a specified PHY register **/ s32 ixgbe_read_phy_reg(struct ixgbe_hw *hw, u32 reg_addr, u32 device_type, u16 *phy_data) { if (hw->phy.id == 0) ! ixgbe_identify_phy(hw); ! return ixgbe_call_func(hw, hw->phy.ops.read_reg, (hw, reg_addr, ! device_type, phy_data), IXGBE_NOT_IMPLEMENTED); } /** * ixgbe_write_phy_reg - Write PHY register * @hw: pointer to hardware structure --- 448,470 ---- * Reads a value from a specified PHY register **/ s32 ixgbe_read_phy_reg(struct ixgbe_hw *hw, u32 reg_addr, u32 device_type, u16 *phy_data) { + s32 status; + if (hw->phy.id == 0) ! status = ixgbe_identify_phy(hw); ! else ! status = IXGBE_SUCCESS; ! if (status == IXGBE_SUCCESS) { ! status = ixgbe_call_func(hw, hw->phy.ops.read_reg, ! (hw, reg_addr, device_type, phy_data), ! IXGBE_NOT_IMPLEMENTED); ! } ! return (status); } /** * ixgbe_write_phy_reg - Write PHY register * @hw: pointer to hardware structure
*** 464,478 **** * Writes a value to specified PHY register **/ s32 ixgbe_write_phy_reg(struct ixgbe_hw *hw, u32 reg_addr, u32 device_type, u16 phy_data) { if (hw->phy.id == 0) ! ixgbe_identify_phy(hw); ! return ixgbe_call_func(hw, hw->phy.ops.write_reg, (hw, reg_addr, ! device_type, phy_data), IXGBE_NOT_IMPLEMENTED); } /** * ixgbe_setup_phy_link - Restart PHY autoneg * @hw: pointer to hardware structure --- 474,497 ---- * Writes a value to specified PHY register **/ s32 ixgbe_write_phy_reg(struct ixgbe_hw *hw, u32 reg_addr, u32 device_type, u16 phy_data) { + s32 status; + if (hw->phy.id == 0) ! status = ixgbe_identify_phy(hw); ! else ! status = IXGBE_SUCCESS; ! if (status == IXGBE_SUCCESS) { ! status = ixgbe_call_func(hw, hw->phy.ops.write_reg, ! (hw, reg_addr, device_type, phy_data), ! IXGBE_NOT_IMPLEMENTED); ! } ! ! return status; } /** * ixgbe_setup_phy_link - Restart PHY autoneg * @hw: pointer to hardware structure