static void ne2000_write(void *opaque, target_phys_addr_t addr,

                         uint64_t data, unsigned size)

{

    NE2000State *s = opaque;



    if (addr < 0x10 && size == 1) {

        ne2000_ioport_write(s, addr, data);

    } else if (addr == 0x10) {

        if (size <= 2) {

            ne2000_asic_ioport_write(s, addr, data);

        } else {

            ne2000_asic_ioport_writel(s, addr, data);

        }

    } else if (addr == 0x1f && size == 1) {

        ne2000_reset_ioport_write(s, addr, data);

    }

}

static void ne2000_write(void *opaque, target_phys_addr_t addr,

                         uint64_t data, unsigned size)

{

    NE2000State *s = opaque;



    if (addr < 0x10 && size == 1) {

        ne2000_ioport_write(s, addr, data);

    } else if (addr == 0x10) {

        if (size <= 2) {

            ne2000_asic_ioport_write(s, addr, data);

        } else {

            ne2000_asic_ioport_writel(s, addr, data);

        }

    } else if (addr == 0x1f && size == 1) {

        ne2000_reset_ioport_write(s, addr, data);

    }

}

static void FUNC_0(void *VAR_0, target_phys_addr_t VAR_1,

                         uint64_t VAR_2, unsigned VAR_3)

{

    NE2000State *s = VAR_0;



    if (VAR_1 < 0x10 && VAR_3 == 1) {

        ne2000_ioport_write(s, VAR_1, VAR_2);

    } else if (VAR_1 == 0x10) {

        if (VAR_3 <= 2) {

            ne2000_asic_ioport_write(s, VAR_1, VAR_2);

        } else {

            ne2000_asic_ioport_writel(s, VAR_1, VAR_2);

        }

    } else if (VAR_1 == 0x1f && VAR_3 == 1) {

        ne2000_reset_ioport_write(s, VAR_1, VAR_2);

    }

}

static void FUNC_0(void *VAR_0, target_phys_addr_t VAR_1,
uint64_t VAR_2, unsigned VAR_3)
{ NE2000State *s = VAR_0; if (VAR_1 < 0x10 && VAR_3 == 1) { ne2000_ioport_write(s, VAR_1, VAR_2); } else if (VAR_1 == 0x10) { if (VAR_3 <= 2) { ne2000_asic_ioport_write(s, VAR_1, VAR_2); } else { ne2000_asic_ioport_writel(s, VAR_1, VAR_2); } } else if (VAR_1 == 0x1f && VAR_3 == 1) { ne2000_reset_ioport_write(s, VAR_1, VAR_2); } }