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

zorro8390: Fix regression caused during net_device_ops conversion

Changeset b6114794a1c394534659f4a17420e48cf23aa922 ("zorro8390: convert to
net_device_ops") broke zorro8390 by adding 8390.o to the link. That
meant that lib8390.c was included twice, once in zorro8390.c and once in
8390.c, subject to different macros. This patch reverts that by
avoiding the wrappers in 8390.c.

Fix based on commits 217cbfa856dc1cbc2890781626c4032d9e3ec59f ("mac8390:
fix regression caused during net_device_ops conversion") and
4e0168fa4842e27795a75b205a510f25b62181d9 ("mac8390: fix build with
NET_POLL_CONTROLLER").

Reported-by: Christian T. Steigies <cts@debian.org>
Suggested-by: Finn Thain <fthain@telegraphics.com.au>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Tested-by: Christian T. Steigies <cts@debian.org>
Cc: stable@kernel.org
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Geert Uytterhoeven and committed by
David S. Miller
cf7e032f d44cf14d

+7 -7
+1 -1
drivers/net/Makefile
··· 219 219 obj-$(CONFIG_LP486E) += lp486e.o 220 220 221 221 obj-$(CONFIG_ETH16I) += eth16i.o 222 - obj-$(CONFIG_ZORRO8390) += zorro8390.o 8390.o 222 + obj-$(CONFIG_ZORRO8390) += zorro8390.o 223 223 obj-$(CONFIG_HPLANCE) += hplance.o 7990.o 224 224 obj-$(CONFIG_MVME147_NET) += mvme147.o 7990.o 225 225 obj-$(CONFIG_EQUALIZER) += eql.o
+6 -6
drivers/net/zorro8390.c
··· 126 126 127 127 board = z->resource.start; 128 128 ioaddr = board+cards[i].offset; 129 - dev = alloc_ei_netdev(); 129 + dev = ____alloc_ei_netdev(0); 130 130 if (!dev) 131 131 return -ENOMEM; 132 132 if (!request_mem_region(ioaddr, NE_IO_EXTENT*2, DRV_NAME)) { ··· 146 146 static const struct net_device_ops zorro8390_netdev_ops = { 147 147 .ndo_open = zorro8390_open, 148 148 .ndo_stop = zorro8390_close, 149 - .ndo_start_xmit = ei_start_xmit, 150 - .ndo_tx_timeout = ei_tx_timeout, 151 - .ndo_get_stats = ei_get_stats, 152 - .ndo_set_multicast_list = ei_set_multicast_list, 149 + .ndo_start_xmit = __ei_start_xmit, 150 + .ndo_tx_timeout = __ei_tx_timeout, 151 + .ndo_get_stats = __ei_get_stats, 152 + .ndo_set_multicast_list = __ei_set_multicast_list, 153 153 .ndo_validate_addr = eth_validate_addr, 154 154 .ndo_set_mac_address = eth_mac_addr, 155 155 .ndo_change_mtu = eth_change_mtu, 156 156 #ifdef CONFIG_NET_POLL_CONTROLLER 157 - .ndo_poll_controller = ei_poll, 157 + .ndo_poll_controller = __ei_poll, 158 158 #endif 159 159 }; 160 160