Fix boot=on flag for CDROMs
authorIustin Pop <iustin@google.com>
Mon, 23 Jul 2012 12:46:08 +0000 (14:46 +0200)
committerIustin Pop <iustin@google.com>
Tue, 24 Jul 2012 15:10:43 +0000 (17:10 +0200)
commit24be50e04a2eb3d691b8f59cde4206eac32357e8
treeb64a76617aa53d20358692cac58d482cb899e1a2
parent2b8463047a71e40e86233b7f35698f478350986f
Fix boot=on flag for CDROMs

This generalises commit 4304964a to cdroms too, since they have
somewhat the same logic. We just abstract the needs_boot_flag into a
separate variable, and then reuse it in the cdrom section.

Note that the logic of what 'if=' type to pass to KVM was very
convoluted, and (I think) incorrect; I went and cleaned it to be more
consistent.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>
lib/hypervisor/hv_kvm.py