void apic_deliver_pic_intr(DeviceState *dev, int level)

{

    APICCommonState *s = APIC_COMMON(dev);



    if (level) {

        apic_local_deliver(s, APIC_LVT_LINT0);

    } else {

        uint32_t lvt = s->lvt[APIC_LVT_LINT0];



        switch ((lvt >> 8) & 7) {

        case APIC_DM_FIXED:

            if (!(lvt & APIC_LVT_LEVEL_TRIGGER))

                break;

            apic_reset_bit(s->irr, lvt & 0xff);

            /* fall through */

        case APIC_DM_EXTINT:

            cpu_reset_interrupt(CPU(s->cpu), CPU_INTERRUPT_HARD);

            break;

        }

    }

}

void apic_deliver_pic_intr(DeviceState *dev, int level)

{

    APICCommonState *s = APIC_COMMON(dev);



    if (level) {

        apic_local_deliver(s, APIC_LVT_LINT0);

    } else {

        uint32_t lvt = s->lvt[APIC_LVT_LINT0];



        switch ((lvt >> 8) & 7) {

        case APIC_DM_FIXED:

            if (!(lvt & APIC_LVT_LEVEL_TRIGGER))

                break;

            apic_reset_bit(s->irr, lvt & 0xff);

            

        case APIC_DM_EXTINT:

            cpu_reset_interrupt(CPU(s->cpu), CPU_INTERRUPT_HARD);

            break;

        }

    }

}

            cpu_reset_interrupt(CPU(s->cpu), CPU_INTERRUPT_HARD);
void FUNC_0(DeviceState *VAR_0, int VAR_1)

{

    APICCommonState *s = APIC_COMMON(VAR_0);



    if (VAR_1) {

        apic_local_deliver(s, APIC_LVT_LINT0);

    } else {

        uint32_t lvt = s->lvt[APIC_LVT_LINT0];



        switch ((lvt >> 8) & 7) {

        case APIC_DM_FIXED:

            if (!(lvt & APIC_LVT_LEVEL_TRIGGER))

                break;

            apic_reset_bit(s->irr, lvt & 0xff);

            

        case APIC_DM_EXTINT:

            cpu_reset_interrupt(CPU(s->cpu), CPU_INTERRUPT_HARD);

            break;

        }

    }

}

void FUNC_0(DeviceState *VAR_0, int VAR_1)
{ APICCommonState *s = APIC_COMMON(VAR_0); if (VAR_1) { apic_local_deliver(s, APIC_LVT_LINT0); } else { uint32_t lvt = s->lvt[APIC_LVT_LINT0]; switch ((lvt >> 8) & 7) { case APIC_DM_FIXED:
if (!(lvt & APIC_LVT_LEVEL_TRIGGER))
break; apic_reset_bit(s->irr, lvt & 0xff); case APIC_DM_EXTINT:
cpu_reset_interrupt(CPU(s->cpu), CPU_INTERRUPT_HARD); break; } } }