qdev: accept hex properties only if prefixed by 0x
commit97aa6e9b8f9df37add21d86fac1a9ca6ce7df9b7
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 9 Feb 2012 09:07:38 +0000 (9 10:07 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 22 Feb 2012 07:31:24 +0000 (22 08:31 +0100)
tree570727fedc786739c2a89fc3e3ab5ec5704b309a
parent768a9ebe188bd0a6172a9a4e64777d21fff7f014
qdev: accept hex properties only if prefixed by 0x

Hex properties are an obstacle to removal of old qdev string parsing, but
even here we can lay down the foundations for future simplification.  In
general, they are rarely used and their printed form is more interesting
than the parsing.  For example you'd usually set isa-serial.index
instead of isa-serial.iobase.  And luckily our main client, libvirt
only cares about few of these, and always sets them with a 0x prefix.
So the series stops accepting bare hexadecimal numbers, preparing for
making legacy properties read-only in 1.3 or so.  The read side will
stay as long as "info qtree" is with us.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
hw/qdev-properties.c