- * Afterward, when the VM is migrated or suspended or whatever, the process will have the corresponding handling, too.
+ */
+msg_vm_t MSG_vm_create(msg_host_t ind_pm, const char *name,
+ int core_nb, int mem_cap, int net_cap, char *disk_path, int disk_size)
+{
+ msg_vm_t vm = MSG_vm_create_core(ind_pm, name);
+
+ MSG_vm_set_property_value(vm, "CORE_NB", bprintf("%d", core_nb), free);
+ MSG_vm_set_property_value(vm, "MEM_CAP", bprintf("%d", mem_cap), free);
+ MSG_vm_set_property_value(vm, "NET_CAP", bprintf("%d", net_cap), free);
+
+ /* TODO: We will revisit the disk support later. */
+
+ return vm;
+}
+
+
+/** @brief Create a new VM object. The VM is not yet started. The resource of the VM is allocated upon MSG_vm_start().
+ * @ingroup msg_VMs*