Commit f88e4b91bea91beaa4f9dde28ccb4aa973c1dd4e
1 parent
66de733b
Allow boot without a drive on Sparc machines (partly extracted from Xen)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4997 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
4 changed files
with
16 additions
and
2 deletions
hw/boards.h
hw/sun4m.c
... | ... | @@ -1242,6 +1242,7 @@ QEMUMachine ss5_machine = { |
1242 | 1242 | .desc = "Sun4m platform, SPARCstation 5", |
1243 | 1243 | .init = ss5_init, |
1244 | 1244 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1245 | + .nodisk_ok = 1, | |
1245 | 1246 | }; |
1246 | 1247 | |
1247 | 1248 | QEMUMachine ss10_machine = { |
... | ... | @@ -1249,6 +1250,7 @@ QEMUMachine ss10_machine = { |
1249 | 1250 | .desc = "Sun4m platform, SPARCstation 10", |
1250 | 1251 | .init = ss10_init, |
1251 | 1252 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1253 | + .nodisk_ok = 1, | |
1252 | 1254 | }; |
1253 | 1255 | |
1254 | 1256 | QEMUMachine ss600mp_machine = { |
... | ... | @@ -1256,6 +1258,7 @@ QEMUMachine ss600mp_machine = { |
1256 | 1258 | .desc = "Sun4m platform, SPARCserver 600MP", |
1257 | 1259 | .init = ss600mp_init, |
1258 | 1260 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1261 | + .nodisk_ok = 1, | |
1259 | 1262 | }; |
1260 | 1263 | |
1261 | 1264 | QEMUMachine ss20_machine = { |
... | ... | @@ -1263,6 +1266,7 @@ QEMUMachine ss20_machine = { |
1263 | 1266 | .desc = "Sun4m platform, SPARCstation 20", |
1264 | 1267 | .init = ss20_init, |
1265 | 1268 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1269 | + .nodisk_ok = 1, | |
1266 | 1270 | }; |
1267 | 1271 | |
1268 | 1272 | QEMUMachine ss2_machine = { |
... | ... | @@ -1270,6 +1274,7 @@ QEMUMachine ss2_machine = { |
1270 | 1274 | .desc = "Sun4c platform, SPARCstation 2", |
1271 | 1275 | .init = ss2_init, |
1272 | 1276 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1277 | + .nodisk_ok = 1, | |
1273 | 1278 | }; |
1274 | 1279 | |
1275 | 1280 | QEMUMachine voyager_machine = { |
... | ... | @@ -1277,6 +1282,7 @@ QEMUMachine voyager_machine = { |
1277 | 1282 | .desc = "Sun4m platform, SPARCstation Voyager", |
1278 | 1283 | .init = vger_init, |
1279 | 1284 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1285 | + .nodisk_ok = 1, | |
1280 | 1286 | }; |
1281 | 1287 | |
1282 | 1288 | QEMUMachine ss_lx_machine = { |
... | ... | @@ -1284,6 +1290,7 @@ QEMUMachine ss_lx_machine = { |
1284 | 1290 | .desc = "Sun4m platform, SPARCstation LX", |
1285 | 1291 | .init = ss_lx_init, |
1286 | 1292 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1293 | + .nodisk_ok = 1, | |
1287 | 1294 | }; |
1288 | 1295 | |
1289 | 1296 | QEMUMachine ss4_machine = { |
... | ... | @@ -1291,6 +1298,7 @@ QEMUMachine ss4_machine = { |
1291 | 1298 | .desc = "Sun4m platform, SPARCstation 4", |
1292 | 1299 | .init = ss4_init, |
1293 | 1300 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1301 | + .nodisk_ok = 1, | |
1294 | 1302 | }; |
1295 | 1303 | |
1296 | 1304 | QEMUMachine scls_machine = { |
... | ... | @@ -1298,6 +1306,7 @@ QEMUMachine scls_machine = { |
1298 | 1306 | .desc = "Sun4m platform, SPARCClassic", |
1299 | 1307 | .init = scls_init, |
1300 | 1308 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1309 | + .nodisk_ok = 1, | |
1301 | 1310 | }; |
1302 | 1311 | |
1303 | 1312 | QEMUMachine sbook_machine = { |
... | ... | @@ -1305,6 +1314,7 @@ QEMUMachine sbook_machine = { |
1305 | 1314 | .desc = "Sun4m platform, SPARCbook", |
1306 | 1315 | .init = sbook_init, |
1307 | 1316 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1317 | + .nodisk_ok = 1, | |
1308 | 1318 | }; |
1309 | 1319 | |
1310 | 1320 | static const struct sun4d_hwdef sun4d_hwdefs[] = { |
... | ... | @@ -1542,6 +1552,7 @@ QEMUMachine ss1000_machine = { |
1542 | 1552 | .desc = "Sun4d platform, SPARCserver 1000", |
1543 | 1553 | .init = ss1000_init, |
1544 | 1554 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1555 | + .nodisk_ok = 1, | |
1545 | 1556 | }; |
1546 | 1557 | |
1547 | 1558 | QEMUMachine ss2000_machine = { |
... | ... | @@ -1549,4 +1560,5 @@ QEMUMachine ss2000_machine = { |
1549 | 1560 | .desc = "Sun4d platform, SPARCcenter 2000", |
1550 | 1561 | .init = ss2000_init, |
1551 | 1562 | .ram_require = PROM_SIZE_MAX + TCX_SIZE, |
1563 | + .nodisk_ok = 1, | |
1552 | 1564 | }; | ... | ... |
hw/sun4u.c
... | ... | @@ -450,6 +450,7 @@ QEMUMachine sun4u_machine = { |
450 | 450 | .desc = "Sun4u platform", |
451 | 451 | .init = sun4u_init, |
452 | 452 | .ram_require = PROM_SIZE_MAX + VGA_RAM_SIZE, |
453 | + .nodisk_ok = 1, | |
453 | 454 | }; |
454 | 455 | |
455 | 456 | QEMUMachine sun4v_machine = { |
... | ... | @@ -457,4 +458,5 @@ QEMUMachine sun4v_machine = { |
457 | 458 | .desc = "Sun4v platform", |
458 | 459 | .init = sun4v_init, |
459 | 460 | .ram_require = PROM_SIZE_MAX + VGA_RAM_SIZE, |
461 | + .nodisk_ok = 1, | |
460 | 462 | }; | ... | ... |
vl.c
... | ... | @@ -8879,9 +8879,8 @@ int main(int argc, char **argv) |
8879 | 8879 | linux_boot = (kernel_filename != NULL); |
8880 | 8880 | net_boot = (boot_devices_bitmap >> ('n' - 'a')) & 0xF; |
8881 | 8881 | |
8882 | - /* XXX: this should not be: some embedded targets just have flash */ | |
8883 | 8882 | if (!linux_boot && net_boot == 0 && |
8884 | - nb_drives_opt == 0) | |
8883 | + !machine->nodisk_ok && nb_drives_opt == 0) | |
8885 | 8884 | help(1); |
8886 | 8885 | |
8887 | 8886 | if (!linux_boot && *kernel_cmdline != '\0') { | ... | ... |