Lines Matching refs:mb
320 volatile struct mace __iomem *mb = mp->mace; in mace_reset() local
326 out_8(&mb->biucc, SWRST); in mace_reset()
327 if (in_8(&mb->biucc) & SWRST) { in mace_reset()
338 out_8(&mb->imr, 0xff); /* disable all intrs for now */ in mace_reset()
339 i = in_8(&mb->ir); in mace_reset()
340 out_8(&mb->maccc, 0); /* turn off tx, rx */ in mace_reset()
342 out_8(&mb->biucc, XMTSP_64); in mace_reset()
343 out_8(&mb->utr, RTRD); in mace_reset()
344 out_8(&mb->fifocc, RCVFW_32 | XMTFW_16 | XMTFWU | RCVFWU | XMTBRST); in mace_reset()
345 out_8(&mb->xmtfc, AUTO_PAD_XMIT); /* auto-pad short frames */ in mace_reset()
346 out_8(&mb->rcvfc, 0); in mace_reset()
353 out_8(&mb->iac, LOGADDR); in mace_reset()
355 out_8(&mb->iac, ADDRCHG | LOGADDR); in mace_reset()
356 while ((in_8(&mb->iac) & ADDRCHG) != 0) in mace_reset()
360 out_8(&mb->ladrf, 0); in mace_reset()
364 out_8(&mb->iac, 0); in mace_reset()
367 out_8(&mb->plscc, PORTSEL_AUI + ENPLSIO); in mace_reset()
369 out_8(&mb->plscc, PORTSEL_GPSI + ENPLSIO); in mace_reset()
375 volatile struct mace __iomem *mb = mp->mace; in __mace_set_address() local
381 out_8(&mb->iac, PHYADDR); in __mace_set_address()
383 out_8(&mb->iac, ADDRCHG | PHYADDR); in __mace_set_address()
384 while ((in_8(&mb->iac) & ADDRCHG) != 0) in __mace_set_address()
388 out_8(&mb->padr, dev->dev_addr[i] = p[i]); in __mace_set_address()
390 out_8(&mb->iac, 0); in __mace_set_address()
396 volatile struct mace __iomem *mb = mp->mace; in mace_set_address() local
404 out_8(&mb->maccc, mp->maccc); in mace_set_address()
431 volatile struct mace __iomem *mb = mp->mace; in mace_open() local
491 out_8(&mb->maccc, mp->maccc); in mace_open()
493 out_8(&mb->imr, RCVINT); in mace_open()
501 volatile struct mace __iomem *mb = mp->mace; in mace_close() local
506 out_8(&mb->maccc, 0); in mace_close()
507 out_8(&mb->imr, 0xff); /* disable all intrs */ in mace_close()
587 volatile struct mace __iomem *mb = mp->mace; in mace_set_multicast() local
620 out_8(&mb->iac, LOGADDR); in mace_set_multicast()
622 out_8(&mb->iac, ADDRCHG | LOGADDR); in mace_set_multicast()
623 while ((in_8(&mb->iac) & ADDRCHG) != 0) in mace_set_multicast()
627 out_8(&mb->ladrf, multicast_filter[i]); in mace_set_multicast()
629 out_8(&mb->iac, 0); in mace_set_multicast()
632 out_8(&mb->maccc, mp->maccc); in mace_set_multicast()
638 volatile struct mace __iomem *mb = mp->mace; in mace_handle_misc_intrs() local
643 dev->stats.rx_missed_errors += in_8(&mb->mpc); /* reading clears it */ in mace_handle_misc_intrs()
646 dev->stats.rx_length_errors += in_8(&mb->rntpc); /* reading clears it */ in mace_handle_misc_intrs()
661 volatile struct mace __iomem *mb = mp->mace; in mace_interrupt() local
670 intr = in_8(&mb->ir); /* read interrupt register */ in mace_interrupt()
671 in_8(&mb->xmtrc); /* get retries */ in mace_interrupt()
675 while (in_8(&mb->pr) & XMTSV) { in mace_interrupt()
683 intr = in_8(&mb->ir); in mace_interrupt()
687 fs = in_8(&mb->xmtfs); in mace_interrupt()
689 out_8(&mb->xmtfc, AUTO_PAD_XMIT); in mace_interrupt()
699 xcount = (in_8(&mb->fifofc) >> XMTFC_SH) & XMTFC_MASK; in mace_interrupt()
712 out_8(&mb->xmtfc, DXMTFCS); in mace_interrupt()
714 fs = in_8(&mb->xmtfs); in mace_interrupt()
732 x = (in_8(&mb->fifofc) >> XMTFC_SH) & XMTFC_MASK; in mace_interrupt()
744 out_8(&mb->maccc, in_8(&mb->maccc) & ~ENXMT); in mace_interrupt()
745 out_8(&mb->fifocc, in_8(&mb->fifocc) | XMTFWU); in mace_interrupt()
747 out_8(&mb->maccc, in_8(&mb->maccc) | ENXMT); in mace_interrupt()
748 out_8(&mb->xmtfc, AUTO_PAD_XMIT); in mace_interrupt()
807 volatile struct mace __iomem *mb = mp->mace; in mace_tx_timeout() local
820 mace_handle_misc_intrs(mp, in_8(&mb->ir), dev); in mace_tx_timeout()
825 out_8(&mb->maccc, 0); in mace_tx_timeout()
862 out_8(&mb->imr, RCVINT); in mace_tx_timeout()
863 out_8(&mb->maccc, mp->maccc); in mace_tx_timeout()