ide: Reject readonly drives unless CD-ROM
drive_init() doesn't permit option readonly for if=ide, but that'sworthless: we get it via if=none and -device.
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Add virtio disk identification support
This patch adds the final missing bits for support ofpassing a serial/id string to a virtio-blk guest driver.
The guest-side component already exists in the virtiodriver, and has recently been reworked by Ryan to export...
fdc: Reject unimplemented error actions
drive_init() doesn't permit them for if=floppy, but that's worthless:we get them via if=none and -global.
This can make device initialization fail. Since all callers offdctrl_init_isa() ignore its value, change it to die instead of...
qdev: Don't hw_error() in qdev_init_nofail()
Some of the failures are internal errors, and hw_error() is okay then.But the common way to fail is bad user input, e.g. -globalisa-fdc.driveA=foo where drive foo has an unsupported rerror value.
exit(1) instead....
scsi: Reject unimplemented error actions
drive_init() doesn't permit rerror for if=scsi, but that's worthless:we get it via if=none and -device.
Moreover, scsi-generic doesn't support werror. Since drive_init()doesn't catch that, option werror was silently ignored even with...
scsi: Error locations for -drive if=scsi device initialization
ide: Improve error messages
Use error_report(), because it points to the error location.
Reword "tried to assign twice" messages to make it clear that we'recomplaining about the unit property.
Report invalid unit property instead of failing silently....
ide: Replace IDEState members is_cdrom, is_cf by drive_kind
The two aren't independent variables. Make that obvious.
ide: Make ide_init_drive() return success
It still always succeeds. The next commits will add failures.
Merge remote branch 'kwolf/for-anthony' into staging
View revisions
Also available in: Atom