@@ -104,15 +104,10 @@ static uint64_t memory_device_get_free_addr(MachineState *ms,
GSList *list = NULL, *item;
Range as, new = range_empty;
- if (!ms->device_memory) {
- error_setg(errp, "memory devices (e.g. for memory hotplug) are not "
- "supported by the machine");
- return 0;
- }
-
- if (!memory_region_size(&ms->device_memory->mr)) {
- error_setg(errp, "memory devices (e.g. for memory hotplug) are not "
- "enabled, please specify the maxmem option");
+ if (!ms->device_memory || !memory_region_size(&ms->device_memory->mr)) {
+ error_setg(errp, "the configuration is not prepared for memory devices"
+ " (e.g., for memory hotplug), consider specifying the"
+ " maxmem option");
return 0;
}
range_init_nofail(&as, ms->device_memory->base,