Report the values when a comparison fails; together with
the previous patch that prints the device and field names
this should give a good idea of why loading the migration failed.
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
if (*v == v2) {
return 0;
}
+ error_report("%" PRIx32 " != %" PRIx32, *v, v2);
return -EINVAL;
}
*cur = loaded;
return 0;
}
+ error_report("Invalid value %" PRId32
+ " expecting positive value <= %" PRId32,
+ loaded, *cur);
return -EINVAL;
}
if (*v == v2) {
return 0;
}
+ error_report("%" PRIx32 " != %" PRIx32, *v, v2);
return -EINVAL;
}
if (*v == v2) {
return 0;
}
+ error_report("%" PRIx64 " != %" PRIx64, *v, v2);
return -EINVAL;
}
if (*v == v2) {
return 0;
}
+ error_report("%x != %x", *v, v2);
return -EINVAL;
}
if (*v == v2) {
return 0;
}
+ error_report("%x != %x", *v, v2);
return -EINVAL;
}