migration/ram: Add check and info message to nvdimm post copy.
The nvdimm kind memory does not support post copy now. We disable post copy if we have nvdimm memory and print some log hint to user. Signed-off-by: Junyan He <junyan.he@intel.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
faf8a13d80
commit
469dd51bc6
@ -3906,6 +3906,15 @@ static int ram_load(QEMUFile *f, void *opaque, int version_id)
|
||||
|
||||
static bool ram_has_postcopy(void *opaque)
|
||||
{
|
||||
RAMBlock *rb;
|
||||
RAMBLOCK_FOREACH_MIGRATABLE(rb) {
|
||||
if (ramblock_is_pmem(rb)) {
|
||||
info_report("Block: %s, host: %p is a nvdimm memory, postcopy"
|
||||
"is not supported now!", rb->idstr, rb->host);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return migrate_postcopy_ram();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user