mbox series

[kvmtool,v1,0/2] Align value generated by get_ram_size() to the host's page size

Message ID 20230717102300.3092062-1-tabba@google.com (mailing list archive)
Headers show
Series Align value generated by get_ram_size() to the host's page size | expand

Message

Fuad Tabba July 17, 2023, 10:22 a.m. UTC
Hi,

This short patch series ensures that the value returned by
get_ram_size() is aligned to the host's page size. Without that,
KVM_SET_USER_MEMORY_REGION could fail when passed an unaligned
value.

Cheers,
/fuad

Fixes: 18bd8c3bd2a7 ("kvm tools: Don't use all of host RAM for guests by default")
Signed-off-by: Fuad Tabba <tabba@google.com>

Fuad Tabba (2):
  Factor out getting the host page size
  Align the calculated guest ram size to the host's page size

 builtin-run.c | 22 ++++++++++++++--------
 1 file changed, 14 insertions(+), 8 deletions(-)


base-commit: bd4ba57156dad39349edfb2338bdc2f4ed3c0bae