提交 068add8e 编写于 作者: J Jiri Denemark

Remove artificial minimum limit for guest memory

Remove the artificial minimum of 4096 KB for guest memory. It's drivers'
job to set the limit if needed.
上级 41461ff7
...@@ -2738,7 +2738,7 @@ virDomainSetMaxMemory(virDomainPtr domain, unsigned long memory) ...@@ -2738,7 +2738,7 @@ virDomainSetMaxMemory(virDomainPtr domain, unsigned long memory)
virLibDomainError(VIR_ERR_OPERATION_DENIED, __FUNCTION__); virLibDomainError(VIR_ERR_OPERATION_DENIED, __FUNCTION__);
goto error; goto error;
} }
if (memory < 4096) { if (!memory) {
virLibDomainError(VIR_ERR_INVALID_ARG, __FUNCTION__); virLibDomainError(VIR_ERR_INVALID_ARG, __FUNCTION__);
goto error; goto error;
} }
...@@ -2792,7 +2792,7 @@ virDomainSetMemory(virDomainPtr domain, unsigned long memory) ...@@ -2792,7 +2792,7 @@ virDomainSetMemory(virDomainPtr domain, unsigned long memory)
virLibDomainError(VIR_ERR_OPERATION_DENIED, __FUNCTION__); virLibDomainError(VIR_ERR_OPERATION_DENIED, __FUNCTION__);
goto error; goto error;
} }
if (memory < 4096) { if (!memory) {
virLibDomainError(VIR_ERR_INVALID_ARG, __FUNCTION__); virLibDomainError(VIR_ERR_INVALID_ARG, __FUNCTION__);
goto error; goto error;
} }
...@@ -2861,7 +2861,7 @@ virDomainSetMemoryFlags(virDomainPtr domain, unsigned long memory, ...@@ -2861,7 +2861,7 @@ virDomainSetMemoryFlags(virDomainPtr domain, unsigned long memory,
goto error; goto error;
} }
if (memory < 4096) { if (!memory) {
virLibDomainError(VIR_ERR_INVALID_ARG, __FUNCTION__); virLibDomainError(VIR_ERR_INVALID_ARG, __FUNCTION__);
goto error; goto error;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册