VirtualBox

vbox的更動 11185 路徑 trunk/src/VBox/Devices/Bus


忽略:
時間撮記:
2008-8-6 下午05:09:12 (16 年 以前)
作者:
vboxsync
訊息:

DevPCI: Use CFGM*Def.

檔案:
修改 1 筆資料

圖例:

未更動
新增
刪除
  • trunk/src/VBox/Devices/Bus/DevPCI.cpp

    r11169 r11185  
    14461446     * Validate and read configuration.
    14471447     */
    1448     if (!CFGMR3AreValuesValid(pCfgHandle, "IOAPIC\0" "GCEnabled\0R0Enabled\0"))
     1448    if (!CFGMR3AreValuesValid(pCfgHandle, "IOAPIC\0" "GCEnabled\0" "R0Enabled\0"))
    14491449        return VERR_PDM_DEVINS_UNKNOWN_CFG_VALUES;
    14501450
    14511451    /* query whether we got an IOAPIC */
    1452     rc = CFGMR3QueryBool(pCfgHandle, "IOAPIC", &fUseIoApic);
    1453     if (rc == VERR_CFGM_VALUE_NOT_FOUND)
    1454         fUseIoApic = false;
    1455     else if (VBOX_FAILURE(rc))
     1452    rc = CFGMR3QueryBoolDef(pCfgHandle, "IOAPIC", &fUseIoApic, false);
     1453    if (VBOX_FAILURE(rc))
    14561454        return PDMDEV_SET_ERROR(pDevIns, rc,
    14571455                                N_("Configuration error: Failed to query boolean value \"IOAPIC\""));
    14581456
    14591457    /* check if RC code is enabled. */
    1460     rc = CFGMR3QueryBool(pCfgHandle, "GCEnabled", &fGCEnabled);
    1461     if (rc == VERR_CFGM_VALUE_NOT_FOUND)
    1462         fGCEnabled = true;
    1463     else if (VBOX_FAILURE(rc))
     1458    rc = CFGMR3QueryBoolDef(pCfgHandle, "GCEnabled", &fGCEnabled, true);
     1459    if (VBOX_FAILURE(rc))
    14641460        return PDMDEV_SET_ERROR(pDevIns, rc,
    14651461                                N_("Configuration error: Failed to query boolean value \"GCEnabled\""));
    1466     Log(("PCI: fGCEnabled=%d\n", fGCEnabled));
    14671462
    14681463    /* check if R0 code is enabled. */
    1469     rc = CFGMR3QueryBool(pCfgHandle, "R0Enabled", &fR0Enabled);
    1470     if (rc == VERR_CFGM_VALUE_NOT_FOUND)
    1471         fR0Enabled = true;
    1472     else if (VBOX_FAILURE(rc))
     1464    rc = CFGMR3QueryBoolDef(pCfgHandle, "R0Enabled", &fR0Enabled, true);
     1465    if (VBOX_FAILURE(rc))
    14731466        return PDMDEV_SET_ERROR(pDevIns, rc,
    14741467                                N_("Configuration error: Failed to query boolean value \"R0Enabled\""));
    1475     Log(("PCI: fR0Enabled=%d\n", fR0Enabled));
     1468    Log(("PCI: fUseIoApic=%RTbool fGCEnabled=%RTbool fR0Enabled=%RTbool\n", fUseIoApic, fGCEnabled, fR0Enabled));
    14761469
    14771470    /*
注意: 瀏覽 TracChangeset 來幫助您使用更動檢視器

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