mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 10:40:03 +01:00
xenpaging: start paging in the middle of gfn range
Set the starting gfn to somewhere in the middle of the gfn range to avoid paging during BIOS startup. This can speedup booting of a guest. Signed-off-by: Olaf Hering <olaf@aepfle.de> Committed-by: Ian Jackson <ian.jackson.citrix.com>
This commit is contained in:
1 parent
fd1b11466e
commit
46a3d35ca3
1 file changed
+4
@@ -69,6 +69,10 @@ int policy_init(xenpaging_t *paging)
|
||||
/* Don't page out page 0 */
|
||||
set_bit(0, bitmap);
|
||||
|
||||
/* Start in the middle to avoid paging during BIOS startup */
|
||||
current_gfn = max_pages / 2;
|
||||
current_gfn -= paging->num_pages / 2;
|
||||
|
||||
rc = 0;
|
||||
out:
|
||||
return rc;
|
||||
|
||||