* [Qemu-devel] [PATCH 1/1] hostmem-file: remove the invalid pmem object id.
[not found] <cover.1540389255.git.yi.z.zhang@linux.intel.com>
@ 2018-10-24 14:14 ` Zhang Yi
2018-10-26 15:40 ` Eduardo Habkost
0 siblings, 1 reply; 2+ messages in thread
From: Zhang Yi @ 2018-10-24 14:14 UTC (permalink / raw)
To: mst, peter.maydell, yu.c.zhang, ehabkost, imammedo
Cc: qemu-devel, pbonzini, stefanha, crosthwaite.peter,
richard.henderson, xiaoguangrong.eric, Zhang Yi
We will never get the canonical path from the object
before object_property_add_child.
Signed-off-by: Zhang Yi <yi.z.zhang@linux.intel.com>
---
backends/hostmem-file.c | 14 ++++----------
1 file changed, 4 insertions(+), 10 deletions(-)
diff --git a/backends/hostmem-file.c b/backends/hostmem-file.c
index 639c8d4..9691c48 100644
--- a/backends/hostmem-file.c
+++ b/backends/hostmem-file.c
@@ -145,26 +145,20 @@ static void file_memory_backend_set_pmem(Object *o, bool value, Error **errp)
HostMemoryBackendFile *fb = MEMORY_BACKEND_FILE(o);
if (host_memory_backend_mr_inited(backend)) {
- char *path = object_get_canonical_path_component(o);
- error_setg(errp, "cannot change property 'pmem' of %s '%s'",
- object_get_typename(o),
- path);
- g_free(path);
+ error_setg(errp, "cannot change property 'pmem' of %s.",
+ object_get_typename(o));
return;
}
#ifndef CONFIG_LIBPMEM
if (value) {
Error *local_err = NULL;
- char *path = object_get_canonical_path_component(o);
error_setg(&local_err,
"Lack of libpmem support while setting the 'pmem=on'"
- " of %s '%s'. We can't ensure data persistence.",
- object_get_typename(o),
- path);
- g_free(path);
+ " of %s. We can't ensure data persistence.",
+ object_get_typename(o));
error_propagate(errp, local_err);
return;
}
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH 1/1] hostmem-file: remove the invalid pmem object id.
2018-10-24 14:14 ` [Qemu-devel] [PATCH 1/1] hostmem-file: remove the invalid pmem object id Zhang Yi
@ 2018-10-26 15:40 ` Eduardo Habkost
0 siblings, 0 replies; 2+ messages in thread
From: Eduardo Habkost @ 2018-10-26 15:40 UTC (permalink / raw)
To: Zhang Yi
Cc: mst, peter.maydell, yu.c.zhang, imammedo, qemu-devel, pbonzini,
stefanha, crosthwaite.peter, richard.henderson,
xiaoguangrong.eric
On Wed, Oct 24, 2018 at 10:14:56PM +0800, Zhang Yi wrote:
> We will never get the canonical path from the object
> before object_property_add_child.
>
> Signed-off-by: Zhang Yi <yi.z.zhang@linux.intel.com>
Thanks. I'm queueing it on machine-next, after rewriting the
subject line as:
hostmem-file: remove object id from pmem error message
--
Eduardo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-10-26 15:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <cover.1540389255.git.yi.z.zhang@linux.intel.com>
2018-10-24 14:14 ` [Qemu-devel] [PATCH 1/1] hostmem-file: remove the invalid pmem object id Zhang Yi
2018-10-26 15:40 ` Eduardo Habkost
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).