From: Atsushi Kumagai <[email protected]>
Date: Fri, 24 Aug 2012 10:16:52 +0900
Subject: [PATCH 11/16] [PATCH v3 11/12] Remove waste calculation to improve 
performance.

This patch adds check whether each page correspond to target memory
region or not into filtering logic.

Signed-off-by: Atsushi Kumagai <[email protected]>
---
 makedumpfile.c |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/makedumpfile.c b/makedumpfile.c
index cc90d39..879f73a 100644
--- a/makedumpfile.c
+++ b/makedumpfile.c
@@ -3751,6 +3751,12 @@ __exclude_unnecessary_pages(unsigned long mem_map,
        for (pfn = pfn_start; pfn < pfn_end; pfn++, mem_map += SIZE(page)) {
 
                /*
+                * If this pfn doesn't belong to target region, skip this pfn.
+                */
+               if (info->flag_cyclic && !is_cyclic_region(pfn))
+                       continue;
+
+               /*
                 * Exclude the memory hole.
                 */
                if (is_xen_memory()) {
-- 
1.7.9.2

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec

Reply via email to