Changeset 35810 in vbox
- Timestamp:
- Feb 1, 2011 1:00:24 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 12 edited
-
include/VBox/err.h (modified) (3 diffs)
-
include/VBox/vmm/pdmdev.h (modified) (2 diffs)
-
include/VBox/vmm/pdmdrv.h (modified) (2 diffs)
-
include/VBox/vmm/pdmusb.h (modified) (2 diffs)
-
include/VBox/vmm/vmapi.h (modified) (1 diff)
-
src/VBox/Runtime/common/err/errmsg.sed (modified) (1 diff)
-
src/VBox/VMM/VMMR0/VMMR0.cpp (modified) (1 diff)
-
src/VBox/VMM/VMMR3/PDMDevice.cpp (modified) (1 diff)
-
src/VBox/VMM/VMMR3/PDMDriver.cpp (modified) (1 diff)
-
src/VBox/VMM/VMMR3/PDMUsb.cpp (modified) (1 diff)
-
src/VBox/VMM/VMMR3/VM.cpp (modified) (4 diffs)
-
src/VBox/VMM/VMMRC/VMMRC.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/err.h
r35592 r35810 932 932 /** Reason for leaving RZ: Illegal call to ring-3. */ 933 933 #define VERR_VMM_RING3_CALL_DISABLED (-2703) 934 /** The VMMR0.r0 module version does not match VBoxVMM.dll/so/dylib. 935 * If you just upgraded VirtualBox, please make terminate all VMs and make sure 936 * VBoxNetDHCP is not running. Then try again. If this error persists, try 937 * re-installing VirtualBox. */ 938 #define VERR_VMM_R0_VERSION_MISMATCH (-2704) 939 /** The VMMRC.rc module version does not match VBoxVMM.dll/so/dylib. 940 * Re-install if you are a user. Developers should make sure the build is 941 * complete or try with a clean build. */ 942 #define VERR_VMM_RC_VERSION_MISMATCH (-2705) 934 943 /** @} */ 935 944 … … 1130 1139 /** Too many instances of a usb device. */ 1131 1140 #define VERR_PDM_TOO_MANY_USB_DEVICE_INSTANCES (-2869) 1141 /** Too many instances of a usb device. */ 1142 #define VERR_PDM_TOO_MANY_USB_DEVICE_INSTANCES (-2869) 1143 /** The device instance structure version has changed. 1144 * 1145 * If you have upgraded VirtualBox recently, please make sure you have 1146 * terminated all VMs and upgraded any extension packs. If this error 1147 * persists, try re-install VirtualBox. */ 1148 #define VERR_PDM_DEVINS_VERSION_MISMATCH (-2870) 1149 /** The device helper structure version has changed. 1150 * 1151 * If you have upgraded VirtualBox recently, please make sure you have 1152 * terminated all VMs and upgraded any extension packs. If this error 1153 * persists, try re-install VirtualBox. */ 1154 #define VERR_PDM_DEVHLPR3_VERSION_MISMATCH (-2871) 1155 /** The USB device instance structure version has changed. 1156 * 1157 * If you have upgraded VirtualBox recently, please make sure you have 1158 * terminated all VMs and upgraded any extension packs. If this error 1159 * persists, try re-install VirtualBox. */ 1160 #define VERR_PDM_USBINS_VERSION_MISMATCH (-2872) 1161 /** The USB device helper structure version has changed. 1162 * 1163 * If you have upgraded VirtualBox recently, please make sure you have 1164 * terminated all VMs and upgraded any extension packs. If this error 1165 * persists, try re-install VirtualBox. */ 1166 #define VERR_PDM_USBHLPR3_VERSION_MISMATCH (-2873) 1167 /** The driver instance structure version has changed. 1168 * 1169 * If you have upgraded VirtualBox recently, please make sure you have 1170 * terminated all VMs and upgraded any extension packs. If this error 1171 * persists, try re-install VirtualBox. */ 1172 #define VERR_PDM_DRVINS_VERSION_MISMATCH (-2874) 1173 /** The driver helper structure version has changed. 1174 * 1175 * If you have upgraded VirtualBox recently, please make sure you have 1176 * terminated all VMs and upgraded any extension packs. If this error 1177 * persists, try re-install VirtualBox. */ 1178 #define VERR_PDM_DRVHLPR3_VERSION_MISMATCH (-2875) 1179 /** Generic device structure version mismatch. 1180 * 1181 * If you have upgraded VirtualBox recently, please make sure you have 1182 * terminated all VMs and upgraded any extension packs. If this error 1183 * persists, try re-install VirtualBox. */ 1184 #define VERR_PDM_DEVICE_VERSION_MISMATCH (-2876) 1185 /** Generic USB device structure version mismatch. 1186 * 1187 * If you have upgraded VirtualBox recently, please make sure you have 1188 * terminated all VMs and upgraded any extension packs. If this error 1189 * persists, try re-install VirtualBox. */ 1190 #define VERR_PDM_USBDEV_VERSION_MISMATCH (-2877) 1191 /** Generic driver structure version mismatch. 1192 * 1193 * If you have upgraded VirtualBox recently, please make sure you have 1194 * terminated all VMs and upgraded any extension packs. If this error 1195 * persists, try re-install VirtualBox. */ 1196 #define VERR_PDM_DRIVER_VERSION_MISMATCH (-2878) 1132 1197 /** @} */ 1133 1198 … … 1660 1725 * Returned by the VBOXEXTPACKREG::pfnInstalled. */ 1661 1726 #define VERR_EXTPACK_UNSUPPORTED_HOST_UNINSTALL (-6000) 1727 /** The VirtualBox version is not supported by one of the extension packs. 1728 * 1729 * You have probably upgraded VirtualBox recently. Please upgrade the 1730 * extension packs to versions compatible with this VirtualBox release. 1731 */ 1732 #define VERR_EXTPACK_VBOX_VERSION_MISMATCH (-6001) 1662 1733 /** @} */ 1663 1734 -
trunk/include/VBox/vmm/pdmdev.h
r35738 r35810 3852 3852 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pDevIns)->u32Version, PDM_DEVINS_VERSION), \ 3853 3853 ("DevIns=%#x mine=%#x\n", (pDevIns)->u32Version, PDM_DEVINS_VERSION), \ 3854 VERR_ VERSION_MISMATCH); \3854 VERR_PDM_DEVINS_VERSION_MISMATCH); \ 3855 3855 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pDevIns)->pHlpR3->u32Version, PDM_DEVHLPR3_VERSION), \ 3856 3856 ("DevHlp=%#x mine=%#x\n", (pDevIns)->pHlpR3->u32Version, PDM_DEVHLPR3_VERSION), \ 3857 VERR_ VERSION_MISMATCH); \3857 VERR_PDM_DEVHLPR3_VERSION_MISMATCH); \ 3858 3858 } while (0) 3859 3859 … … 3870 3870 { \ 3871 3871 PPDMDEVINS pDevInsTypeCheck = (pDevIns); NOREF(pDevInsTypeCheck); \ 3872 if (RT_UNLIKELY( !PDM_VERSION_ARE_COMPATIBLE((pDevIns)->u32Version, PDM_DEVINS_VERSION) \ 3873 || !PDM_VERSION_ARE_COMPATIBLE((pDevIns)->pHlpR3->u32Version, PDM_DEVHLPR3_VERSION) )) \ 3874 return VERR_VERSION_MISMATCH; \ 3872 if (RT_UNLIKELY(!PDM_VERSION_ARE_COMPATIBLE((pDevIns)->u32Version, PDM_DEVINS_VERSION) )) \ 3873 return VERR_PDM_DEVINS_VERSION_MISMATCH; \ 3874 if (RT_UNLIKELY(!PDM_VERSION_ARE_COMPATIBLE((pDevIns)->pHlpR3->u32Version, PDM_DEVHLPR3_VERSION) )) \ 3875 return VERR_PDM_DEVHLPR3_VERSION_MISMATCH; \ 3875 3876 } while (0) 3876 3877 -
trunk/include/VBox/vmm/pdmdrv.h
r35676 r35810 338 338 /** SCSI driver. */ 339 339 #define PDM_DRVREG_CLASS_SCSI RT_BIT(15) 340 /** Generic raw PCI device driver. */ 341 #define PDM_DRVREG_CLASS_PCIRAW RT_BIT(16) 340 /** Generic raw PCI device driver. */ 341 #define PDM_DRVREG_CLASS_PCIRAW RT_BIT(16) 342 342 /** @} */ 343 343 … … 437 437 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pDrvIns)->u32Version, PDM_DRVINS_VERSION), \ 438 438 ("DrvIns=%#x mine=%#x\n", (pDrvIns)->u32Version, PDM_DRVINS_VERSION), \ 439 VERR_ VERSION_MISMATCH); \439 VERR_PDM_DRVINS_VERSION_MISMATCH); \ 440 440 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pDrvIns)->pHlpR3->u32Version, PDM_DRVHLPR3_VERSION), \ 441 441 ("DrvHlp=%#x mine=%#x\n", (pDrvIns)->pHlpR3->u32Version, PDM_DRVHLPR3_VERSION), \ 442 VERR_ VERSION_MISMATCH); \442 VERR_PDM_DRVHLPR3_VERSION_MISMATCH); \ 443 443 } while (0) 444 444 -
trunk/include/VBox/vmm/pdmusb.h
r35361 r35810 733 733 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->u32Version, PDM_USBINS_VERSION), \ 734 734 ("DevIns=%#x mine=%#x\n", (pUsbIns)->u32Version, PDM_USBINS_VERSION), \ 735 VERR_ VERSION_MISMATCH); \735 VERR_PDM_USBINS_VERSION_MISMATCH); \ 736 736 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->pHlpR3->u32Version, PDM_USBHLP_VERSION), \ 737 737 ("DevHlp=%#x mine=%#x\n", (pUsbIns)->pHlpR3->u32Version, PDM_USBHLP_VERSION), \ 738 VERR_ VERSION_MISMATCH); \738 VERR_PDM_USBHLPR3_VERSION_MISMATCH); \ 739 739 } while (0) 740 740 … … 751 751 { \ 752 752 PPDMUSBINS pUsbInsTypeCheck = (pUsbIns); NOREF(pUsbInsTypeCheck); \ 753 if (RT_UNLIKELY( !PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->u32Version, PDM_USBINS_VERSION) \ 754 || !PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->pHlpR3->u32Version, PDM_USBHLPR3_VERSION) )) \ 755 return VERR_VERSION_MISMATCH; \ 753 if (RT_UNLIKELY(!PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->u32Version, PDM_USBINS_VERSION) )) \ 754 return VERR_PDM_USBINS_VERSION_MISMATCH; \ 755 if (RT_UNLIKELY(!PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->pHlpR3->u32Version, PDM_USBHLPR3_VERSION) )) \ 756 return VERR_PDM_USBHLPR3_VERSION_MISMATCH; \ 756 757 } while (0) 757 758 -
trunk/include/VBox/vmm/vmapi.h
r35361 r35810 365 365 VMMR3DECL(void) VMR3SetErrorWorker(PVM pVM); 366 366 VMMR3DECL(uint32_t) VMR3GetErrorCount(PVM pVM); 367 VMMR3DECL(uint32_t) VMR3GetErrorCountU(PUVM pUVM); 367 368 VMMR3DECL(int) VMR3AtRuntimeErrorRegister(PVM pVM, PFNVMATRUNTIMEERROR pfnAtRuntimeError, void *pvUser); 368 369 VMMR3DECL(int) VMR3AtRuntimeErrorDeregister(PVM pVM, PFNVMATRUNTIMEERROR pfnAtRuntimeError, void *pvUser); -
trunk/src/VBox/Runtime/common/err/errmsg.sed
r28800 r35810 94 94 # terminate the string 95 95 s/[[:space:]]*\*\//\"\,/ 96 97 # translate empty lines into new-lines (only one, please). 98 s/[[:space:]]*[[:space:]]\*[[:space:]][[:space:]]*\*[[:space:]][[:space:]]*/\\n/g 99 100 # remove asterics. 96 101 s/[[:space:]]*[[:space:]]\*[[:space:]][[:space:]]*/ /g 97 102 b end -
trunk/src/VBox/VMM/VMMR0/VMMR0.cpp
r35346 r35810 210 210 LogRel(("VMMR0InitVM: Revision mismatch, r3=%d r0=%d\n", uSvnRev, VMMGetSvnRev())); 211 211 SUPR0Printf("VMMR0InitVM: Revision mismatch, r3=%d r0=%d\n", uSvnRev, VMMGetSvnRev()); 212 return VERR_V ERSION_MISMATCH;212 return VERR_VMM_R0_VERSION_MISMATCH; 213 213 } 214 214 if ( !VALID_PTR(pVM) -
trunk/src/VBox/VMM/VMMR3/PDMDevice.cpp
r35346 r35810 404 404 paDevs[i].pDev->cInstances--; 405 405 /* because we're damn lazy right now, we'll say that the destructor will be called even if the constructor fails. */ 406 return rc ;406 return rc == VERR_VERSION_MISMATCH ? VERR_PDM_DEVICE_VERSION_MISMATCH : rc; 407 407 } 408 408 } /* for device instances */ -
trunk/src/VBox/VMM/VMMR3/PDMDriver.cpp
r35346 r35810 508 508 } 509 509 else 510 { 510 511 pdmR3DrvDestroyChain(pNew, PDM_TACH_FLAGS_NO_CALLBACKS); 512 if (rc == VERR_VERSION_MISMATCH) 513 rc = VERR_PDM_DRIVER_VERSION_MISMATCH; 514 } 511 515 } 512 516 else -
trunk/src/VBox/VMM/VMMR3/PDMUsb.cpp
r35346 r35810 637 637 } 638 638 else 639 { 639 640 AssertMsgFailed(("Failed to construct '%s'/%d! %Rra\n", pUsbIns->pReg->szName, pUsbIns->iInstance, rc)); 641 if (rc == VERR_VERSION_MISMATCH) 642 rc = VERR_PDM_DRIVER_VERSION_MISMATCH; 643 } 640 644 if (fAtRuntime) 641 645 pdmR3UsbDestroyDevice(pVM, pUsbIns); -
trunk/src/VBox/VMM/VMMR3/VM.cpp
r35794 r35810 269 269 270 270 /* 271 * An error occurred during VM creation. Set the error message directly272 * using the initial callback, as the callback list doesn't exist yet.271 * An error occurred during VM creation. Set the error message directly 272 * using the initial callback, as the callback list might not exist yet. 273 273 */ 274 const char *pszError = NULL;274 const char *pszError; 275 275 switch (rc) 276 276 { … … 298 298 pszError = N_("VirtualBox can't enable the AMD-V extension. Please close all other virtualization programs."); 299 299 #endif 300 break;301 302 case VERR_VERSION_MISMATCH:303 pszError = N_("VMMR0 driver version mismatch:\n"304 "Either there is an older extension package installed which does not "305 "fit to this version of VirtualBox. In that case update the extension "306 "pack. Make sure to terminate all VMs before.\n"307 "Or VirtualBox was recently upgraded and there is still some process "308 "of the older version active. Please terminate all VMs, make sure that "309 "VBoxNetDHCP is not running and try again. If you still get this error, "310 "re-install VirtualBox");311 300 break; 312 301 … … 350 339 351 340 default: 352 pszError = N_("Unknown error creating VM"); 341 if (VMR3GetErrorCountU(pUVM) == 0) 342 pszError = RTErrGetFull(rc); 343 else 344 pszError = NULL; /* already set. */ 353 345 break; 354 346 } 355 vmR3SetErrorU(pUVM, rc, RT_SRC_POS, pszError, rc); 347 if (pszError) 348 vmR3SetErrorU(pUVM, rc, RT_SRC_POS, pszError, rc); 356 349 } 357 350 else … … 3652 3645 VMMR3DECL(uint32_t) VMR3GetErrorCount(PVM pVM) 3653 3646 { 3654 return pVM->pUVM->vm.s.cErrors; 3647 AssertPtrReturn(pVM, 0); 3648 return VMR3GetErrorCountU(pVM->pUVM); 3649 } 3650 3651 3652 /** 3653 * Gets the number of errors raised via VMSetError. 3654 * 3655 * This can be used avoid double error messages. 3656 * 3657 * @returns The error count. 3658 * @param pVM The VM handle. 3659 */ 3660 VMMR3DECL(uint32_t) VMR3GetErrorCountU(PUVM pUVM) 3661 { 3662 AssertPtrReturn(pUVM, 0); 3663 AssertReturn(pUVM->u32Magic == UVM_MAGIC, 0); 3664 return pUVM->vm.s.cErrors; 3655 3665 } 3656 3666 -
trunk/src/VBox/VMM/VMMRC/VMMRC.cpp
r35346 r35810 73 73 */ 74 74 if (uArg != VMMGetSvnRev()) 75 return VERR_V ERSION_MISMATCH;75 return VERR_VMM_RC_VERSION_MISMATCH; 76 76 77 77 /*
Note:
See TracChangeset
for help on using the changeset viewer.

