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

ariadne: convert to net_device_ops

On Fri, Apr 10, 2009 at 06:13:54PM +0200, Jan Ceuleers wrote:
> Alexander Beregalov wrote:
> >
> > Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
> ...
> > @@ -197,13 +209,8 @@ static int __devinit ariadne_init_one(struct zorro_dev *z,
> > dev->mem_start = ZTWO_VADDR(mem_start);
> > dev->mem_end = dev->mem_start+ARIADNE_RAM_SIZE;
> >
> > - dev->open = &ariadne_open;
> > - dev->stop = &ariadne_close;
> > - dev->hard_start_xmit = &ariadne_start_xmit;
> > - dev->tx_timeout = &ariadne_tx_timeout;
> > + dev->netdev_ops = &ariadne_netdev_ops;;
>
> We don't really need two semicolons there but I suppose that they won't
> hurt.
Thanks!

David, please apply this patch

Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Alexander Beregalov and committed by
David S. Miller
f97b1f2a 15efc02b

+13 -6
+13 -6
drivers/net/ariadne.c
··· 155 155 .remove = __devexit_p(ariadne_remove_one), 156 156 }; 157 157 158 + static const struct net_device_ops ariadne_netdev_ops = { 159 + .ndo_open = ariadne_open, 160 + .ndo_stop = ariadne_close, 161 + .ndo_start_xmit = ariadne_start_xmit, 162 + .ndo_tx_timeout = ariadne_tx_timeout, 163 + .ndo_get_stats = ariadne_get_stats, 164 + .ndo_set_multicast_list = set_multicast_list, 165 + .ndo_validate_addr = eth_validate_addr, 166 + .ndo_change_mtu = eth_change_mtu, 167 + .ndo_set_mac_address = eth_mac_addr, 168 + }; 169 + 158 170 static int __devinit ariadne_init_one(struct zorro_dev *z, 159 171 const struct zorro_device_id *ent) 160 172 { ··· 209 197 dev->mem_start = ZTWO_VADDR(mem_start); 210 198 dev->mem_end = dev->mem_start+ARIADNE_RAM_SIZE; 211 199 212 - dev->open = &ariadne_open; 213 - dev->stop = &ariadne_close; 214 - dev->hard_start_xmit = &ariadne_start_xmit; 215 - dev->tx_timeout = &ariadne_tx_timeout; 200 + dev->netdev_ops = &ariadne_netdev_ops; 216 201 dev->watchdog_timeo = 5*HZ; 217 - dev->get_stats = &ariadne_get_stats; 218 - dev->set_multicast_list = &set_multicast_list; 219 202 220 203 err = register_netdev(dev); 221 204 if (err) {