All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Tesarik <ptesarik@suse.cz>
To: Atsushi Kumagai <kumagai-atsushi@mxc.nes.nec.co.jp>
Cc: Petr Tesarik <ptesarik@suse.cz>, kexec@lists.infradead.org
Subject: [PATCH v2 1/3] Pass mmd pointer to __exclude_unnecessary_pages
Date: Fri,  4 Apr 2014 19:25:07 +0200	[thread overview]
Message-ID: <5bf492a576255fe25a1a84d6b8d105cb55c9bcec.1396632131.git.ptesarik@suse.cz> (raw)
In-Reply-To: <cover.1396632131.git.ptesarik@suse.cz>
In-Reply-To: <cover.1396632131.git.ptesarik@suse.cz>

Pass the mmd pointer itself instead of the individual fields, so additional
information can be kept in mem_map_data.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
---
 makedumpfile.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/makedumpfile.c b/makedumpfile.c
index 5e81cc5..81c687b 100644
--- a/makedumpfile.c
+++ b/makedumpfile.c
@@ -4658,9 +4658,11 @@ initialize_2nd_bitmap_cyclic(struct cycle *cycle)
 }
 
 int
-__exclude_unnecessary_pages(unsigned long mem_map,
-    unsigned long long pfn_start, unsigned long long pfn_end, struct cycle *cycle)
+__exclude_unnecessary_pages(struct mem_map_data *mmd, struct cycle *cycle)
 {
+	unsigned long mem_map = mmd->mem_map;
+	unsigned long long pfn_start = mmd->pfn_start;
+	unsigned long long pfn_end = mmd->pfn_end;
 	unsigned long long pfn, pfn_mm, maddr;
 	unsigned long long pfn_read_start, pfn_read_end, index_pg;
 	unsigned char page_cache[SIZE(page) * PGMM_CACHED];
@@ -4809,8 +4811,7 @@ exclude_unnecessary_pages(void)
 		if (mmd->mem_map == NOT_MEMMAP_ADDR)
 			continue;
 
-		if (!__exclude_unnecessary_pages(mmd->mem_map,
-						 mmd->pfn_start, mmd->pfn_end, NULL))
+		if (!__exclude_unnecessary_pages(mmd, NULL))
 			return FALSE;
 	}
 
@@ -4860,8 +4861,7 @@ exclude_unnecessary_pages_cyclic(struct cycle *cycle)
 
 			if (mmd->pfn_end >= cycle->start_pfn &&
 			    mmd->pfn_start <= cycle->end_pfn) {
-				if (!__exclude_unnecessary_pages(mmd->mem_map,
-								 mmd->pfn_start, mmd->pfn_end, cycle))
+				if (!__exclude_unnecessary_pages(mmd, cycle))
 					return FALSE;
 			}
 		}
-- 
1.8.4.5


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

  reply	other threads:[~2014-04-04 17:25 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-04 17:25 [PATCH v2 0/3] Generic multi-page exclusion Petr Tesarik
2014-04-04 17:25 ` Petr Tesarik [this message]
2014-04-04 17:25 ` [PATCH v2 2/3] Generic handling of multi-page exclusions Petr Tesarik
2014-04-08  1:49   ` HATAYAMA Daisuke
2014-04-08  6:54     ` Petr Tesarik
2014-04-08  8:19       ` HATAYAMA Daisuke
2014-04-08  9:00         ` Atsushi Kumagai
2014-04-09  7:27           ` HATAYAMA Daisuke
2014-04-15  4:18             ` Atsushi Kumagai
2014-04-15  8:27               ` HATAYAMA Daisuke
2014-04-15 10:06                 ` Atsushi Kumagai
2014-04-08 10:07         ` Petr Tesarik
2014-04-09  7:12           ` HATAYAMA Daisuke
2014-04-08  7:06     ` Atsushi Kumagai
2014-04-10 10:47       ` Petr Tesarik
2014-04-11  1:59         ` HATAYAMA Daisuke
2014-04-15  1:20           ` Atsushi Kumagai
2014-04-15  6:23             ` Petr Tesarik
2014-04-15  8:09             ` HATAYAMA Daisuke
2014-04-04 17:25 ` [PATCH v2 3/3] Get rid of overrun adjustments Petr Tesarik
2014-04-08  7:02 ` [PATCH v2 0/3] Generic multi-page exclusion Atsushi Kumagai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5bf492a576255fe25a1a84d6b8d105cb55c9bcec.1396632131.git.ptesarik@suse.cz \
    --to=ptesarik@suse.cz \
    --cc=kexec@lists.infradead.org \
    --cc=kumagai-atsushi@mxc.nes.nec.co.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.