Paolo Bonzini <pbonz...@redhat.com> writes: > On 24/03/2015 13:48, Markus Armbruster wrote: >> Use of -drive if=floppy with onboard pc87312 (machine "prep") shouldn't >> be affected. Likewise for connecting onboard m25p80-generic derivatives >> with if=mtd drives, or onboard ssi-sd with if=sd. > > Exactly. > >> Weird usage similar to the one you caught in time for sdhci-pci (--drive >> if=sd --device sdhci-pci) would break. It's possible when the target >> has the device, and the machine type has a suitable bus. >> >> * pc87312 >> >> Depends on CONFIG_PC87312, set in {ppc,ppc64}-softmmu.mak. >> >> Requires an ISA bus. I believe "prep" is the only machine providing >> one. > > You can add one with -device i82378. Actually used in > tests/endianness-test.c, hence I guess supported.
Point taken. >> If Andreas agrees, I can set cannot_instantiate_with_device_add_yet >> for pc87312 now. > > Could do that, could also decide that "-device i82378 -device pc87312" > is a valid way to add all the legacy crap to a PCI machine. In which > case supporting "-drive if=floppy" is a weird feature but it's also hard > to call it a bug. > > The difference with other devices is that you can only add it once. > It's a big difference. $ qemu-system-ppc64 -M bamboo -S -device i82378 -device pc87312 -device pc87312 qemu-system-ppc64: -device pc87312: Property 'isa-parallel.chardev' can't take value 'parallel0', it's in use Aborted (core dumped) drive_get() & friends were designed for board code, and never meant for realize(). They got used it in a few, but that were honest mistakes. Attempting to promote mistakes into a design of sorts just to avoid the consequences of reverting the mistakes is not a bright idea. Especially not when it complicates our conventions for device models. People are confused enough about them as it is, without alternate ways to do stuff that only work in special circumstances. Let's not go there. I really can't see why we should tie ourselves into knots to avoid an incompatible change here. I seriously doubt anyone will notice if drop the mistaken automatic backend pickup so that "-drive if=floppy -device i82378 -device pc87312" no longer picks up the floppy. >> * ssi-sd >> >> I guess we want to document that --device ssi-sd will at some point >> cease to auto-connect to the next available if=sd drive and require >> the usual drive property instead. Okay? >> >> * m25p80-generic >> >> Document just like ssi-sd. > > Ack for these two. Boards can still hook -drive if={sd,mtd} to them, > but (hypothetical) users would have to switch to -drive if=none. Want me to add something to http://wiki.qemu.org/ChangeLog/2.3#Future_incompatible_changes ? [...]