There is no need to scrub pages freed during dom0 construction
since heap will be scrubbed once dom0 is ready (by scrub_heap_pages()).

Since boot_scrub_done will not be set if boot-time scrubbing is off we
also check for domain state.

Signed-off-by: Boris Ostrovsky <boris.ostrov...@oracle.com>
---
 xen/common/page_alloc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/common/page_alloc.c b/xen/common/page_alloc.c
index 34a7992..b93dae9 100644
--- a/xen/common/page_alloc.c
+++ b/xen/common/page_alloc.c
@@ -2259,7 +2259,7 @@ void free_domheap_pages(struct page_info *pg, unsigned 
int order)
              */
             scrub = !!d->is_dying;
 #else
-            scrub = true;
+            scrub = boot_scrub_done || !!d->is_dying;
 #endif
         }
         else
-- 
1.8.3.1


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

Reply via email to