qdev: Improve diagnostics for bad property values
commit6bf38816df80a3b50529119c5458b151b3e2c728
authorMarkus Armbruster <armbru@redhat.com>
Fri, 26 Feb 2010 14:50:50 +0000 (26 15:50 +0100)
committerAnthony Liguori <aliguori@us.ibm.com>
Tue, 9 Mar 2010 14:47:19 +0000 (9 08:47 -0600)
treee047c71c4770fd1bb0f440abe7bf1bdd1858dbee
parent573fb60c97721328f71b866c0561c6250d6cb25a
qdev: Improve diagnostics for bad property values

Property "vlan" reports "failed to parse" even when the value parses
just fine, but the result doesn't name an existing VLAN.

Similarly, properties "drive", "chr" and "netdev" misleadingly report
"failed to parse" when the value doesn't name an existing host device.

Change PropertyInfo method parse to return an error code, so that
qdev_prop_parse() can report the error more accurately.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw/qdev-properties.c