blob: fbe609a51e02c5952e6b437f8183e344af0c4fbc [file] [log] [blame]
Al Viro6c3561b2006-10-10 00:19:36 +01001/* 8390 core for usual drivers */
Linus Torvalds1da177e2005-04-16 15:20:36 -07002
3static const char version[] =
4 "8390.c:v1.10cvs 9/23/94 Donald Becker (becker@cesdis.gsfc.nasa.gov)\n";
5
Al Viro6c3561b2006-10-10 00:19:36 +01006#include "lib8390.c"
Linus Torvalds1da177e2005-04-16 15:20:36 -07007
Linus Torvalds1da177e2005-04-16 15:20:36 -07008int ei_open(struct net_device *dev)
9{
Al Viro6c3561b2006-10-10 00:19:36 +010010 return __ei_open(dev);
Linus Torvalds1da177e2005-04-16 15:20:36 -070011}
Gustavo F. Padovan11795aa2008-08-02 15:55:13 -030012EXPORT_SYMBOL(ei_open);
Linus Torvalds1da177e2005-04-16 15:20:36 -070013
Linus Torvalds1da177e2005-04-16 15:20:36 -070014int ei_close(struct net_device *dev)
15{
Al Viro6c3561b2006-10-10 00:19:36 +010016 return __ei_close(dev);
Linus Torvalds1da177e2005-04-16 15:20:36 -070017}
Gustavo F. Padovan11795aa2008-08-02 15:55:13 -030018EXPORT_SYMBOL(ei_close);
Linus Torvalds1da177e2005-04-16 15:20:36 -070019
Stephen Hemminger8884c092008-11-25 18:12:49 -080020int ei_start_xmit(struct sk_buff *skb, struct net_device *dev)
21{
22 return __ei_start_xmit(skb, dev);
23}
24EXPORT_SYMBOL(ei_start_xmit);
25
26struct net_device_stats *ei_get_stats(struct net_device *dev)
27{
28 return __ei_get_stats(dev);
29}
30EXPORT_SYMBOL(ei_get_stats);
31
32void ei_set_multicast_list(struct net_device *dev)
33{
34 __ei_set_multicast_list(dev);
35}
36EXPORT_SYMBOL(ei_set_multicast_list);
37
38void ei_tx_timeout(struct net_device *dev)
39{
40 __ei_tx_timeout(dev);
41}
42EXPORT_SYMBOL(ei_tx_timeout);
43
David Howells7d12e782006-10-05 14:55:46 +010044irqreturn_t ei_interrupt(int irq, void *dev_id)
Linus Torvalds1da177e2005-04-16 15:20:36 -070045{
Al Viro6c3561b2006-10-10 00:19:36 +010046 return __ei_interrupt(irq, dev_id);
Linus Torvalds1da177e2005-04-16 15:20:36 -070047}
Gustavo F. Padovan11795aa2008-08-02 15:55:13 -030048EXPORT_SYMBOL(ei_interrupt);
Linus Torvalds1da177e2005-04-16 15:20:36 -070049
50#ifdef CONFIG_NET_POLL_CONTROLLER
51void ei_poll(struct net_device *dev)
52{
Al Viro6c3561b2006-10-10 00:19:36 +010053 __ei_poll(dev);
Linus Torvalds1da177e2005-04-16 15:20:36 -070054}
Gustavo F. Padovan11795aa2008-08-02 15:55:13 -030055EXPORT_SYMBOL(ei_poll);
Linus Torvalds1da177e2005-04-16 15:20:36 -070056#endif
57
Stephen Hemminger8884c092008-11-25 18:12:49 -080058const struct net_device_ops ei_netdev_ops = {
59 .ndo_open = ei_open,
60 .ndo_stop = ei_close,
61 .ndo_start_xmit = ei_start_xmit,
62 .ndo_tx_timeout = ei_tx_timeout,
63 .ndo_get_stats = ei_get_stats,
64 .ndo_set_multicast_list = ei_set_multicast_list,
65 .ndo_validate_addr = eth_validate_addr,
66 .ndo_change_mtu = eth_change_mtu,
67#ifdef CONFIG_NET_POLL_CONTROLLER
68 .ndo_poll_controller = ei_poll,
69#endif
70};
71EXPORT_SYMBOL(ei_netdev_ops);
72
Linus Torvalds1da177e2005-04-16 15:20:36 -070073struct net_device *__alloc_ei_netdev(int size)
74{
David S. Miller9a4a8422008-12-15 15:14:59 -080075 struct net_device *dev = ____alloc_ei_netdev(size);
76#ifdef CONFIG_COMPAT_NET_DEV_OPS
77 if (dev) {
78 dev->hard_start_xmit = ei_start_xmit;
79 dev->get_stats = ei_get_stats;
80 dev->set_multicast_list = ei_set_multicast_list;
81 dev->tx_timeout = ei_tx_timeout;
82 }
83#endif
84 return dev;
Linus Torvalds1da177e2005-04-16 15:20:36 -070085}
Gustavo F. Padovan11795aa2008-08-02 15:55:13 -030086EXPORT_SYMBOL(__alloc_ei_netdev);
Linus Torvalds1da177e2005-04-16 15:20:36 -070087
Linus Torvalds1da177e2005-04-16 15:20:36 -070088void NS8390_init(struct net_device *dev, int startp)
89{
Harvey Harrisonab598592008-05-01 02:47:38 -070090 __NS8390_init(dev, startp);
Linus Torvalds1da177e2005-04-16 15:20:36 -070091}
Linus Torvalds1da177e2005-04-16 15:20:36 -070092EXPORT_SYMBOL(NS8390_init);
Linus Torvalds1da177e2005-04-16 15:20:36 -070093
94#if defined(MODULE)
95
Jon Schindler08dc7322008-02-28 01:30:14 -060096static int __init ns8390_module_init(void)
Linus Torvalds1da177e2005-04-16 15:20:36 -070097{
98 return 0;
99}
100
Jon Schindler08dc7322008-02-28 01:30:14 -0600101static void __exit ns8390_module_exit(void)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700102{
103}
104
David S. Millerd5706ef2008-03-22 18:33:28 -0700105module_init(ns8390_module_init);
Jon Schindler08dc7322008-02-28 01:30:14 -0600106module_exit(ns8390_module_exit);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700107#endif /* MODULE */
108MODULE_LICENSE("GPL");