libxc: remove stale error check for domain size in xc_sr_save_x86_hvm.c
authorJuergen Gross <jgross@suse.com>
Tue, 26 Sep 2017 12:02:56 +0000 (14:02 +0200)
committerWei Liu <wei.liu2@citrix.com>
Fri, 27 Oct 2017 11:03:04 +0000 (12:03 +0100)
commit26a896cde21c6d03de367190034fcc150b1bf2d8
tree35ace8fb15ea026da20f4ea21ff7e8db04136531
parent1abaf4f1fe5e106b2578c1df3a13e77170a885cc
libxc: remove stale error check for domain size in xc_sr_save_x86_hvm.c

Long ago domains to be saved were limited to 1TB size due to the
migration stream v1 limitations which used a 32 bit value for the
PFN and the frame type (4 bits) leaving only 28 bits for the PFN.

Migration stream V2 uses a 64 bit value for this purpose, so there
is no need to refuse saving (or migrating) domains larger than 1 TB.

For 32 bit toolstacks there is still a size limit, as domains larger
than about 1TB will lead to an exhausted virtual address space of the
saving process. So keep the test for 32 bit, but don't base it on the
page type macros. As a migration could lead to the situation where a
32 bit toolstack would have to handle such a large domain (in case the
sending side is 64 bit) the same test should be added for restoring a
domain.

Signed-off-by: Juergen Gross <jgross@suse.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
Release-acked-by: Julien Grall <julien.grall@linaro.org>
tools/libxc/xc_sr_restore_x86_hvm.c
tools/libxc/xc_sr_save_x86_hvm.c