* [Qemu-devel] [PULL 0/1] NUMA fix for -rc2
@ 2015-11-23 12:46 Eduardo Habkost
2015-11-23 12:46 ` [Qemu-devel] [PULL 1/1] hostmem: Ignore ENOSYS while setting MPOL_DEFAULT Eduardo Habkost
2015-11-23 17:03 ` [Qemu-devel] [PULL 0/1] NUMA fix for -rc2 Peter Maydell
0 siblings, 2 replies; 3+ messages in thread
From: Eduardo Habkost @ 2015-11-23 12:46 UTC (permalink / raw)
To: Peter Maydell; +Cc: Paolo Bonzini, qemu-devel
(I forgot to submit a pull request for this earlier, sorry.)
The following changes since commit 541abd10a01da56c5f16582cd32d67114ec22a5c:
Update version for v2.5.0-rc1 release (2015-11-20 17:43:46 +0000)
are available in the git repository at:
git://github.com/ehabkost/qemu.git tags/numa-pull-request
for you to fetch changes up to a3567ba1e6171ef7cfad55ae549c0cd8bffb1195:
hostmem: Ignore ENOSYS while setting MPOL_DEFAULT (2015-11-23 10:43:38 -0200)
----------------------------------------------------------------
NUMA fix for -rc2
----------------------------------------------------------------
Pavel Fedin (1):
hostmem: Ignore ENOSYS while setting MPOL_DEFAULT
backends/hostmem.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
--
2.1.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Qemu-devel] [PULL 1/1] hostmem: Ignore ENOSYS while setting MPOL_DEFAULT
2015-11-23 12:46 [Qemu-devel] [PULL 0/1] NUMA fix for -rc2 Eduardo Habkost
@ 2015-11-23 12:46 ` Eduardo Habkost
2015-11-23 17:03 ` [Qemu-devel] [PULL 0/1] NUMA fix for -rc2 Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Eduardo Habkost @ 2015-11-23 12:46 UTC (permalink / raw)
To: Peter Maydell; +Cc: Paolo Bonzini, Pavel Fedin, qemu-devel
From: Pavel Fedin <p.fedin@samsung.com>
Currently hostmem backend fails if CONFIG_NUMA is enabled in QEMU
(the default) but NUMA is not supported by the kernel. This makes
it impossible to use ivshmem in such configurations.
This patch fixes the problem by ignoring ENOSYS error if policy is set to
MPOL_DEFAULT. This way the code behaves in the same way as if CONFIG_NUMA
was not defined. qemu will still fail if the user specifies some other
policy, so that the user knows it.
Signed-off-by: Pavel Fedin <p.fedin@samsung.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
backends/hostmem.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/backends/hostmem.c b/backends/hostmem.c
index 41ba2af..1b4eb45 100644
--- a/backends/hostmem.c
+++ b/backends/hostmem.c
@@ -313,9 +313,11 @@ host_memory_backend_memory_complete(UserCreatable *uc, Error **errp)
assert(maxnode <= MAX_NODES);
if (mbind(ptr, sz, backend->policy,
maxnode ? backend->host_nodes : NULL, maxnode + 1, flags)) {
- error_setg_errno(errp, errno,
- "cannot bind memory to host NUMA nodes");
- return;
+ if (backend->policy != MPOL_DEFAULT || errno != ENOSYS) {
+ error_setg_errno(errp, errno,
+ "cannot bind memory to host NUMA nodes");
+ return;
+ }
}
#endif
/* Preallocate memory after the NUMA policy has been instantiated.
--
2.1.0
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [Qemu-devel] [PULL 0/1] NUMA fix for -rc2
2015-11-23 12:46 [Qemu-devel] [PULL 0/1] NUMA fix for -rc2 Eduardo Habkost
2015-11-23 12:46 ` [Qemu-devel] [PULL 1/1] hostmem: Ignore ENOSYS while setting MPOL_DEFAULT Eduardo Habkost
@ 2015-11-23 17:03 ` Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2015-11-23 17:03 UTC (permalink / raw)
To: Eduardo Habkost; +Cc: Paolo Bonzini, QEMU Developers
On 23 November 2015 at 12:46, Eduardo Habkost <ehabkost@redhat.com> wrote:
> (I forgot to submit a pull request for this earlier, sorry.)
>
> The following changes since commit 541abd10a01da56c5f16582cd32d67114ec22a5c:
>
> Update version for v2.5.0-rc1 release (2015-11-20 17:43:46 +0000)
>
> are available in the git repository at:
>
> git://github.com/ehabkost/qemu.git tags/numa-pull-request
>
> for you to fetch changes up to a3567ba1e6171ef7cfad55ae549c0cd8bffb1195:
>
> hostmem: Ignore ENOSYS while setting MPOL_DEFAULT (2015-11-23 10:43:38 -0200)
>
> ----------------------------------------------------------------
> NUMA fix for -rc2
>
> ----------------------------------------------------------------
>
> Pavel Fedin (1):
> hostmem: Ignore ENOSYS while setting MPOL_DEFAULT
Applied, thanks.
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-11-23 17:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-23 12:46 [Qemu-devel] [PULL 0/1] NUMA fix for -rc2 Eduardo Habkost
2015-11-23 12:46 ` [Qemu-devel] [PULL 1/1] hostmem: Ignore ENOSYS while setting MPOL_DEFAULT Eduardo Habkost
2015-11-23 17:03 ` [Qemu-devel] [PULL 0/1] NUMA fix for -rc2 Peter Maydell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).