- Timestamp:
- Apr 3, 2009 2:47:51 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/ConsoleImpl2.cpp
r18664 r18696 93 93 #include <VBox/param.h> 94 94 95 /* Comment out the following line to remove VMWare compatibility hack. */ 96 #define VMWARE_NET_IN_SLOT_11 95 97 96 98 /** … … 1177 1179 * Network adapters 1178 1180 */ 1181 #ifdef VMWARE_NET_IN_SLOT_11 1182 bool fSwapSlots3and11 = false; 1183 #endif 1179 1184 PCFGMNODE pDevPCNet = NULL; /* PCNet-type devices */ 1180 1185 rc = CFGMR3InsertNode(pDevices, "pcnet", &pDevPCNet); RC_CHECK(); … … 1232 1237 iPciDeviceNo = ulInstance - 4 + 16; 1233 1238 } 1239 #ifdef VMWARE_NET_IN_SLOT_11 1240 /* 1241 * Dirty hack for PCI slot compatibility with VMWare, 1242 * it assigns slot 11 to the first network controller. 1243 */ 1244 if (iPciDeviceNo == 3 && adapterType == NetworkAdapterType_I82545EM) 1245 { 1246 iPciDeviceNo = 11; 1247 fSwapSlots3and11 = true; 1248 } 1249 #endif 1234 1250 rc = CFGMR3InsertInteger(pInst, "PCIDeviceNo", iPciDeviceNo); RC_CHECK(); 1235 1251 Assert(!afPciDeviceNo[iPciDeviceNo]); … … 2338 2354 rc = CFGMR3InsertNode(pInst, "Config", &pCfg); RC_CHECK(); 2339 2355 rc = CFGMR3InsertInteger(pInst, "Trusted", 1); /* bool */ RC_CHECK(); 2356 #ifdef VMWARE_NET_IN_SLOT_11 2357 /* 2358 * Dirty hack for PCI slot compatibility with VMWare, 2359 * it assigns slot 11 to the first network controller. 2360 */ 2361 unsigned iPciDeviceNo = 11; 2362 if (fSwapSlots3and11) 2363 iPciDeviceNo = 3; 2364 rc = CFGMR3InsertInteger(pInst, "PCIDeviceNo", iPciDeviceNo); RC_CHECK(); 2365 Assert(!afPciDeviceNo[iPciDeviceNo]); 2366 afPciDeviceNo[iPciDeviceNo] = true; 2367 #else 2340 2368 rc = CFGMR3InsertInteger(pInst, "PCIDeviceNo", 11); RC_CHECK(); 2341 2369 Assert(!afPciDeviceNo[11]); 2342 2370 afPciDeviceNo[11] = true; 2371 #endif 2343 2372 rc = CFGMR3InsertInteger(pInst, "PCIFunctionNo", 0); RC_CHECK(); 2344 2373
Note:
See TracChangeset
for help on using the changeset viewer.