VirtualBox

Changeset 11263 in vbox for trunk/src/VBox/Devices/PC


Ignore:
Timestamp:
Aug 8, 2008 3:51:31 PM (16 years ago)
Author:
vboxsync
Message:

DevPIC: Use CFGM*Def.

File:
1 edited

Legend:

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

    r11262 r11263  
    925925     * Validate and read configuration.
    926926     */
    927     if (!CFGMR3AreValuesValid(pCfgHandle, "GCEnabled\0R0Enabled\0"))
     927    if (!CFGMR3AreValuesValid(pCfgHandle, "GCEnabled\0" "R0Enabled\0"))
    928928        return VERR_PDM_DEVINS_UNKNOWN_CFG_VALUES;
    929929
    930     rc = CFGMR3QueryBool(pCfgHandle, "GCEnabled", &fGCEnabled);
    931     if (rc == VERR_CFGM_VALUE_NOT_FOUND)
    932         fGCEnabled = true;
    933     else if (RT_FAILURE(rc))
     930    rc = CFGMR3QueryBoolDef(pCfgHandle, "GCEnabled", &fGCEnabled, true);
     931    if (RT_FAILURE(rc))
    934932        return PDMDEV_SET_ERROR(pDevIns, rc,
    935933                                N_("Configuration error: failed to read GCEnabled as boolean"));
    936934
    937     rc = CFGMR3QueryBool(pCfgHandle, "R0Enabled", &fR0Enabled);
    938     if (rc == VERR_CFGM_VALUE_NOT_FOUND)
    939         fR0Enabled = true;
    940     else if (RT_FAILURE(rc))
     935    rc = CFGMR3QueryBoolDef(pCfgHandle, "R0Enabled", &fR0Enabled, true);
     936    if (RT_FAILURE(rc))
    941937        return PDMDEV_SET_ERROR(pDevIns, rc,
    942938                                N_("Configuration error: failed to read R0Enabled as boolean"));
    943939
    944     Log(("i8259: fGCEnabled=%d fR0Enabled=%d\n", fGCEnabled, fR0Enabled));
     940    Log(("DevPIC: fGCEnabled=%RTbool fR0Enabled=%RTbool\n", fGCEnabled, fR0Enabled));
    945941
    946942    /*
Note: See TracChangeset for help on using the changeset viewer.

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