Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

amd8111e: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Stephen Hemminger and committed by
David S. Miller
887e53d2 b1da683d

+21 -14
+21 -14
drivers/net/amd8111e.c
··· 1813 1813 lp->ext_phy_addr = 1; 1814 1814 } 1815 1815 1816 + static const struct net_device_ops amd8111e_netdev_ops = { 1817 + .ndo_open = amd8111e_open, 1818 + .ndo_stop = amd8111e_close, 1819 + .ndo_start_xmit = amd8111e_start_xmit, 1820 + .ndo_tx_timeout = amd8111e_tx_timeout, 1821 + .ndo_get_stats = amd8111e_get_stats, 1822 + .ndo_set_multicast_list = amd8111e_set_multicast_list, 1823 + .ndo_validate_addr = eth_validate_addr, 1824 + .ndo_set_mac_address = amd8111e_set_mac_address, 1825 + .ndo_do_ioctl = amd8111e_ioctl, 1826 + .ndo_change_mtu = amd8111e_change_mtu, 1827 + #if AMD8111E_VLAN_TAG_USED 1828 + .ndo_vlan_rx_register = amd8111e_vlan_rx_register, 1829 + #endif 1830 + #ifdef CONFIG_NET_POLL_CONTROLLER 1831 + .ndo_poll_controller = amd8111e_poll, 1832 + #endif 1833 + }; 1834 + 1816 1835 static int __devinit amd8111e_probe_one(struct pci_dev *pdev, 1817 1836 const struct pci_device_id *ent) 1818 1837 { ··· 1891 1872 1892 1873 #if AMD8111E_VLAN_TAG_USED 1893 1874 dev->features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX ; 1894 - dev->vlan_rx_register =amd8111e_vlan_rx_register; 1895 1875 #endif 1896 1876 1897 1877 lp = netdev_priv(dev); ··· 1919 1901 if(dynamic_ipg[card_idx++]) 1920 1902 lp->options |= OPTION_DYN_IPG_ENABLE; 1921 1903 1904 + 1922 1905 /* Initialize driver entry points */ 1923 - dev->open = amd8111e_open; 1924 - dev->hard_start_xmit = amd8111e_start_xmit; 1925 - dev->stop = amd8111e_close; 1926 - dev->get_stats = amd8111e_get_stats; 1927 - dev->set_multicast_list = amd8111e_set_multicast_list; 1928 - dev->set_mac_address = amd8111e_set_mac_address; 1929 - dev->do_ioctl = amd8111e_ioctl; 1930 - dev->change_mtu = amd8111e_change_mtu; 1906 + dev->netdev_ops = &amd8111e_netdev_ops; 1931 1907 SET_ETHTOOL_OPS(dev, &ops); 1932 1908 dev->irq =pdev->irq; 1933 - dev->tx_timeout = amd8111e_tx_timeout; 1934 1909 dev->watchdog_timeo = AMD8111E_TX_TIMEOUT; 1935 1910 netif_napi_add(dev, &lp->napi, amd8111e_rx_poll, 32); 1936 - #ifdef CONFIG_NET_POLL_CONTROLLER 1937 - dev->poll_controller = amd8111e_poll; 1938 - #endif 1939 1911 1940 1912 #if AMD8111E_VLAN_TAG_USED 1941 1913 dev->features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX; 1942 - dev->vlan_rx_register =amd8111e_vlan_rx_register; 1943 1914 #endif 1944 1915 /* Probe the external PHY */ 1945 1916 amd8111e_probe_ext_phy(dev);