require '_h2ph_pre.ph';

unless(defined(&RL_IDR0)) {
    sub RL_IDR0 () {	0x0000;}
}
unless(defined(&RL_IDR1)) {
    sub RL_IDR1 () {	0x0001;}
}
unless(defined(&RL_IDR2)) {
    sub RL_IDR2 () {	0x0002;}
}
unless(defined(&RL_IDR3)) {
    sub RL_IDR3 () {	0x0003;}
}
unless(defined(&RL_IDR4)) {
    sub RL_IDR4 () {	0x0004;}
}
unless(defined(&RL_IDR5)) {
    sub RL_IDR5 () {	0x0005;}
}
unless(defined(&RL_MAR0)) {
    sub RL_MAR0 () {	0x0008;}
}
unless(defined(&RL_MAR1)) {
    sub RL_MAR1 () {	0x0009;}
}
unless(defined(&RL_MAR2)) {
    sub RL_MAR2 () {	0x000a;}
}
unless(defined(&RL_MAR3)) {
    sub RL_MAR3 () {	0x000b;}
}
unless(defined(&RL_MAR4)) {
    sub RL_MAR4 () {	0x000c;}
}
unless(defined(&RL_MAR5)) {
    sub RL_MAR5 () {	0x000d;}
}
unless(defined(&RL_MAR6)) {
    sub RL_MAR6 () {	0x000e;}
}
unless(defined(&RL_MAR7)) {
    sub RL_MAR7 () {	0x000f;}
}
unless(defined(&RL_TXSTAT0)) {
    sub RL_TXSTAT0 () {	0x0010;}
}
unless(defined(&RL_TXSTAT1)) {
    sub RL_TXSTAT1 () {	0x0014;}
}
unless(defined(&RL_TXSTAT2)) {
    sub RL_TXSTAT2 () {	0x0018;}
}
unless(defined(&RL_TXSTAT3)) {
    sub RL_TXSTAT3 () {	0x001c;}
}
unless(defined(&RL_TXADDR0)) {
    sub RL_TXADDR0 () {	0x0020;}
}
unless(defined(&RL_TXADDR1)) {
    sub RL_TXADDR1 () {	0x0024;}
}
unless(defined(&RL_TXADDR2)) {
    sub RL_TXADDR2 () {	0x0028;}
}
unless(defined(&RL_TXADDR3)) {
    sub RL_TXADDR3 () {	0x002c;}
}
unless(defined(&RL_RXADDR)) {
    sub RL_RXADDR () {	0x0030;}
}
unless(defined(&RL_RX_EARLY_BYTES)) {
    sub RL_RX_EARLY_BYTES () {	0x0034;}
}
unless(defined(&RL_RX_EARLY_STAT)) {
    sub RL_RX_EARLY_STAT () {	0x0036;}
}
unless(defined(&RL_COMMAND)) {
    sub RL_COMMAND () {	0x0037;}
}
unless(defined(&RL_CURRXADDR)) {
    sub RL_CURRXADDR () {	0x0038;}
}
unless(defined(&RL_CURRXBUF)) {
    sub RL_CURRXBUF () {	0x003a;}
}
unless(defined(&RL_IMR)) {
    sub RL_IMR () {	0x003c;}
}
unless(defined(&RL_ISR)) {
    sub RL_ISR () {	0x003e;}
}
unless(defined(&RL_TXCFG)) {
    sub RL_TXCFG () {	0x0040;}
}
unless(defined(&RL_RXCFG)) {
    sub RL_RXCFG () {	0x0044;}
}
unless(defined(&RL_TIMERCNT)) {
    sub RL_TIMERCNT () {	0x0048;}
}
unless(defined(&RL_MISSEDPKT)) {
    sub RL_MISSEDPKT () {	0x004c;}
}
unless(defined(&RL_EECMD)) {
    sub RL_EECMD () {	0x0050;}
}
unless(defined(&RL_CFG0)) {
    sub RL_CFG0 () {	0x0051;}
}
unless(defined(&RL_CFG1)) {
    sub RL_CFG1 () {	0x0052;}
}
unless(defined(&RL_MEDIASTAT)) {
    sub RL_MEDIASTAT () {	0x0058;}
}
unless(defined(&RL_MII)) {
    sub RL_MII () {	0x005a;}
}
unless(defined(&RL_HALTCLK)) {
    sub RL_HALTCLK () {	0x005b;}
}
unless(defined(&RL_MULTIINTR)) {
    sub RL_MULTIINTR () {	0x005c;}
}
unless(defined(&RL_PCIREV)) {
    sub RL_PCIREV () {	0x005e;}
}
unless(defined(&RL_TXSTAT_ALL)) {
    sub RL_TXSTAT_ALL () {	0x0060;}
}
unless(defined(&RL_BMCR)) {
    sub RL_BMCR () {	0x0062;}
}
unless(defined(&RL_BMSR)) {
    sub RL_BMSR () {	0x0064;}
}
unless(defined(&RL_ANAR)) {
    sub RL_ANAR () {	0x0066;}
}
unless(defined(&RL_LPAR)) {
    sub RL_LPAR () {	0x0068;}
}
unless(defined(&RL_ANER)) {
    sub RL_ANER () {	0x006a;}
}
unless(defined(&RL_DISCCNT)) {
    sub RL_DISCCNT () {	0x006c;}
}
unless(defined(&RL_FALSECAR)) {
    sub RL_FALSECAR () {	0x006e;}
}
unless(defined(&RL_NWAYTST)) {
    sub RL_NWAYTST () {	0x0070;}
}
unless(defined(&RL_RX_ER)) {
    sub RL_RX_ER () {	0x0072;}
}
unless(defined(&RL_CSCFG)) {
    sub RL_CSCFG () {	0x0074;}
}
unless(defined(&RL_TXCFG_CLRABRT)) {
    sub RL_TXCFG_CLRABRT () {	0x00000001;}
}
unless(defined(&RL_TXCFG_MAXDMA)) {
    sub RL_TXCFG_MAXDMA () {	0x00000700;}
}
unless(defined(&RL_TXCFG_CRCAPPEND)) {
    sub RL_TXCFG_CRCAPPEND () {	0x00010000;}
}
unless(defined(&RL_TXCFG_LOOPBKTST)) {
    sub RL_TXCFG_LOOPBKTST () {	0x00060000;}
}
unless(defined(&RL_TXCFG_IFG)) {
    sub RL_TXCFG_IFG () {	0x03000000;}
}
unless(defined(&RL_TXDMA_16BYTES)) {
    sub RL_TXDMA_16BYTES () {	0x00000000;}
}
unless(defined(&RL_TXDMA_32BYTES)) {
    sub RL_TXDMA_32BYTES () {	0x00000100;}
}
unless(defined(&RL_TXDMA_64BYTES)) {
    sub RL_TXDMA_64BYTES () {	0x00000200;}
}
unless(defined(&RL_TXDMA_128BYTES)) {
    sub RL_TXDMA_128BYTES () {	0x00000300;}
}
unless(defined(&RL_TXDMA_256BYTES)) {
    sub RL_TXDMA_256BYTES () {	0x00000400;}
}
unless(defined(&RL_TXDMA_512BYTES)) {
    sub RL_TXDMA_512BYTES () {	0x00000500;}
}
unless(defined(&RL_TXDMA_1024BYTES)) {
    sub RL_TXDMA_1024BYTES () {	0x00000600;}
}
unless(defined(&RL_TXDMA_2048BYTES)) {
    sub RL_TXDMA_2048BYTES () {	0x00000700;}
}
unless(defined(&RL_TXSTAT_LENMASK)) {
    sub RL_TXSTAT_LENMASK () {	0x00001fff;}
}
unless(defined(&RL_TXSTAT_OWN)) {
    sub RL_TXSTAT_OWN () {	0x00002000;}
}
unless(defined(&RL_TXSTAT_TX_UNDERRUN)) {
    sub RL_TXSTAT_TX_UNDERRUN () {	0x00004000;}
}
unless(defined(&RL_TXSTAT_TX_OK)) {
    sub RL_TXSTAT_TX_OK () {	0x00008000;}
}
unless(defined(&RL_TXSTAT_EARLY_THRESH)) {
    sub RL_TXSTAT_EARLY_THRESH () {	0x003f0000;}
}
unless(defined(&RL_TXSTAT_COLLCNT)) {
    sub RL_TXSTAT_COLLCNT () {	0x0f000000;}
}
unless(defined(&RL_TXSTAT_CARR_HBEAT)) {
    sub RL_TXSTAT_CARR_HBEAT () {	0x10000000;}
}
unless(defined(&RL_TXSTAT_OUTOFWIN)) {
    sub RL_TXSTAT_OUTOFWIN () {	0x20000000;}
}
unless(defined(&RL_TXSTAT_TXABRT)) {
    sub RL_TXSTAT_TXABRT () {	0x40000000;}
}
unless(defined(&RL_TXSTAT_CARRLOSS)) {
    sub RL_TXSTAT_CARRLOSS () {	0x80000000;}
}
unless(defined(&RL_ISR_RX_OK)) {
    sub RL_ISR_RX_OK () {	0x0001;}
}
unless(defined(&RL_ISR_RX_ERR)) {
    sub RL_ISR_RX_ERR () {	0x0002;}
}
unless(defined(&RL_ISR_TX_OK)) {
    sub RL_ISR_TX_OK () {	0x0004;}
}
unless(defined(&RL_ISR_TX_ERR)) {
    sub RL_ISR_TX_ERR () {	0x0008;}
}
unless(defined(&RL_ISR_RX_OVERRUN)) {
    sub RL_ISR_RX_OVERRUN () {	0x0010;}
}
unless(defined(&RL_ISR_PKT_UNDERRUN)) {
    sub RL_ISR_PKT_UNDERRUN () {	0x0020;}
}
unless(defined(&RL_ISR_FIFO_OFLOW)) {
    sub RL_ISR_FIFO_OFLOW () {	0x0040;}
}
unless(defined(&RL_ISR_PCS_TIMEOUT)) {
    sub RL_ISR_PCS_TIMEOUT () {	0x4000;}
}
unless(defined(&RL_ISR_SYSTEM_ERR)) {
    sub RL_ISR_SYSTEM_ERR () {	0x8000;}
}
unless(defined(&RL_INTRS)) {
    sub RL_INTRS () {	( &RL_ISR_TX_OK| &RL_ISR_RX_OK| &RL_ISR_RX_ERR| &RL_ISR_TX_ERR|  &RL_ISR_RX_OVERRUN| &RL_ISR_PKT_UNDERRUN| &RL_ISR_FIFO_OFLOW|  &RL_ISR_PCS_TIMEOUT| &RL_ISR_SYSTEM_ERR);}
}
unless(defined(&RL_MEDIASTAT_RXPAUSE)) {
    sub RL_MEDIASTAT_RXPAUSE () {	0x01;}
}
unless(defined(&RL_MEDIASTAT_TXPAUSE)) {
    sub RL_MEDIASTAT_TXPAUSE () {	0x02;}
}
unless(defined(&RL_MEDIASTAT_LINK)) {
    sub RL_MEDIASTAT_LINK () {	0x04;}
}
unless(defined(&RL_MEDIASTAT_SPEED10)) {
    sub RL_MEDIASTAT_SPEED10 () {	0x08;}
}
unless(defined(&RL_MEDIASTAT_RXFLOWCTL)) {
    sub RL_MEDIASTAT_RXFLOWCTL () {	0x40;}
}
unless(defined(&RL_MEDIASTAT_TXFLOWCTL)) {
    sub RL_MEDIASTAT_TXFLOWCTL () {	0x80;}
}
unless(defined(&RL_RXCFG_RX_ALLPHYS)) {
    sub RL_RXCFG_RX_ALLPHYS () {	0x00000001;}
}
unless(defined(&RL_RXCFG_RX_INDIV)) {
    sub RL_RXCFG_RX_INDIV () {	0x00000002;}
}
unless(defined(&RL_RXCFG_RX_MULTI)) {
    sub RL_RXCFG_RX_MULTI () {	0x00000004;}
}
unless(defined(&RL_RXCFG_RX_BROAD)) {
    sub RL_RXCFG_RX_BROAD () {	0x00000008;}
}
unless(defined(&RL_RXCFG_RX_RUNT)) {
    sub RL_RXCFG_RX_RUNT () {	0x00000010;}
}
unless(defined(&RL_RXCFG_RX_ERRPKT)) {
    sub RL_RXCFG_RX_ERRPKT () {	0x00000020;}
}
unless(defined(&RL_RXCFG_WRAP)) {
    sub RL_RXCFG_WRAP () {	0x00000080;}
}
unless(defined(&RL_RXCFG_MAXDMA)) {
    sub RL_RXCFG_MAXDMA () {	0x00000700;}
}
unless(defined(&RL_RXCFG_BURSZ)) {
    sub RL_RXCFG_BURSZ () {	0x00001800;}
}
unless(defined(&RL_RXCFG_FIFOTHRESH)) {
    sub RL_RXCFG_FIFOTHRESH () {	0x0000e000;}
}
unless(defined(&RL_RXCFG_EARLYTHRESH)) {
    sub RL_RXCFG_EARLYTHRESH () {	0x07000000;}
}
unless(defined(&RL_RXDMA_16BYTES)) {
    sub RL_RXDMA_16BYTES () {	0x00000000;}
}
unless(defined(&RL_RXDMA_32BYTES)) {
    sub RL_RXDMA_32BYTES () {	0x00000100;}
}
unless(defined(&RL_RXDMA_64BYTES)) {
    sub RL_RXDMA_64BYTES () {	0x00000200;}
}
unless(defined(&RL_RXDMA_128BYTES)) {
    sub RL_RXDMA_128BYTES () {	0x00000300;}
}
unless(defined(&RL_RXDMA_256BYTES)) {
    sub RL_RXDMA_256BYTES () {	0x00000400;}
}
unless(defined(&RL_RXDMA_512BYTES)) {
    sub RL_RXDMA_512BYTES () {	0x00000500;}
}
unless(defined(&RL_RXDMA_1024BYTES)) {
    sub RL_RXDMA_1024BYTES () {	0x00000600;}
}
unless(defined(&RL_RXDMA_UNLIMITED)) {
    sub RL_RXDMA_UNLIMITED () {	0x00000700;}
}
unless(defined(&RL_RXBUF_8)) {
    sub RL_RXBUF_8 () {	0x00000000;}
}
unless(defined(&RL_RXBUF_16)) {
    sub RL_RXBUF_16 () {	0x00000800;}
}
unless(defined(&RL_RXBUF_32)) {
    sub RL_RXBUF_32 () {	0x00001000;}
}
unless(defined(&RL_RXBUF_64)) {
    sub RL_RXBUF_64 () {	0x00001800;}
}
unless(defined(&RL_RXFIFO_16BYTES)) {
    sub RL_RXFIFO_16BYTES () {	0x00000000;}
}
unless(defined(&RL_RXFIFO_32BYTES)) {
    sub RL_RXFIFO_32BYTES () {	0x00002000;}
}
unless(defined(&RL_RXFIFO_64BYTES)) {
    sub RL_RXFIFO_64BYTES () {	0x00004000;}
}
unless(defined(&RL_RXFIFO_128BYTES)) {
    sub RL_RXFIFO_128BYTES () {	0x00006000;}
}
unless(defined(&RL_RXFIFO_256BYTES)) {
    sub RL_RXFIFO_256BYTES () {	0x00008000;}
}
unless(defined(&RL_RXFIFO_512BYTES)) {
    sub RL_RXFIFO_512BYTES () {	0x0000a000;}
}
unless(defined(&RL_RXFIFO_1024BYTES)) {
    sub RL_RXFIFO_1024BYTES () {	0x0000c000;}
}
unless(defined(&RL_RXFIFO_NOTHRESH)) {
    sub RL_RXFIFO_NOTHRESH () {	0x0000e000;}
}
unless(defined(&RL_RXSTAT_RXOK)) {
    sub RL_RXSTAT_RXOK () {	0x00000001;}
}
unless(defined(&RL_RXSTAT_ALIGNERR)) {
    sub RL_RXSTAT_ALIGNERR () {	0x00000002;}
}
unless(defined(&RL_RXSTAT_CRCERR)) {
    sub RL_RXSTAT_CRCERR () {	0x00000004;}
}
unless(defined(&RL_RXSTAT_GIANT)) {
    sub RL_RXSTAT_GIANT () {	0x00000008;}
}
unless(defined(&RL_RXSTAT_RUNT)) {
    sub RL_RXSTAT_RUNT () {	0x00000010;}
}
unless(defined(&RL_RXSTAT_BADSYM)) {
    sub RL_RXSTAT_BADSYM () {	0x00000020;}
}
unless(defined(&RL_RXSTAT_BROAD)) {
    sub RL_RXSTAT_BROAD () {	0x00002000;}
}
unless(defined(&RL_RXSTAT_INDIV)) {
    sub RL_RXSTAT_INDIV () {	0x00004000;}
}
unless(defined(&RL_RXSTAT_MULTI)) {
    sub RL_RXSTAT_MULTI () {	0x00008000;}
}
unless(defined(&RL_RXSTAT_LENMASK)) {
    sub RL_RXSTAT_LENMASK () {	0xffff0000;}
}
unless(defined(&RL_RXSTAT_UNFINISHED)) {
    sub RL_RXSTAT_UNFINISHED () {	0xfff0;}
}
unless(defined(&RL_CMD_EMPTY_RXBUF)) {
    sub RL_CMD_EMPTY_RXBUF () {	0x0001;}
}
unless(defined(&RL_CMD_TX_ENB)) {
    sub RL_CMD_TX_ENB () {	0x0004;}
}
unless(defined(&RL_CMD_RX_ENB)) {
    sub RL_CMD_RX_ENB () {	0x0008;}
}
unless(defined(&RL_CMD_RESET)) {
    sub RL_CMD_RESET () {	0x0010;}
}
unless(defined(&RL_EE_DATAOUT)) {
    sub RL_EE_DATAOUT () {	0x01;}
}
unless(defined(&RL_EE_DATAIN)) {
    sub RL_EE_DATAIN () {	0x02;}
}
unless(defined(&RL_EE_CLK)) {
    sub RL_EE_CLK () {	0x04;}
}
unless(defined(&RL_EE_SEL)) {
    sub RL_EE_SEL () {	0x08;}
}
unless(defined(&RL_EE_MODE)) {
    sub RL_EE_MODE () {	(0x40|0x80);}
}
unless(defined(&RL_EEMODE_OFF)) {
    sub RL_EEMODE_OFF () {	0x00;}
}
unless(defined(&RL_EEMODE_AUTOLOAD)) {
    sub RL_EEMODE_AUTOLOAD () {	0x40;}
}
unless(defined(&RL_EEMODE_PROGRAM)) {
    sub RL_EEMODE_PROGRAM () {	0x80;}
}
unless(defined(&RL_EEMODE_WRITECFG)) {
    sub RL_EEMODE_WRITECFG () {	(0x80|0x40);}
}
unless(defined(&RL_EECMD_WRITE)) {
    sub RL_EECMD_WRITE () {	0x140;}
}
unless(defined(&RL_EECMD_READ)) {
    sub RL_EECMD_READ () {	0x180;}
}
unless(defined(&RL_EECMD_ERASE)) {
    sub RL_EECMD_ERASE () {	0x1c0;}
}
unless(defined(&RL_EE_ID)) {
    sub RL_EE_ID () {	0x00;}
}
unless(defined(&RL_EE_PCI_VID)) {
    sub RL_EE_PCI_VID () {	0x01;}
}
unless(defined(&RL_EE_PCI_DID)) {
    sub RL_EE_PCI_DID () {	0x02;}
}
unless(defined(&RL_EE_EADDR)) {
    sub RL_EE_EADDR () {	0x07;}
}
unless(defined(&RL_MII_CLK)) {
    sub RL_MII_CLK () {	0x01;}
}
unless(defined(&RL_MII_DATAIN)) {
    sub RL_MII_DATAIN () {	0x02;}
}
unless(defined(&RL_MII_DATAOUT)) {
    sub RL_MII_DATAOUT () {	0x04;}
}
unless(defined(&RL_MII_DIR)) {
    sub RL_MII_DIR () {	0x80;}
}
unless(defined(&RL_CFG0_ROM0)) {
    sub RL_CFG0_ROM0 () {	0x01;}
}
unless(defined(&RL_CFG0_ROM1)) {
    sub RL_CFG0_ROM1 () {	0x02;}
}
unless(defined(&RL_CFG0_ROM2)) {
    sub RL_CFG0_ROM2 () {	0x04;}
}
unless(defined(&RL_CFG0_PL0)) {
    sub RL_CFG0_PL0 () {	0x08;}
}
unless(defined(&RL_CFG0_PL1)) {
    sub RL_CFG0_PL1 () {	0x10;}
}
unless(defined(&RL_CFG0_10MBPS)) {
    sub RL_CFG0_10MBPS () {	0x20;}
}
unless(defined(&RL_CFG0_PCS)) {
    sub RL_CFG0_PCS () {	0x40;}
}
unless(defined(&RL_CFG0_SCR)) {
    sub RL_CFG0_SCR () {	0x80;}
}
unless(defined(&RL_CFG1_PWRDWN)) {
    sub RL_CFG1_PWRDWN () {	0x01;}
}
unless(defined(&RL_CFG1_SLEEP)) {
    sub RL_CFG1_SLEEP () {	0x02;}
}
unless(defined(&RL_CFG1_IOMAP)) {
    sub RL_CFG1_IOMAP () {	0x04;}
}
unless(defined(&RL_CFG1_MEMMAP)) {
    sub RL_CFG1_MEMMAP () {	0x08;}
}
unless(defined(&RL_CFG1_RSVD)) {
    sub RL_CFG1_RSVD () {	0x10;}
}
unless(defined(&RL_CFG1_DRVLOAD)) {
    sub RL_CFG1_DRVLOAD () {	0x20;}
}
unless(defined(&RL_CFG1_LED0)) {
    sub RL_CFG1_LED0 () {	0x40;}
}
unless(defined(&RL_CFG1_FULLDUPLEX)) {
    sub RL_CFG1_FULLDUPLEX () {	0x40;}
}
unless(defined(&RL_CFG1_LED1)) {
    sub RL_CFG1_LED1 () {	0x80;}
}
unless(defined(&RL_RX_BUF_SZ)) {
    sub RL_RX_BUF_SZ () {	 &RL_RXBUF_64;}
}
unless(defined(&RL_RXBUFLEN)) {
    sub RL_RXBUFLEN () {	(1<< (( &RL_RX_BUF_SZ >> 11) + 13));}
}
unless(defined(&RL_TX_LIST_CNT)) {
    sub RL_TX_LIST_CNT () {	4;}
}
unless(defined(&RL_MIN_FRAMELEN)) {
    sub RL_MIN_FRAMELEN () {	60;}
}
unless(defined(&RL_TXTHRESH)) {
    sub RL_TXTHRESH {
	local($x) = @_;
	eval q((($x) << 11));
    }
}
unless(defined(&RL_TX_THRESH_INIT)) {
    sub RL_TX_THRESH_INIT () {	96;}
}
unless(defined(&RL_RX_FIFOTHRESH)) {
    sub RL_RX_FIFOTHRESH () {	 &RL_RXFIFO_256BYTES;}
}
unless(defined(&RL_RX_MAXDMA)) {
    sub RL_RX_MAXDMA () {	 &RL_RXDMA_UNLIMITED;}
}
unless(defined(&RL_TX_MAXDMA)) {
    sub RL_TX_MAXDMA () {	 &RL_TXDMA_2048BYTES;}
}
unless(defined(&RL_RXCFG_CONFIG)) {
    sub RL_RXCFG_CONFIG () {	( &RL_RX_FIFOTHRESH| &RL_RX_MAXDMA| &RL_RX_BUF_SZ);}
}
unless(defined(&RL_TXCFG_CONFIG)) {
    sub RL_TXCFG_CONFIG () {	( &RL_TXCFG_IFG| &RL_TX_MAXDMA);}
}
unless(defined(&RL_ETHER_ALIGN)) {
    sub RL_ETHER_ALIGN () {	2;}
}
unless(defined(&RL_INC)) {
    sub RL_INC {
	local($x) = @_;
	eval q(($x = ($x + 1) %  &RL_TX_LIST_CNT));
    }
}
unless(defined(&RL_CUR_TXADDR)) {
    sub RL_CUR_TXADDR {
	local($x) = @_;
	eval q((( ($x->{rl_cdata}->{cur_tx}) * 4) +  &RL_TXADDR0));
    }
}
unless(defined(&RL_CUR_TXSTAT)) {
    sub RL_CUR_TXSTAT {
	local($x) = @_;
	eval q((( ($x->{rl_cdata}->{cur_tx}) * 4) +  &RL_TXSTAT0));
    }
}
unless(defined(&RL_CUR_TXMBUF)) {
    sub RL_CUR_TXMBUF {
	local($x) = @_;
	eval q(( ($x->{rl_cdata}->{rl_tx_chain[$x}->{rl_cdata}->{cur_tx]})));
    }
}
unless(defined(&RL_LAST_TXADDR)) {
    sub RL_LAST_TXADDR {
	local($x) = @_;
	eval q((( ($x->{rl_cdata}->{last_tx}) * 4) +  &RL_TXADDR0));
    }
}
unless(defined(&RL_LAST_TXSTAT)) {
    sub RL_LAST_TXSTAT {
	local($x) = @_;
	eval q((( ($x->{rl_cdata}->{last_tx}) * 4) +  &RL_TXSTAT0));
    }
}
unless(defined(&RL_LAST_TXMBUF)) {
    sub RL_LAST_TXMBUF {
	local($x) = @_;
	eval q(( ($x->{rl_cdata}->{rl_tx_chain[$x}->{rl_cdata}->{last_tx]})));
    }
}
unless(defined(&RL_MII_STARTDELIM)) {
    sub RL_MII_STARTDELIM () {	0x01;}
}
unless(defined(&RL_MII_READOP)) {
    sub RL_MII_READOP () {	0x02;}
}
unless(defined(&RL_MII_WRITEOP)) {
    sub RL_MII_WRITEOP () {	0x01;}
}
unless(defined(&RL_MII_TURNAROUND)) {
    sub RL_MII_TURNAROUND () {	0x02;}
}
unless(defined(&RL_8129)) {
    sub RL_8129 () {	1;}
}
unless(defined(&RL_8139)) {
    sub RL_8139 () {	2;}
}
unless(defined(&CSR_WRITE_4)) {
    sub CSR_WRITE_4 {
	local($sc, $csr, $val) = @_;
	eval q( &bus_space_write_4( ($sc->{rl_btag}),  ($sc->{rl_bhandle}), $csr, $val));
    }
}
unless(defined(&CSR_WRITE_2)) {
    sub CSR_WRITE_2 {
	local($sc, $csr, $val) = @_;
	eval q( &bus_space_write_2( ($sc->{rl_btag}),  ($sc->{rl_bhandle}), $csr, $val));
    }
}
unless(defined(&CSR_WRITE_1)) {
    sub CSR_WRITE_1 {
	local($sc, $csr, $val) = @_;
	eval q( &bus_space_write_1( ($sc->{rl_btag}),  ($sc->{rl_bhandle}), $csr, $val));
    }
}
unless(defined(&CSR_READ_4)) {
    sub CSR_READ_4 {
	local($sc, $csr) = @_;
	eval q( &bus_space_read_4( ($sc->{rl_btag}),  ($sc->{rl_bhandle}), $csr));
    }
}
unless(defined(&CSR_READ_2)) {
    sub CSR_READ_2 {
	local($sc, $csr) = @_;
	eval q( &bus_space_read_2( ($sc->{rl_btag}),  ($sc->{rl_bhandle}), $csr));
    }
}
unless(defined(&CSR_READ_1)) {
    sub CSR_READ_1 {
	local($sc, $csr) = @_;
	eval q( &bus_space_read_1( ($sc->{rl_btag}),  ($sc->{rl_bhandle}), $csr));
    }
}
unless(defined(&RL_TIMEOUT)) {
    sub RL_TIMEOUT () {	1000;}
}
unless(defined(&RT_VENDORID)) {
    sub RT_VENDORID () {	0x10ec;}
}
unless(defined(&RT_DEVICEID_8129)) {
    sub RT_DEVICEID_8129 () {	0x8129;}
}
unless(defined(&RT_DEVICEID_8139)) {
    sub RT_DEVICEID_8139 () {	0x8139;}
}
unless(defined(&ACCTON_VENDORID)) {
    sub ACCTON_VENDORID () {	0x1113;}
}
unless(defined(&ACCTON_DEVICEID_5030)) {
    sub ACCTON_DEVICEID_5030 () {	0x1211;}
}
unless(defined(&DELTA_VENDORID)) {
    sub DELTA_VENDORID () {	0x1500;}
}
unless(defined(&DELTA_DEVICEID_8139)) {
    sub DELTA_DEVICEID_8139 () {	0x1360;}
}
unless(defined(&ADDTRON_VENDORID)) {
    sub ADDTRON_VENDORID () {	0x4033;}
}
unless(defined(&ADDTRON_DEVICEID_8139)) {
    sub ADDTRON_DEVICEID_8139 () {	0x1360;}
}
unless(defined(&DLINK_VENDORID)) {
    sub DLINK_VENDORID () {	0x1186;}
}
unless(defined(&DLINK_DEVICEID_8139)) {
    sub DLINK_DEVICEID_8139 () {	0x1300;}
}
unless(defined(&RL_PCI_VENDOR_ID)) {
    sub RL_PCI_VENDOR_ID () {	0x00;}
}
unless(defined(&RL_PCI_DEVICE_ID)) {
    sub RL_PCI_DEVICE_ID () {	0x02;}
}
unless(defined(&RL_PCI_COMMAND)) {
    sub RL_PCI_COMMAND () {	0x04;}
}
unless(defined(&RL_PCI_STATUS)) {
    sub RL_PCI_STATUS () {	0x06;}
}
unless(defined(&RL_PCI_CLASSCODE)) {
    sub RL_PCI_CLASSCODE () {	0x09;}
}
unless(defined(&RL_PCI_LATENCY_TIMER)) {
    sub RL_PCI_LATENCY_TIMER () {	0x0d;}
}
unless(defined(&RL_PCI_HEADER_TYPE)) {
    sub RL_PCI_HEADER_TYPE () {	0x0e;}
}
unless(defined(&RL_PCI_LOIO)) {
    sub RL_PCI_LOIO () {	0x10;}
}
unless(defined(&RL_PCI_LOMEM)) {
    sub RL_PCI_LOMEM () {	0x14;}
}
unless(defined(&RL_PCI_BIOSROM)) {
    sub RL_PCI_BIOSROM () {	0x30;}
}
unless(defined(&RL_PCI_INTLINE)) {
    sub RL_PCI_INTLINE () {	0x3c;}
}
unless(defined(&RL_PCI_INTPIN)) {
    sub RL_PCI_INTPIN () {	0x3d;}
}
unless(defined(&RL_PCI_MINGNT)) {
    sub RL_PCI_MINGNT () {	0x3e;}
}
unless(defined(&RL_PCI_MINLAT)) {
    sub RL_PCI_MINLAT () {	0x0f;}
}
unless(defined(&RL_PCI_RESETOPT)) {
    sub RL_PCI_RESETOPT () {	0x48;}
}
unless(defined(&RL_PCI_EEPROM_DATA)) {
    sub RL_PCI_EEPROM_DATA () {	0x4c;}
}
unless(defined(&RL_PCI_CAPID)) {
    sub RL_PCI_CAPID () {	0x50;}
}
unless(defined(&RL_PCI_NEXTPTR)) {
    sub RL_PCI_NEXTPTR () {	0x51;}
}
unless(defined(&RL_PCI_PWRMGMTCAP)) {
    sub RL_PCI_PWRMGMTCAP () {	0x52;}
}
unless(defined(&RL_PCI_PWRMGMTCTRL)) {
    sub RL_PCI_PWRMGMTCTRL () {	0x54;}
}
unless(defined(&RL_PSTATE_MASK)) {
    sub RL_PSTATE_MASK () {	0x0003;}
}
unless(defined(&RL_PSTATE_D0)) {
    sub RL_PSTATE_D0 () {	0x0000;}
}
unless(defined(&RL_PSTATE_D1)) {
    sub RL_PSTATE_D1 () {	0x0002;}
}
unless(defined(&RL_PSTATE_D2)) {
    sub RL_PSTATE_D2 () {	0x0002;}
}
unless(defined(&RL_PSTATE_D3)) {
    sub RL_PSTATE_D3 () {	0x0003;}
}
unless(defined(&RL_PME_EN)) {
    sub RL_PME_EN () {	0x0010;}
}
unless(defined(&RL_PME_STATUS)) {
    sub RL_PME_STATUS () {	0x8000;}
}
if(defined(&__alpha__)) {
    undef(&vtophys) if defined(&vtophys);
    eval 'sub vtophys {
        local($va) = @_;
	    eval q( &alpha_XXX_dmamap($va));
    }' unless defined(&vtophys);
}
1;
