diff mbox series

[11/20] tpm_util: Remove unnecessary prefix from error message

Message ID 20201030202131.796967-12-ehabkost@redhat.com
State New
Headers show
Series qdev/qom: Remove explicit type names from error_setg() calls | expand

Commit Message

Eduardo Habkost Oct. 30, 2020, 8:21 p.m. UTC
object_property_parse() will add a
  "Property '<TYPE>.<PROP>' can't take value '<VALUE>'"
prefix automatically for us.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
Cc: Stefan Berger <stefanb@linux.vnet.ibm.com>
Cc: qemu-devel@nongnu.org
---
 backends/tpm/tpm_util.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/backends/tpm/tpm_util.c b/backends/tpm/tpm_util.c
index 2b5f788861..012c71bc53 100644
--- a/backends/tpm/tpm_util.c
+++ b/backends/tpm/tpm_util.c
@@ -56,8 +56,7 @@  static void set_tpm(Object *obj, Visitor *v, const char *name, void *opaque,
 
     s = qemu_find_tpm_be(str);
     if (s == NULL) {
-        error_setg(errp, "Property '%s.%s' can't find value '%s'",
-                   object_get_typename(obj), prop->name, str);
+        error_setg(errp, "tpm backend not found");
     } else if (tpm_backend_init(s, TPM_IF(obj), errp) == 0) {
         *be = s; /* weak reference, avoid cyclic ref */
     }