Paolo Bonzini <pbonz...@redhat.com> writes: > Il 20/02/2014 17:02, Andreas Färber ha scritto: >> Not unexpected, it's the older; the - convention was introduced possibly >> with QOM around start of 2012. Or at least there it's been enforced, and
QMP preferred '-' from the start, but insufficient decoupling from command line and HMP let in many '_', and the bad examples then got copied around, as usual. >> by my understanding of QOM and QMP visibility it then applies to devices >> as well. >> >> Regarding QMP, I consider it smarter to do the _ -> - matching at >> QemuOpts level than somewhere inside QOM. > > That's fine, because device_add uses QemuOpts internally. > >> For -cpu we have such compatibility code (although non-QemuOpts) in >> target-i386/cpu.c, converting all underscores. Unfortunately that won't >> work as long as there are underscores in old properties. Maybe you have >> some cool patch idea? > > Well, no cool idea except "once conversion is done at the QemuOpts > level, do a full sweep of s/_/-/". Required anyway, to get the help texts consistent, and to get rid of the bad examples. > This should be done before we'll > be able to create devices with object-add. I think as long as we have > a plan, consistency trumps design-by-committee convention.