> Am 24.10.2016 um 13:44 schrieb Igor Mammedov <imamm...@redhat.com>: > >> >> modified exec.c >> @@ -1254,7 +1254,11 @@ static void *file_ram_alloc(RAMBlock *block, >> } >> >> block->page_size = qemu_fd_getpagesize(fd); >> +#if defined(__x86_64__) || defined(__i386__) >> + block->mr->align = block->page_size; >> +#else >> block->mr->align = MAX(block->page_size, QEMU_VMALLOC_ALIGN); > maybe it's worth to do other way around i.e. for special s390 case > do above and for the rest leave page_size alignment? >
That should work, now the question would be why on x86 file backed memory allocations differ to anonymous allocations? On s390 all allocations used for KVM should be aligned on a segment basis. > SPAPR supports mem hotplug so it's also affected As power does not specialize QEMU_VMALLOC_ALIGN it shouldn’t be affected. Thanks, Dominik