diff options
author | Joe Perches <joe@perches.com> | 2010-02-09 11:49:48 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-12 13:27:44 -0800 |
commit | ba211e3ec35820eced89bfe12e2d94e6352a4c5f (patch) | |
tree | 997d133bb18f347534b7a70536b693cd2a9843a1 /drivers/net/atl1e/atl1e_hw.c | |
parent | 571ba42303813106d533bf6bda929d8e289f51bf (diff) | |
download | op-kernel-dev-ba211e3ec35820eced89bfe12e2d94e6352a4c5f.zip op-kernel-dev-ba211e3ec35820eced89bfe12e2d94e6352a4c5f.tar.gz |
drivers/net/atl1e: Use netdev_printk helpers
Logging messages sometimes had duplicated "ATL1E" output.
For instance:
ATL1E 0000:03:00.0: ATL1E: eth0 NIC Link is Up<100 Mbps Full Duplex>
is now:
ATL1E 0000:03:00.0: eth0: NIC Link is Up <100 Mbps Full Duplex>
Add some consistency to logging messages
Add some missing \n's to logging messages
Miscellaneous typo spelling corrections
Change atl1e_validate_option argument from pdev to adapter
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/atl1e/atl1e_hw.c')
-rw-r--r-- | drivers/net/atl1e/atl1e_hw.c | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/drivers/net/atl1e/atl1e_hw.c b/drivers/net/atl1e/atl1e_hw.c index 4a77006..76cc043 100644 --- a/drivers/net/atl1e/atl1e_hw.c +++ b/drivers/net/atl1e/atl1e_hw.c @@ -394,7 +394,6 @@ static int atl1e_phy_setup_autoneg_adv(struct atl1e_hw *hw) int atl1e_phy_commit(struct atl1e_hw *hw) { struct atl1e_adapter *adapter = hw->adapter; - struct pci_dev *pdev = adapter->pdev; int ret_val; u16 phy_data; @@ -415,12 +414,12 @@ int atl1e_phy_commit(struct atl1e_hw *hw) } if (0 != (val & (MDIO_START | MDIO_BUSY))) { - dev_err(&pdev->dev, - "pcie linkdown at least for 25ms\n"); + netdev_err(adapter->netdev, + "pcie linkdown at least for 25ms\n"); return ret_val; } - dev_err(&pdev->dev, "pcie linkup after %d ms\n", i); + netdev_err(adapter->netdev, "pcie linkup after %d ms\n", i); } return 0; } @@ -428,7 +427,6 @@ int atl1e_phy_commit(struct atl1e_hw *hw) int atl1e_phy_init(struct atl1e_hw *hw) { struct atl1e_adapter *adapter = hw->adapter; - struct pci_dev *pdev = adapter->pdev; s32 ret_val; u16 phy_val; @@ -492,20 +490,22 @@ int atl1e_phy_init(struct atl1e_hw *hw) /*Enable PHY LinkChange Interrupt */ ret_val = atl1e_write_phy_reg(hw, MII_INT_CTRL, 0xC00); if (ret_val) { - dev_err(&pdev->dev, "Error enable PHY linkChange Interrupt\n"); + netdev_err(adapter->netdev, + "Error enable PHY linkChange Interrupt\n"); return ret_val; } /* setup AutoNeg parameters */ ret_val = atl1e_phy_setup_autoneg_adv(hw); if (ret_val) { - dev_err(&pdev->dev, "Error Setting up Auto-Negotiation\n"); + netdev_err(adapter->netdev, + "Error Setting up Auto-Negotiation\n"); return ret_val; } /* SW.Reset & En-Auto-Neg to restart Auto-Neg*/ - dev_dbg(&pdev->dev, "Restarting Auto-Neg"); + netdev_dbg(adapter->netdev, "Restarting Auto-Negotiation\n"); ret_val = atl1e_phy_commit(hw); if (ret_val) { - dev_err(&pdev->dev, "Error Resetting the phy"); + netdev_err(adapter->netdev, "Error resetting the phy\n"); return ret_val; } @@ -559,9 +559,8 @@ int atl1e_reset_hw(struct atl1e_hw *hw) } if (timeout >= AT_HW_MAX_IDLE_DELAY) { - dev_err(&pdev->dev, - "MAC state machine cann't be idle since" - " disabled for 10ms second\n"); + netdev_err(adapter->netdev, + "MAC state machine can't be idle since disabled for 10ms second\n"); return AT_ERR_TIMEOUT; } |