8390p.c 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. /* 8390 core for ISA devices needing bus delays */
  2. static const char version[] =
  3. "8390p.c:v1.10cvs 9/23/94 Donald Becker (becker@cesdis.gsfc.nasa.gov)\n";
  4. #define ei_inb(_p) inb(_p)
  5. #define ei_outb(_v, _p) outb(_v, _p)
  6. #define ei_inb_p(_p) inb_p(_p)
  7. #define ei_outb_p(_v, _p) outb_p(_v, _p)
  8. #include "lib8390.c"
  9. int eip_open(struct net_device *dev)
  10. {
  11. return __ei_open(dev);
  12. }
  13. EXPORT_SYMBOL(eip_open);
  14. int eip_close(struct net_device *dev)
  15. {
  16. return __ei_close(dev);
  17. }
  18. EXPORT_SYMBOL(eip_close);
  19. netdev_tx_t eip_start_xmit(struct sk_buff *skb, struct net_device *dev)
  20. {
  21. return __ei_start_xmit(skb, dev);
  22. }
  23. EXPORT_SYMBOL(eip_start_xmit);
  24. struct net_device_stats *eip_get_stats(struct net_device *dev)
  25. {
  26. return __ei_get_stats(dev);
  27. }
  28. EXPORT_SYMBOL(eip_get_stats);
  29. void eip_set_multicast_list(struct net_device *dev)
  30. {
  31. __ei_set_multicast_list(dev);
  32. }
  33. EXPORT_SYMBOL(eip_set_multicast_list);
  34. void eip_tx_timeout(struct net_device *dev)
  35. {
  36. __ei_tx_timeout(dev);
  37. }
  38. EXPORT_SYMBOL(eip_tx_timeout);
  39. irqreturn_t eip_interrupt(int irq, void *dev_id)
  40. {
  41. return __ei_interrupt(irq, dev_id);
  42. }
  43. EXPORT_SYMBOL(eip_interrupt);
  44. #ifdef CONFIG_NET_POLL_CONTROLLER
  45. void eip_poll(struct net_device *dev)
  46. {
  47. __ei_poll(dev);
  48. }
  49. EXPORT_SYMBOL(eip_poll);
  50. #endif
  51. const struct net_device_ops eip_netdev_ops = {
  52. .ndo_open = eip_open,
  53. .ndo_stop = eip_close,
  54. .ndo_start_xmit = eip_start_xmit,
  55. .ndo_tx_timeout = eip_tx_timeout,
  56. .ndo_get_stats = eip_get_stats,
  57. .ndo_set_multicast_list = eip_set_multicast_list,
  58. .ndo_validate_addr = eth_validate_addr,
  59. .ndo_set_mac_address = eth_mac_addr,
  60. .ndo_change_mtu = eth_change_mtu,
  61. #ifdef CONFIG_NET_POLL_CONTROLLER
  62. .ndo_poll_controller = eip_poll,
  63. #endif
  64. };
  65. EXPORT_SYMBOL(eip_netdev_ops);
  66. struct net_device *__alloc_eip_netdev(int size)
  67. {
  68. struct net_device *dev = ____alloc_ei_netdev(size);
  69. if (dev)
  70. dev->netdev_ops = &eip_netdev_ops;
  71. return dev;
  72. }
  73. EXPORT_SYMBOL(__alloc_eip_netdev);
  74. void NS8390p_init(struct net_device *dev, int startp)
  75. {
  76. __NS8390_init(dev, startp);
  77. }
  78. EXPORT_SYMBOL(NS8390p_init);
  79. static int __init NS8390p_init_module(void)
  80. {
  81. return 0;
  82. }
  83. static void __exit NS8390p_cleanup_module(void)
  84. {
  85. }
  86. module_init(NS8390p_init_module);
  87. module_exit(NS8390p_cleanup_module);
  88. MODULE_LICENSE("GPL");