* txgbe_reset_phy - Performs a PHY reset * @hw: pointer to hardware structure **/
| 269 | * @hw: pointer to hardware structure |
| 270 | **/ |
| 271 | s32 txgbe_reset_phy(struct txgbe_hw *hw) |
| 272 | { |
| 273 | s32 err = 0; |
| 274 | |
| 275 | if (hw->phy.type == txgbe_phy_unknown) |
| 276 | err = txgbe_identify_phy(hw); |
| 277 | |
| 278 | if (err != 0 || hw->phy.type == txgbe_phy_none) |
| 279 | return err; |
| 280 | |
| 281 | /* Don't reset PHY if it's shut down due to overtemp. */ |
| 282 | if (hw->phy.check_overtemp(hw) == TXGBE_ERR_OVERTEMP) |
| 283 | return err; |
| 284 | |
| 285 | /* Blocked by MNG FW so bail */ |
| 286 | if (txgbe_check_reset_blocked(hw)) |
| 287 | return err; |
| 288 | |
| 289 | switch (hw->phy.type) { |
| 290 | case txgbe_phy_cu_mtd: |
| 291 | err = txgbe_reset_extphy(hw); |
| 292 | break; |
| 293 | default: |
| 294 | break; |
| 295 | } |
| 296 | |
| 297 | return err; |
| 298 | } |
| 299 | |
| 300 | /** |
| 301 | * txgbe_read_phy_mdi - Reads a value from a specified PHY register without |
nothing calls this directly
no test coverage detected