On 12/05/2017 03:54 PM, Eric Blake wrote: > On 12/05/2017 06:05 AM, Halil Pasic wrote: > >> Good catch! Regarding omitting the machine name, I was surprised that >> it works, but it does. Our documentation is a bit strange on this: we >> document the machine name as non-optional: >> "-machine [type=]name[,prop=value[,...]]" >> but then use -machine prop=value in the deprecation section (that's >> with no name). > > QemuOpts at their "finest". If it sees the first hunk as a value > without an =, then that value is fed to type=name; but you are also free > to make the first hunk be an explicit name=value (whether type=name or > prop=value), at which point it is up to the backend whether type can be > omitted. So in this case, '-machine prop=value' manages to work just > fine, and it's a question of how you would convey that information in > the --help documentation. >
I would have spontaneously said something like -machine [[type=]name | prop=value][,prop=value,[,...]] It is kind of complicated and it does not precisely reflect what is possible (one can specify the machine multiple times, and it does not have to be a prefix of the list for example) but that ain't necessarily a problem. I'm not saying we should change this. I just wanted to say: wow, this was new to me. >> >> Since the documentation doesn't make it clear that the property is >> existent only for the s390-ccw-virtio family of the machines I think >> being your suggestion has a lot of charm. @Connie: do you agree to >> removing the machine name (type)? >>
signature.asc
Description: OpenPGP digital signature