- Timestamp:
- Nov 19, 2008 6:37:22 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxManage/VBoxManage.cpp
r14258 r14371 1149 1149 /* 1150 1150 * SATA. 1151 * 1152 * Contributed by: James Lucas 1151 1153 */ 1154 #ifdef VBOX_WITH_AHCI 1152 1155 ComPtr<ISATAController> SATACtl; 1156 BOOL fSataEnabled; 1153 1157 rc = machine->COMGETTER(SATAController)(SATACtl.asOutParam()); 1154 1158 if (SUCCEEDED(rc)) 1155 1159 { 1156 BOOL fEnabled; 1157 rc = SATACtl->COMGETTER(Enabled)(&fEnabled); 1160 rc = SATACtl->COMGETTER(Enabled)(&fSataEnabled); 1158 1161 if (FAILED(rc)) 1159 f Enabled = false;1162 fSataEnabled = false; 1160 1163 if (details == VMINFO_MACHINEREADABLE) 1161 RTPrintf("sata=\"%s\"\n", f Enabled ? "on" : "off");1164 RTPrintf("sata=\"%s\"\n", fSataEnabled ? "on" : "off"); 1162 1165 else 1163 RTPrintf("SATA: %s\n", fEnabled ? "enabled" : "disabled"); 1164 } 1166 RTPrintf("SATA: %s\n", fSataEnabled ? "enabled" : "disabled"); 1167 } 1168 1169 /* 1170 * SATA Hard disks 1171 */ 1172 if (fSataEnabled) 1173 { 1174 ComPtr<IHardDisk2> hardDisk; 1175 Bstr filePath; 1176 ULONG cSataPorts; 1177 1178 SATACtl->COMGETTER(PortCount)(&cSataPorts); 1179 for (ULONG i = 0; i < cSataPorts; ++ i) 1180 { 1181 rc = machine->GetHardDisk2(StorageBus_SATA, i, 0, hardDisk.asOutParam()); 1182 if (SUCCEEDED(rc) && hardDisk) 1183 { 1184 hardDisk->COMGETTER(Location)(filePath.asOutParam()); 1185 hardDisk->COMGETTER(Id)(uuid.asOutParam()); 1186 if (details == VMINFO_MACHINEREADABLE) 1187 { 1188 RTPrintf("sata%d=\"%lS\"\n", i, filePath.raw()); 1189 RTPrintf("sata%dImageUUID=\"%s\"\n", i, uuid.toString().raw()); 1190 } 1191 else 1192 RTPrintf("SATA %d: %lS (UUID: %s)\n", i, filePath.raw(), uuid.toString().raw()); 1193 } 1194 else 1195 { 1196 if (details == VMINFO_MACHINEREADABLE) 1197 RTPrintf("sata%d=\"none\"\n",i); 1198 } 1199 } 1200 } 1201 #endif 1165 1202 1166 1203 /* 1167 * Hard disks1204 * IDE Hard disks 1168 1205 */ 1169 1206 IDEControllerType_T ideController;
Note:
See TracChangeset
for help on using the changeset viewer.