VirtualBox

Changeset 24128 in vbox


Ignore:
Timestamp:
Oct 28, 2009 10:31:33 AM (15 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
54041
Message:

apicLocalInterrupt: panic if unimplemented delivery mode.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/PC/DevAPIC.cpp

    r24125 r24128  
    989989
    990990    /* If LAPIC is enabled, interrupts are subject to LVT programming. */
    991     if (u8Pin > 1)
    992     {
    993         /* There are only two local interrupt pins. */
    994         AssertMsgFailed(("Invalid LAPIC pin %d\n", u8Pin));
    995         return VERR_INVALID_PARAMETER;
    996     }
     991
     992    /* There are only two local interrupt pins. */
     993    AssertMsgReturn(u8Pin <= 1, ("Invalid LAPIC pin %d\n", u8Pin), VERR_INVALID_PARAMETER);
    997994
    998995    /* NB: We currently only deliver local interrupts to the first CPU. In theory they
     
    10091006
    10101007        u8Delivery = (u32Lvec >> 8) & 7;
    1011         switch (u8Delivery) 
     1008        switch (u8Delivery)
    10121009        {
    1013         case APIC_DM_EXTINT:
    1014             Assert(u8Pin == 0); /* PIC should be wired to LINT0. */
    1015             enmType = PDMAPICIRQ_EXTINT;
    1016             break;
    1017         case APIC_DM_NMI:
    1018             Assert(u8Pin == 0); /* NMI should be wired to LINT1. */
    1019             enmType = PDMAPICIRQ_NMI;
    1020             break;
    1021         case APIC_DM_SMI:
    1022             enmType = PDMAPICIRQ_SMI;
    1023             break;
    1024 
     1010            case APIC_DM_EXTINT:
     1011                Assert(u8Pin == 0); /* PIC should be wired to LINT0. */
     1012                enmType = PDMAPICIRQ_EXTINT;
     1013                break;
     1014            case APIC_DM_NMI:
     1015                Assert(u8Pin == 1); /* NMI should be wired to LINT1. */
     1016                enmType = PDMAPICIRQ_NMI;
     1017                break;
     1018            case APIC_DM_SMI:
     1019                enmType = PDMAPICIRQ_SMI;
     1020                break;
     1021            case APIC_DM_FIXED:
     1022                /** @todo implement APIC_DM_FIXED! */
     1023            case APIC_DM_INIT:
     1024                /** @todo implement APIC_DM_INIT? */
     1025            default:
     1026                AssertLogRelMsgFailedReturn(("delivery type %d not implemented. u8Pin=%d u8Level=%d", u8Delivery, u8Pin, u8Level),
     1027                                            VERR_INTERNAL_ERROR_4);
    10251028        }
    10261029        LogFlow(("apicLocalInterrupt: setting local interrupt type %d\n", enmType));
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette