Peter Maydell <peter.mayd...@linaro.org> writes: > On 9 June 2015 at 18:48, Peter Maydell <peter.mayd...@linaro.org> wrote: >> Patch 3 is the one-liner to change the default-drive-type. Unfortunately >> just doing that alone will break commandlines that currently work > > The other problem with taking patch 3 alone is that it completely > breaks everything, because: > * by default we create a "cdrom" drive whose type is <board-default> > and which has no media inserted > * the virtio-blk device barfs if you give it a drive with no media: > "Device needs media, but drive is empty" > > The S390 systems get around this by specifying no_cdrom = 1, but > it doesn't seem terribly satisfactory that this has to be manually > done by any machine with a virtio default drive type...
In my opinion, no_cdrom, no_parallel, no_floppy and no_sdcard are all daft. Flip their sense, and the chance of boards getting them right increases sharply. An explicit mc->use_cdrom = 1 in a machine initialization function for a board without a suitable controller sticks out and gets fixed. A missing mc->use_cdrom = 1 for a board with a suitable controller annoys users and gets fixed.