require '_h2ph_pre.ph';

no warnings 'redefine';

unless(defined(&AXE_CMD_LEN)) {
    sub AXE_CMD_LEN {
	my($x) = @_;
	eval q(((($x) & 0xf000) >> 12));
    }
}
unless(defined(&AXE_CMD_DIR)) {
    sub AXE_CMD_DIR {
	my($x) = @_;
	eval q(((($x) & 0xf00) >> 8));
    }
}
unless(defined(&AXE_CMD_CMD)) {
    sub AXE_CMD_CMD {
	my($x) = @_;
	eval q((($x) & 0xff));
    }
}
unless(defined(&AXE_172_CMD_READ_RXTX_SRAM)) {
    sub AXE_172_CMD_READ_RXTX_SRAM () {	0x2002;}
}
unless(defined(&AXE_182_CMD_READ_RXTX_SRAM)) {
    sub AXE_182_CMD_READ_RXTX_SRAM () {	0x8002;}
}
unless(defined(&AXE_172_CMD_WRITE_RX_SRAM)) {
    sub AXE_172_CMD_WRITE_RX_SRAM () {	0x103;}
}
unless(defined(&AXE_172_CMD_WRITE_TX_SRAM)) {
    sub AXE_172_CMD_WRITE_TX_SRAM () {	0x104;}
}
unless(defined(&AXE_182_CMD_WRITE_RXTX_SRAM)) {
    sub AXE_182_CMD_WRITE_RXTX_SRAM () {	0x8103;}
}
unless(defined(&AXE_CMD_MII_OPMODE_SW)) {
    sub AXE_CMD_MII_OPMODE_SW () {	0x106;}
}
unless(defined(&AXE_CMD_MII_READ_REG)) {
    sub AXE_CMD_MII_READ_REG () {	0x2007;}
}
unless(defined(&AXE_CMD_MII_WRITE_REG)) {
    sub AXE_CMD_MII_WRITE_REG () {	0x2108;}
}
unless(defined(&AXE_CMD_MII_READ_OPMODE)) {
    sub AXE_CMD_MII_READ_OPMODE () {	0x1009;}
}
unless(defined(&AXE_CMD_MII_OPMODE_HW)) {
    sub AXE_CMD_MII_OPMODE_HW () {	0x10a;}
}
unless(defined(&AXE_CMD_SROM_READ)) {
    sub AXE_CMD_SROM_READ () {	0x200b;}
}
unless(defined(&AXE_CMD_SROM_WRITE)) {
    sub AXE_CMD_SROM_WRITE () {	0x10c;}
}
unless(defined(&AXE_CMD_SROM_WR_ENABLE)) {
    sub AXE_CMD_SROM_WR_ENABLE () {	0x10d;}
}
unless(defined(&AXE_CMD_SROM_WR_DISABLE)) {
    sub AXE_CMD_SROM_WR_DISABLE () {	0x10e;}
}
unless(defined(&AXE_CMD_RXCTL_READ)) {
    sub AXE_CMD_RXCTL_READ () {	0x200f;}
}
unless(defined(&AXE_CMD_RXCTL_WRITE)) {
    sub AXE_CMD_RXCTL_WRITE () {	0x110;}
}
unless(defined(&AXE_CMD_READ_IPG012)) {
    sub AXE_CMD_READ_IPG012 () {	0x3011;}
}
unless(defined(&AXE_172_CMD_WRITE_IPG0)) {
    sub AXE_172_CMD_WRITE_IPG0 () {	0x112;}
}
unless(defined(&AXE_172_CMD_WRITE_IPG1)) {
    sub AXE_172_CMD_WRITE_IPG1 () {	0x113;}
}
unless(defined(&AXE_172_CMD_WRITE_IPG2)) {
    sub AXE_172_CMD_WRITE_IPG2 () {	0x114;}
}
unless(defined(&AXE_178_CMD_WRITE_IPG012)) {
    sub AXE_178_CMD_WRITE_IPG012 () {	0x112;}
}
unless(defined(&AXE_CMD_READ_MCAST)) {
    sub AXE_CMD_READ_MCAST () {	0x8015;}
}
unless(defined(&AXE_CMD_WRITE_MCAST)) {
    sub AXE_CMD_WRITE_MCAST () {	0x8116;}
}
unless(defined(&AXE_172_CMD_READ_NODEID)) {
    sub AXE_172_CMD_READ_NODEID () {	0x6017;}
}
unless(defined(&AXE_172_CMD_WRITE_NODEID)) {
    sub AXE_172_CMD_WRITE_NODEID () {	0x6118;}
}
unless(defined(&AXE_178_CMD_READ_NODEID)) {
    sub AXE_178_CMD_READ_NODEID () {	0x6013;}
}
unless(defined(&AXE_178_CMD_WRITE_NODEID)) {
    sub AXE_178_CMD_WRITE_NODEID () {	0x6014;}
}
unless(defined(&AXE_CMD_READ_PHYID)) {
    sub AXE_CMD_READ_PHYID () {	0x2019;}
}
unless(defined(&AXE_172_CMD_READ_MEDIA)) {
    sub AXE_172_CMD_READ_MEDIA () {	0x101a;}
}
unless(defined(&AXE_178_CMD_READ_MEDIA)) {
    sub AXE_178_CMD_READ_MEDIA () {	0x201a;}
}
unless(defined(&AXE_CMD_WRITE_MEDIA)) {
    sub AXE_CMD_WRITE_MEDIA () {	0x11b;}
}
unless(defined(&AXE_CMD_READ_MONITOR_MODE)) {
    sub AXE_CMD_READ_MONITOR_MODE () {	0x101c;}
}
unless(defined(&AXE_CMD_WRITE_MONITOR_MODE)) {
    sub AXE_CMD_WRITE_MONITOR_MODE () {	0x11d;}
}
unless(defined(&AXE_CMD_READ_GPIO)) {
    sub AXE_CMD_READ_GPIO () {	0x101e;}
}
unless(defined(&AXE_CMD_WRITE_GPIO)) {
    sub AXE_CMD_WRITE_GPIO () {	0x11f;}
}
unless(defined(&AXE_CMD_SW_RESET_REG)) {
    sub AXE_CMD_SW_RESET_REG () {	0x120;}
}
unless(defined(&AXE_CMD_SW_PHY_STATUS)) {
    sub AXE_CMD_SW_PHY_STATUS () {	0x21;}
}
unless(defined(&AXE_CMD_SW_PHY_SELECT)) {
    sub AXE_CMD_SW_PHY_SELECT () {	0x122;}
}
unless(defined(&AXE_SW_RESET_CLEAR)) {
    sub AXE_SW_RESET_CLEAR () {	0x;}
}
unless(defined(&AXE_SW_RESET_RR)) {
    sub AXE_SW_RESET_RR () {	0x1;}
}
unless(defined(&AXE_SW_RESET_RT)) {
    sub AXE_SW_RESET_RT () {	0x2;}
}
unless(defined(&AXE_SW_RESET_PRTE)) {
    sub AXE_SW_RESET_PRTE () {	0x4;}
}
unless(defined(&AXE_SW_RESET_PRL)) {
    sub AXE_SW_RESET_PRL () {	0x8;}
}
unless(defined(&AXE_SW_RESET_BZ)) {
    sub AXE_SW_RESET_BZ () {	0x10;}
}
unless(defined(&AXE_SW_RESET_IPRL)) {
    sub AXE_SW_RESET_IPRL () {	0x20;}
}
unless(defined(&AXE_SW_RESET_IPPD)) {
    sub AXE_SW_RESET_IPPD () {	0x40;}
}
unless(defined(&AXE_178_RESET_MAGIC)) {
    sub AXE_178_RESET_MAGIC () {	0x40;}
}
unless(defined(&AXE_178_MEDIA_GMII)) {
    sub AXE_178_MEDIA_GMII () {	0x1;}
}
unless(defined(&AXE_MEDIA_FULL_DUPLEX)) {
    sub AXE_MEDIA_FULL_DUPLEX () {	0x2;}
}
unless(defined(&AXE_172_MEDIA_TX_ABORT_ALLOW)) {
    sub AXE_172_MEDIA_TX_ABORT_ALLOW () {	0x4;}
}
unless(defined(&AXE_178_MEDIA_MAGIC)) {
    sub AXE_178_MEDIA_MAGIC () {	0x4;}
}
unless(defined(&AXE_178_MEDIA_ENCK)) {
    sub AXE_178_MEDIA_ENCK () {	0x8;}
}
unless(defined(&AXE_172_MEDIA_FLOW_CONTROL_EN)) {
    sub AXE_172_MEDIA_FLOW_CONTROL_EN () {	0x10;}
}
unless(defined(&AXE_178_MEDIA_RXFLOW_CONTROL_EN)) {
    sub AXE_178_MEDIA_RXFLOW_CONTROL_EN () {	0x10;}
}
unless(defined(&AXE_178_MEDIA_TXFLOW_CONTROL_EN)) {
    sub AXE_178_MEDIA_TXFLOW_CONTROL_EN () {	0x20;}
}
unless(defined(&AXE_178_MEDIA_JUMBO_EN)) {
    sub AXE_178_MEDIA_JUMBO_EN () {	0x40;}
}
unless(defined(&AXE_178_MEDIA_LTPF_ONLY)) {
    sub AXE_178_MEDIA_LTPF_ONLY () {	0x80;}
}
unless(defined(&AXE_178_MEDIA_RX_EN)) {
    sub AXE_178_MEDIA_RX_EN () {	0x100;}
}
unless(defined(&AXE_178_MEDIA_100TX)) {
    sub AXE_178_MEDIA_100TX () {	0x200;}
}
unless(defined(&AXE_178_MEDIA_SBP)) {
    sub AXE_178_MEDIA_SBP () {	0x800;}
}
unless(defined(&AXE_178_MEDIA_SUPERMAC)) {
    sub AXE_178_MEDIA_SUPERMAC () {	0x1000;}
}
unless(defined(&AXE_RXCMD_PROMISC)) {
    sub AXE_RXCMD_PROMISC () {	0x1;}
}
unless(defined(&AXE_RXCMD_ALLMULTI)) {
    sub AXE_RXCMD_ALLMULTI () {	0x2;}
}
unless(defined(&AXE_172_RXCMD_UNICAST)) {
    sub AXE_172_RXCMD_UNICAST () {	0x4;}
}
unless(defined(&AXE_178_RXCMD_KEEP_INVALID_CRC)) {
    sub AXE_178_RXCMD_KEEP_INVALID_CRC () {	0x4;}
}
unless(defined(&AXE_RXCMD_BROADCAST)) {
    sub AXE_RXCMD_BROADCAST () {	0x8;}
}
unless(defined(&AXE_RXCMD_MULTICAST)) {
    sub AXE_RXCMD_MULTICAST () {	0x10;}
}
unless(defined(&AXE_RXCMD_ENABLE)) {
    sub AXE_RXCMD_ENABLE () {	0x80;}
}
unless(defined(&AXE_178_RXCMD_MFB)) {
    sub AXE_178_RXCMD_MFB () {	0x300;}
}
unless(defined(&AXE_NOPHY)) {
    sub AXE_NOPHY () {	0xe0;}
}
unless(defined(&AXE_INTPHY)) {
    sub AXE_INTPHY () {	0x10;}
}
unless(defined(&AXE_TIMEOUT)) {
    sub AXE_TIMEOUT () {	1000;}
}
unless(defined(&AXE_172_BUFSZ)) {
    sub AXE_172_BUFSZ () {	1536;}
}
unless(defined(&AXE_178_MIN_BUFSZ)) {
    sub AXE_178_MIN_BUFSZ () {	2048;}
}
unless(defined(&AXE_178_MAX_BUFSZ)) {
    sub AXE_178_MAX_BUFSZ () {	16384;}
}
unless(defined(&AXE_RX_LIST_CNT)) {
    sub AXE_RX_LIST_CNT () {	1;}
}
unless(defined(&AXE_TX_LIST_CNT)) {
    sub AXE_TX_LIST_CNT () {	1;}
}
unless(defined(&AXE_CTL_READ)) {
    sub AXE_CTL_READ () {	0x1;}
}
unless(defined(&AXE_CTL_WRITE)) {
    sub AXE_CTL_WRITE () {	0x2;}
}
unless(defined(&AXE_CONFIG_NO)) {
    sub AXE_CONFIG_NO () {	1;}
}
unless(defined(&AXE_IFACE_IDX)) {
    sub AXE_IFACE_IDX () {	0;}
}
unless(defined(&AXE_ENDPT_RX)) {
    sub AXE_ENDPT_RX () {	0x;}
}
unless(defined(&AXE_ENDPT_TX)) {
    sub AXE_ENDPT_TX () {	0x1;}
}
unless(defined(&AXE_ENDPT_INTR)) {
    sub AXE_ENDPT_INTR () {	0x2;}
}
unless(defined(&AXE_ENDPT_MAX)) {
    sub AXE_ENDPT_MAX () {	0x3;}
}
unless(defined(&AX178)) {
    sub AX178 () {	0x1;}
}
unless(defined(&AX772)) {
    sub AX772 () {	0x2;}
}
if(defined( &__FreeBSD__)) {
    eval 'sub GET_MII {
        my($sc) = @_;
	    eval q(( &device_get_softc(($sc)-> &axe_mii)));
    }' unless defined(&GET_MII);
}
 elsif(defined( &__NetBSD__)) {
    eval 'sub GET_MII {
        my($sc) = @_;
	    eval q((($sc)-> &axe_mii));
    }' unless defined(&GET_MII);
}
 elsif(defined( &__OpenBSD__)) {
    eval 'sub GET_MII {
        my($sc) = @_;
	    eval q((($sc)-> &axe_mii));
    }' unless defined(&GET_MII);
}
unless(defined(&GET_IFP)) {
    sub GET_IFP {
	my($sc) = @_;
	eval q((($sc)-> ($arpcom->{ac_if})));
    }
}
1;
