diff options
Diffstat (limited to 'drivers/net/ethernet/marvell/pxa168_eth.c')
| -rw-r--r-- | drivers/net/ethernet/marvell/pxa168_eth.c | 29 | 
1 files changed, 4 insertions, 25 deletions
diff --git a/drivers/net/ethernet/marvell/pxa168_eth.c b/drivers/net/ethernet/marvell/pxa168_eth.c index 4ae0c742601..8f5aa7c62b1 100644 --- a/drivers/net/ethernet/marvell/pxa168_eth.c +++ b/drivers/net/ethernet/marvell/pxa168_eth.c @@ -19,11 +19,9 @@   * GNU General Public License for more details.   *   * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA. + * along with this program; if not, see <http://www.gnu.org/licenses/>.   */ -#include <linux/init.h>  #include <linux/dma-mapping.h>  #include <linux/in.h>  #include <linux/ip.h> @@ -321,23 +319,6 @@ static void ethernet_phy_set_addr(struct pxa168_eth_private *pep, int phy_addr)  	wrl(pep, PHY_ADDRESS, reg_data);  } -static void ethernet_phy_reset(struct pxa168_eth_private *pep) -{ -	int data; - -	data = phy_read(pep->phy, MII_BMCR); -	if (data < 0) -		return; - -	data |= BMCR_RESET; -	if (phy_write(pep->phy, MII_BMCR, data) < 0) -		return; - -	do { -		data = phy_read(pep->phy, MII_BMCR); -	} while (data >= 0 && data & BMCR_RESET); -} -  static void rxq_refill(struct net_device *dev)  {  	struct pxa168_eth_private *pep = netdev_priv(dev); @@ -646,7 +627,7 @@ static void eth_port_start(struct net_device *dev)  		struct ethtool_cmd cmd;  		pxa168_get_settings(pep->dev, &cmd); -		ethernet_phy_reset(pep); +		phy_init_hw(pep->phy);  		pxa168_set_settings(pep->dev, &cmd);  	} @@ -1123,8 +1104,7 @@ static int pxa168_eth_open(struct net_device *dev)  	struct pxa168_eth_private *pep = netdev_priv(dev);  	int err; -	err = request_irq(dev->irq, pxa168_eth_int_handler, -			  IRQF_DISABLED, dev->name, dev); +	err = request_irq(dev->irq, pxa168_eth_int_handler, 0, dev->name, dev);  	if (err) {  		dev_err(&dev->dev, "can't assign irq\n");  		return -EAGAIN; @@ -1384,7 +1364,6 @@ static struct phy_device *phy_scan(struct pxa168_eth_private *pep, int phy_addr)  static void phy_init(struct pxa168_eth_private *pep, int speed, int duplex)  {  	struct phy_device *phy = pep->phy; -	ethernet_phy_reset(pep);  	phy_attach(pep->dev, dev_name(&phy->dev), PHY_INTERFACE_MODE_MII); @@ -1509,7 +1488,7 @@ static int pxa168_eth_probe(struct platform_device *pdev)  	dev->netdev_ops = &pxa168_eth_netdev_ops;  	dev->watchdog_timeo = 2 * HZ;  	dev->base_addr = 0; -	SET_ETHTOOL_OPS(dev, &pxa168_ethtool_ops); +	dev->ethtool_ops = &pxa168_ethtool_ops;  	INIT_WORK(&pep->tx_timeout_task, pxa168_eth_tx_timeout_task);  | 
