Lines Matching +full:xcvr +full:- +full:setup

3     A PCMCIA ethernet driver for Asix AX88190-based cards
5 The Asix AX88190 is a NS8390-derived chipset with a few nasty
12 Copyright (C) 2001 David A. Hinds -- dahinds@users.sourceforge.net
52 #define AXNET_DATAPORT 0x10 /* NatSemi-defined port window offset. */
146 dev_dbg(&link->dev, "axnet_attach()\n"); in axnet_probe()
150 return -ENOMEM; in axnet_probe()
153 spin_lock_init(&ei_local->page_lock); in axnet_probe()
156 info->p_dev = link; in axnet_probe()
157 link->priv = dev; in axnet_probe()
158 link->config_flags |= CONF_ENABLE_IRQ; in axnet_probe()
160 dev->netdev_ops = &axnet_netdev_ops; in axnet_probe()
162 dev->watchdog_timeo = TX_TIMEOUT; in axnet_probe()
169 struct net_device *dev = link->priv; in axnet_detach()
171 dev_dbg(&link->dev, "axnet_detach(0x%p)\n", link); in axnet_detach()
188 struct net_device *dev = link->priv; in get_prom()
189 unsigned int ioaddr = dev->base_addr; in get_prom()
198 {0x01, EN0_DCFG}, /* Set word-wide access. */ in get_prom()
213 if (link->config_base != 0x03c0) in get_prom()
235 link->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in try_io_port()
236 link->resource[1]->flags &= ~IO_DATA_PATH_WIDTH; in try_io_port()
237 if (link->resource[0]->end == 32) { in try_io_port()
238 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; in try_io_port()
240 if (link->resource[1]->end > 0) in try_io_port()
241 link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8; in try_io_port()
243 /* This should be two 16-port windows */ in try_io_port()
244 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8; in try_io_port()
245 link->resource[1]->flags |= IO_DATA_PATH_WIDTH_16; in try_io_port()
247 if (link->resource[0]->start == 0) { in try_io_port()
249 link->resource[0]->start = j ^ 0x300; in try_io_port()
250 link->resource[1]->start = (j ^ 0x300) + 0x10; in try_io_port()
251 link->io_lines = 16; in try_io_port()
264 if (p_dev->config_index == 0) in axnet_configcheck()
265 return -EINVAL; in axnet_configcheck()
267 p_dev->config_index = 0x05; in axnet_configcheck()
268 if (p_dev->resource[0]->end + p_dev->resource[1]->end < 32) in axnet_configcheck()
269 return -ENODEV; in axnet_configcheck()
276 struct net_device *dev = link->priv; in axnet_config()
280 dev_dbg(&link->dev, "axnet_config(0x%p)\n", link); in axnet_config()
283 link->config_regs = 0x63; in axnet_config()
284 link->config_flags |= CONF_ENABLE_IRQ | CONF_AUTO_SET_IO; in axnet_config()
289 if (!link->irq) in axnet_config()
292 if (resource_size(link->resource[1]) == 8) in axnet_config()
293 link->config_flags |= CONF_ENABLE_SPKR; in axnet_config()
299 dev->irq = link->irq; in axnet_config()
300 dev->base_addr = link->resource[0]->start; in axnet_config()
318 if (inb(dev->base_addr + AXNET_TEST) != 0) in axnet_config()
319 info->flags |= IS_AX88790; in axnet_config()
321 info->flags |= IS_AX88190; in axnet_config()
323 if (info->flags & IS_AX88790) in axnet_config()
324 outb(0x10, dev->base_addr + AXNET_GPIO); /* select Internal PHY */ in axnet_config()
326 info->active_low = 0; in axnet_config()
329 j = mdio_read(dev->base_addr + AXNET_MII_EEP, i, 1); in axnet_config()
330 j2 = mdio_read(dev->base_addr + AXNET_MII_EEP, i, 2); in axnet_config()
340 j = mdio_read(dev->base_addr + AXNET_MII_EEP, i, 1); in axnet_config()
341 j2 = mdio_read(dev->base_addr + AXNET_MII_EEP, i, 2); in axnet_config()
344 info->active_low = 1; in axnet_config()
350 info->phy_id = (i < 32) ? i : -1; in axnet_config()
351 SET_NETDEV_DEV(dev, &link->dev); in axnet_config()
359 ((info->flags & IS_AX88790) ? 7 : 1), in axnet_config()
360 dev->base_addr, dev->irq, dev->dev_addr); in axnet_config()
361 if (info->phy_id != -1) { in axnet_config()
363 info->phy_id, j); in axnet_config()
371 return -ENODEV; in axnet_config()
381 struct net_device *dev = link->priv; in axnet_suspend()
383 if (link->open) in axnet_suspend()
391 struct net_device *dev = link->priv; in axnet_resume()
394 if (link->open) { in axnet_resume()
395 if (info->active_low == 1) in axnet_resume()
435 for (i = 14; i >= 0; i--) { in mdio_read()
440 for (i = 19; i > 0; i--) { in mdio_read()
454 for (i = 31; i >= 0; i--) { in mdio_write()
459 for (i = 1; i >= 0; i--) { in mdio_write()
471 struct pcmcia_device *link = info->p_dev; in axnet_open()
472 unsigned int nic_base = dev->base_addr; in axnet_open()
474 dev_dbg(&link->dev, "axnet_open('%s')\n", dev->name); in axnet_open()
477 return -ENODEV; in axnet_open()
480 ret = request_irq(dev->irq, ei_irq_wrapper, IRQF_SHARED, "axnet_cs", dev); in axnet_open()
484 link->open++; in axnet_open()
486 info->link_status = 0x00; in axnet_open()
487 timer_setup(&info->watchdog, ei_watchdog, 0); in axnet_open()
488 mod_timer(&info->watchdog, jiffies + HZ); in axnet_open()
498 struct pcmcia_device *link = info->p_dev; in axnet_close()
500 dev_dbg(&link->dev, "axnet_close('%s')\n", dev->name); in axnet_close()
503 free_irq(dev->irq, dev); in axnet_close()
505 link->open--; in axnet_close()
507 del_timer_sync(&info->watchdog); in axnet_close()
521 unsigned int nic_base = dev->base_addr; in axnet_reset_8390()
547 PRIV(dev)->stale = 0; in ei_irq_wrapper()
554 struct net_device *dev = info->p_dev->priv; in ei_watchdog()
555 unsigned int nic_base = dev->base_addr; in ei_watchdog()
563 if (info->stale++ && (inb_p(nic_base + EN0_ISR) & ENISR_ALL)) { in ei_watchdog()
564 if (!info->fast_poll) in ei_watchdog()
566 ei_irq_wrapper(dev->irq, dev); in ei_watchdog()
567 info->fast_poll = HZ; in ei_watchdog()
569 if (info->fast_poll) { in ei_watchdog()
570 info->fast_poll--; in ei_watchdog()
571 info->watchdog.expires = jiffies + 1; in ei_watchdog()
572 add_timer(&info->watchdog); in ei_watchdog()
576 if (info->phy_id < 0) in ei_watchdog()
578 link = mdio_read(mii_addr, info->phy_id, 1); in ei_watchdog()
581 info->phy_id = -1; in ei_watchdog()
586 if (link != info->link_status) { in ei_watchdog()
587 u_short p = mdio_read(mii_addr, info->phy_id, 5); in ei_watchdog()
590 info->duplex_flag = (p & 0x0140) ? 0x80 : 0x00; in ei_watchdog()
592 netdev_info(dev, "autonegotiation complete: %dbaseT-%cD selected\n", in ei_watchdog()
598 info->link_status = link; in ei_watchdog()
602 info->watchdog.expires = jiffies + HZ; in ei_watchdog()
603 add_timer(&info->watchdog); in ei_watchdog()
612 unsigned int mii_addr = dev->base_addr + AXNET_MII_EEP; in axnet_ioctl()
615 data->phy_id = info->phy_id; in axnet_ioctl()
618 data->val_out = mdio_read(mii_addr, data->phy_id, data->reg_num & 0x1f); in axnet_ioctl()
621 mdio_write(mii_addr, data->phy_id, data->reg_num & 0x1f, data->val_in); in axnet_ioctl()
624 return -EOPNOTSUPP; in axnet_ioctl()
633 unsigned int nic_base = dev->base_addr; in get_8390_hdr()
642 hdr->count = le16_to_cpu(hdr->count); in get_8390_hdr()
651 unsigned int nic_base = dev->base_addr; in block_input()
654 char *buf = skb->data; in block_input()
664 buf[count-1] = inb(nic_base + AXNET_DATAPORT); in block_input()
675 unsigned int nic_base = dev->base_addr; in block_output()
677 pr_debug("%s: [bo=%d]\n", dev->name, count); in block_output()
703 …PCMCIA_DEVICE_PROD_ID124("Fast Ethernet", "16-bit PC Card", "AX88190", 0xb4be14e3, 0x9a12eb6a, 0xa…
705 PCMCIA_DEVICE_PROD_ID12("Billionton", "LNA-100B", 0x552ab682, 0xbc3b87e1),
708 PCMCIA_DEVICE_PROD_ID12("corega K.K.", "corega FEther PCC-TXD", 0x5261440f, 0x436768c5),
709 PCMCIA_DEVICE_PROD_ID12("corega K.K.", "corega FEtherII PCC-TXD", 0x5261440f, 0x730df72e),
710 PCMCIA_DEVICE_PROD_ID12("corega K.K.", "corega FEther PCC-TXM", 0x5261440f, 0x3abbd061),
714 PCMCIA_DEVICE_PROD_ID12("MELCO", "LPC3-TX", 0x481e0094, 0xf91af609),
739 Written 1992-94 by Donald Becker.
752 This is the chip-specific code for many 8390-based ethernet adaptors.
753 This is not a complete driver, it must be combined with board-specific
759 you have found something that needs changing. -- PG
774 Paul Gortmaker : add kmod support for auto-loading of the 8390
792 /* These are the operational function interfaces to board-specific
801 "page" value uses the 8390's 256-byte pages.
810 #define ei_reset_8390 (ei_local->reset_8390)
811 #define ei_block_output (ei_local->block_output)
812 #define ei_block_input (ei_local->block_input)
813 #define ei_get_8390_hdr (ei_local->get_8390_hdr)
821 /* Routines generic to NS8390-based boards. */
827 * SMP and the 8390 setup.
831 * this with ei_local->page_lock. Nobody should assume or set the page other
853 * ax_open - Open/initialize the board.
856 * This routine goes all-out, setting everything
870 spin_lock_irqsave(&ei_local->page_lock, flags); in ax_open()
875 spin_unlock_irqrestore(&ei_local->page_lock, flags); in ax_open()
876 ei_local->irqlock = 0; in ax_open()
880 #define dev_lock(dev) (((struct ei_device *)netdev_priv(dev))->page_lock)
883 * ax_close - shut down network device
904 * axnet_tx_timeout - handle transmit time out condition
909 * completed (or failed) - i.e. never posted a Tx related interrupt.
914 long e8390_base = dev->base_addr; in axnet_tx_timeout()
916 int txsr, isr, tickssofar = jiffies - dev_trans_start(dev); in axnet_tx_timeout()
919 dev->stats.tx_errors++; in axnet_tx_timeout()
921 spin_lock_irqsave(&ei_local->page_lock, flags); in axnet_tx_timeout()
924 spin_unlock_irqrestore(&ei_local->page_lock, flags); in axnet_tx_timeout()
931 if (!isr && !dev->stats.tx_packets) in axnet_tx_timeout()
934 ei_local->interface_num ^= 1; /* Try a different xcvr. */ in axnet_tx_timeout()
939 spin_lock_irqsave(&ei_local->page_lock, flags); in axnet_tx_timeout()
945 spin_unlock_irqrestore(&ei_local->page_lock, flags); in axnet_tx_timeout()
950 * axnet_start_xmit - begin packet transmission
960 long e8390_base = dev->base_addr; in axnet_start_xmit()
968 length = skb->len; in axnet_start_xmit()
975 spin_lock_irqsave(&ei_local->page_lock, flags); in axnet_start_xmit()
982 ei_local->irqlock = 1; in axnet_start_xmit()
989 * you get very close to transmitting back-to-back packets. With in axnet_start_xmit()
994 if (ei_local->tx1 == 0) in axnet_start_xmit()
996 output_page = ei_local->tx_start_page; in axnet_start_xmit()
997 ei_local->tx1 = send_length; in axnet_start_xmit()
999 ei_local->tx2 > 0) in axnet_start_xmit()
1002 ei_local->tx2, ei_local->lasttx, in axnet_start_xmit()
1003 ei_local->txing); in axnet_start_xmit()
1005 else if (ei_local->tx2 == 0) in axnet_start_xmit()
1007 output_page = ei_local->tx_start_page + TX_PAGES/2; in axnet_start_xmit()
1008 ei_local->tx2 = send_length; in axnet_start_xmit()
1010 ei_local->tx1 > 0) in axnet_start_xmit()
1013 ei_local->tx1, ei_local->lasttx, in axnet_start_xmit()
1014 ei_local->txing); in axnet_start_xmit()
1020 ei_local->tx1, ei_local->tx2, in axnet_start_xmit()
1021 ei_local->lasttx); in axnet_start_xmit()
1022 ei_local->irqlock = 0; in axnet_start_xmit()
1025 spin_unlock_irqrestore(&ei_local->page_lock, flags); in axnet_start_xmit()
1026 dev->stats.tx_errors++; in axnet_start_xmit()
1036 if (length == skb->len) in axnet_start_xmit()
1037 ei_block_output(dev, length, skb->data, output_page); in axnet_start_xmit()
1040 skb_copy_from_linear_data(skb, packet, skb->len); in axnet_start_xmit()
1044 if (! ei_local->txing) in axnet_start_xmit()
1046 ei_local->txing = 1; in axnet_start_xmit()
1049 if (output_page == ei_local->tx_start_page) in axnet_start_xmit()
1051 ei_local->tx1 = -1; in axnet_start_xmit()
1052 ei_local->lasttx = -1; in axnet_start_xmit()
1056 ei_local->tx2 = -1; in axnet_start_xmit()
1057 ei_local->lasttx = -2; in axnet_start_xmit()
1060 else ei_local->txqueue++; in axnet_start_xmit()
1062 if (ei_local->tx1 && ei_local->tx2) in axnet_start_xmit()
1068 ei_local->irqlock = 0; in axnet_start_xmit()
1071 spin_unlock_irqrestore(&ei_local->page_lock, flags); in axnet_start_xmit()
1074 dev->stats.tx_bytes += send_length; in axnet_start_xmit()
1080 * ax_interrupt - handle the interrupts from an 8390
1100 e8390_base = dev->base_addr; in ax_interrupt()
1107 spin_lock_irqsave(&ei_local->page_lock, flags); in ax_interrupt()
1109 if (ei_local->irqlock) { in ax_interrupt()
1113 if (ei_local->irqlock) in ax_interrupt()
1122 spin_unlock_irqrestore(&ei_local->page_lock, flags); in ax_interrupt()
1130 ei_local->irqlock = 1; in ax_interrupt()
1132 /* !!Assumption!! -- we stay in page 0. Don't break this. */ in ax_interrupt()
1160 /* Push the next to-transmit packet through. */ in ax_interrupt()
1168 dev->stats.rx_frame_errors += inb_p(e8390_base + EN0_COUNTER0); in ax_interrupt()
1169 dev->stats.rx_crc_errors += inb_p(e8390_base + EN0_COUNTER1); in ax_interrupt()
1170 dev->stats.rx_missed_errors+= inb_p(e8390_base + EN0_COUNTER2); in ax_interrupt()
1193 ei_local->irqlock = 0; in ax_interrupt()
1196 spin_unlock_irqrestore(&ei_local->page_lock, flags); in ax_interrupt()
1201 * ei_tx_err - handle transmitter error
1216 long e8390_base = dev->base_addr; in ei_tx_err()
1223 pr_cont(" excess-collisions"); in ei_tx_err()
1225 pr_cont(" non-deferral"); in ei_tx_err()
1227 pr_cont(" lost-carrier"); in ei_tx_err()
1229 pr_cont(" FIFO-underrun"); in ei_tx_err()
1231 pr_cont(" lost-heartbeat"); in ei_tx_err()
1239 dev->stats.tx_errors++; in ei_tx_err()
1240 if (txsr & ENTSR_CRS) dev->stats.tx_carrier_errors++; in ei_tx_err()
1241 if (txsr & ENTSR_CDH) dev->stats.tx_heartbeat_errors++; in ei_tx_err()
1242 if (txsr & ENTSR_OWC) dev->stats.tx_window_errors++; in ei_tx_err()
1247 * ei_tx_intr - transmit interrupt handler
1256 long e8390_base = dev->base_addr; in ei_tx_intr()
1264 ei_local->txqueue--; in ei_tx_intr()
1266 if (ei_local->tx1 < 0) in ei_tx_intr()
1268 if (ei_local->lasttx != 1 && ei_local->lasttx != -1) in ei_tx_intr()
1270 ei_local->name, ei_local->lasttx, in ei_tx_intr()
1271 ei_local->tx1); in ei_tx_intr()
1272 ei_local->tx1 = 0; in ei_tx_intr()
1273 if (ei_local->tx2 > 0) in ei_tx_intr()
1275 ei_local->txing = 1; in ei_tx_intr()
1276 NS8390_trigger_send(dev, ei_local->tx2, ei_local->tx_start_page + 6); in ei_tx_intr()
1278 ei_local->tx2 = -1; in ei_tx_intr()
1279 ei_local->lasttx = 2; in ei_tx_intr()
1281 ei_local->lasttx = 20; in ei_tx_intr()
1282 ei_local->txing = 0; in ei_tx_intr()
1285 else if (ei_local->tx2 < 0) in ei_tx_intr()
1287 if (ei_local->lasttx != 2 && ei_local->lasttx != -2) in ei_tx_intr()
1289 ei_local->name, ei_local->lasttx, in ei_tx_intr()
1290 ei_local->tx2); in ei_tx_intr()
1291 ei_local->tx2 = 0; in ei_tx_intr()
1292 if (ei_local->tx1 > 0) in ei_tx_intr()
1294 ei_local->txing = 1; in ei_tx_intr()
1295 NS8390_trigger_send(dev, ei_local->tx1, ei_local->tx_start_page); in ei_tx_intr()
1297 ei_local->tx1 = -1; in ei_tx_intr()
1298 ei_local->lasttx = 1; in ei_tx_intr()
1300 ei_local->lasttx = 10; in ei_tx_intr()
1301 ei_local->txing = 0; in ei_tx_intr()
1305 // netdev_warn(dev, "unexpected TX-done interrupt, lasttx=%d\n", in ei_tx_intr()
1306 // ei_local->lasttx); in ei_tx_intr()
1310 dev->stats.collisions++; in ei_tx_intr()
1312 dev->stats.tx_packets++; in ei_tx_intr()
1315 dev->stats.tx_errors++; in ei_tx_intr()
1318 dev->stats.tx_aborted_errors++; in ei_tx_intr()
1319 dev->stats.collisions += 16; in ei_tx_intr()
1322 dev->stats.tx_carrier_errors++; in ei_tx_intr()
1324 dev->stats.tx_fifo_errors++; in ei_tx_intr()
1326 dev->stats.tx_heartbeat_errors++; in ei_tx_intr()
1328 dev->stats.tx_window_errors++; in ei_tx_intr()
1334 * ei_receive - receive some packets
1343 long e8390_base = dev->base_addr; in ei_receive()
1355 rxing_page = inb_p(e8390_base + EN1_CURPAG -1); in ei_receive()
1359 if (this_frame >= ei_local->stop_page) in ei_receive()
1360 this_frame = ei_local->rx_start_page; in ei_receive()
1369 this_frame != ei_local->current_page && in ei_receive()
1372 this_frame, ei_local->current_page); in ei_receive()
1380 pkt_len = rx_frame.count - sizeof(struct e8390_pkt_hdr); in ei_receive()
1391 dev->stats.rx_errors++; in ei_receive()
1392 dev->stats.rx_length_errors++; in ei_receive()
1404 dev->stats.rx_dropped++; in ei_receive()
1412 skb->protocol=eth_type_trans(skb,dev); in ei_receive()
1414 dev->stats.rx_packets++; in ei_receive()
1415 dev->stats.rx_bytes += pkt_len; in ei_receive()
1417 dev->stats.multicast++; in ei_receive()
1426 dev->stats.rx_errors++; in ei_receive()
1429 dev->stats.rx_fifo_errors++; in ei_receive()
1434 if (next_frame >= ei_local->stop_page) { in ei_receive()
1437 next_frame = ei_local->rx_start_page; in ei_receive()
1439 ei_local->current_page = next_frame; in ei_receive()
1440 outb_p(next_frame-1, e8390_base+EN0_BOUNDARY); in ei_receive()
1445 * ei_rx_overrun - handle receiver overrun
1454 * computer will hate you - it takes 10ms or so.
1460 long e8390_base = dev->base_addr; in ei_rx_overrun()
1472 dev->stats.rx_over_errors++; in ei_rx_overrun()
1514 outb_p(E8390_TXCONFIG | info->duplex_flag, e8390_base + EN0_TXCR); in ei_rx_overrun()
1525 long ioaddr = dev->base_addr; in get_stats()
1531 return &dev->stats; in get_stats()
1533 spin_lock_irqsave(&ei_local->page_lock,flags); in get_stats()
1535 dev->stats.rx_frame_errors += inb_p(ioaddr + EN0_COUNTER0); in get_stats()
1536 dev->stats.rx_crc_errors += inb_p(ioaddr + EN0_COUNTER1); in get_stats()
1537 dev->stats.rx_missed_errors+= inb_p(ioaddr + EN0_COUNTER2); in get_stats()
1538 spin_unlock_irqrestore(&ei_local->page_lock, flags); in get_stats()
1540 return &dev->stats; in get_stats()
1554 crc = ether_crc(ETH_ALEN, ha->addr); in make_mc_bits()
1564 * do_set_multicast_list - set/clear multicast filter
1573 long e8390_base = dev->base_addr; in do_set_multicast_list()
1577 if (!(dev->flags&(IFF_PROMISC|IFF_ALLMULTI))) { in do_set_multicast_list()
1578 memset(ei_local->mcfilter, 0, 8); in do_set_multicast_list()
1580 make_mc_bits(ei_local->mcfilter, dev); in do_set_multicast_list()
1582 /* set to accept-all */ in do_set_multicast_list()
1583 memset(ei_local->mcfilter, 0xFF, 8); in do_set_multicast_list()
1589 outb_p(ei_local->mcfilter[i], e8390_base + EN1_MULT_SHIFT(i)); in do_set_multicast_list()
1593 if(dev->flags&IFF_PROMISC) in do_set_multicast_list()
1595 else if (dev->flags & IFF_ALLMULTI || !netdev_mc_empty(dev)) in do_set_multicast_list()
1622 * AX88190_init - initialize 8390 hardware
1624 * @startp: boolean. non-zero value to initiate chip processing
1632 long e8390_base = dev->base_addr; in AX88190_init()
1635 int endcfg = ei_local->word16 ? (0x48 | ENDCFG_WTS) : 0x48; in AX88190_init()
1645 /* Set to monitor and loopback mode -- this is vital!. */ in AX88190_init()
1649 outb_p(ei_local->tx_start_page, e8390_base + EN0_TPSR); in AX88190_init()
1650 ei_local->tx1 = ei_local->tx2 = 0; in AX88190_init()
1651 outb_p(ei_local->rx_start_page, e8390_base + EN0_STARTPG); in AX88190_init()
1652 outb_p(ei_local->stop_page-1, e8390_base + EN0_BOUNDARY); /* 3c503 says 0x3f,NS0x26*/ in AX88190_init()
1653 ei_local->current_page = ei_local->rx_start_page; /* assert boundary+1 */ in AX88190_init()
1654 outb_p(ei_local->stop_page, e8390_base + EN0_STOPPG); in AX88190_init()
1664 outb_p(dev->dev_addr[i], e8390_base + EN1_PHYS_SHIFT(i)); in AX88190_init()
1665 if(inb_p(e8390_base + EN1_PHYS_SHIFT(i))!=dev->dev_addr[i]) in AX88190_init()
1669 outb_p(ei_local->rx_start_page, e8390_base + EN1_CURPAG); in AX88190_init()
1673 ei_local->tx1 = ei_local->tx2 = 0; in AX88190_init()
1674 ei_local->txing = 0; in AX88190_init()
1676 if (info->flags & IS_AX88790) /* select Internal PHY */ in AX88190_init()
1684 outb_p(E8390_TXCONFIG | info->duplex_flag, in AX88190_init()
1698 long e8390_base = dev->base_addr; in NS8390_trigger_send()