70b6d525df
Since 5.0 QEMU uses hostmem backend for allocating main guest RAM. The backend however calls mbind() which is typically NOP in case of default policy/absent host-nodes bitmap. However when runing in container with black-listed mbind() syscall, QEMU fails to start with error "cannot bind memory to host NUMA nodes: Operation not permitted" even when user hasn't provided host-nodes to pin to explictly (which is the case with -m option) To fix issue, call mbind() only in case when user has provided host-nodes explicitly (i.e. host_nodes bitmap is not empty). That should allow to run QEMU in containers with black-listed mbind() without memory pinning. If QEMU provided memory-pinning is required user still has to white-list mbind() in container configuration. Reported-by: Manuel Hohmann <mhohmann@physnet.uni-hamburg.de> Signed-off-by: Igor Mammedov <imammedo@redhat.com> Message-Id: <20200430154606.6421-1-imammedo@redhat.com> Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com> Cc: qemu-stable@nongnu.org Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> |
||
---|---|---|
.. | ||
cryptodev-builtin.c | ||
cryptodev-vhost-user.c | ||
cryptodev-vhost.c | ||
cryptodev.c | ||
dbus-vmstate.c | ||
hostmem-file.c | ||
hostmem-memfd.c | ||
hostmem-ram.c | ||
hostmem.c | ||
Makefile.objs | ||
rng-builtin.c | ||
rng-egd.c | ||
rng-random.c | ||
rng.c | ||
tpm.c | ||
trace-events | ||
vhost-user.c |