From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Pavel Machek <pavel@ucw.cz>
Cc: Andy Isaacson <adi@hexapodia.org>, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH][mm][Fix] swsusp: fix counting of highmem pages
Date: Sun, 4 Dec 2005 01:26:13 +0100 [thread overview]
Message-ID: <200512040126.14048.rjw@sisk.pl> (raw)
In-Reply-To: <20051204001055.GE5198@elf.ucw.cz>
Hi,
On Sunday, 4 of December 2005 01:10, Pavel Machek wrote:
> > > Ah, okay, I see. As long as the include hack is gone, its okay with me.
> >
> > All right. Appended is the latest version.
>
> Okay, seems I'll need to get latest mm version, because this changed a
> lot. Sorry, that will be tommorow afternoon.
OK
> > Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
> >
> > kernel/power/snapshot.c | 25 ++++++++++++++++++-------
> > kernel/power/swsusp.c | 3 ++-
> > 2 files changed, 20 insertions(+), 8 deletions(-)
> >
> > Index: linux-2.6.15-rc3-mm1/kernel/power/snapshot.c
> > ===================================================================
> > --- linux-2.6.15-rc3-mm1.orig/kernel/power/snapshot.c 2005-12-03 00:14:49.000000000 +0100
> > +++ linux-2.6.15-rc3-mm1/kernel/power/snapshot.c 2005-12-04 00:35:14.000000000 +0100
> > @@ -37,6 +37,12 @@
> > @@ -52,13 +58,12 @@
> > if (!pfn_valid(pfn))
> > continue;
> > page = pfn_to_page(pfn);
> > - if (PageReserved(page))
> > - continue;
> > - if (PageNosaveFree(page))
> > - continue;
> > - n++;
> > + if (!PageNosaveFree(page) && !PageReserved(page))
> > + n++;
> > }
>
> As far as I can see, this does not change anything. Can you keep it
> out?
OK
> > }
> > + if (n > 0)
> > + n += (n * KMALLOC_SIZE + PAGE_SIZE - 1) / PAGE_SIZE + 1;
> > return n;
> > }
>
> Can't you just n += n/50 here? Playing with KMALLOC_SIZE knows way too
> much about memory allocation details.
I do the "n + n/50" later on, so I can just drop all of the above changes
if they are too complicated.
Greetings,
Rafael
next prev parent reply other threads:[~2005-12-04 0:25 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-03 20:40 Rafael J. Wysocki
2005-12-03 21:40 ` Pavel Machek
2005-12-03 23:11 ` Rafael J. Wysocki
2005-12-03 23:50 ` Pavel Machek
2005-12-04 0:02 ` Rafael J. Wysocki
2005-12-04 0:10 ` Pavel Machek
2005-12-04 0:26 ` Rafael J. Wysocki [this message]
2005-12-04 0:35 ` Pavel Machek
2005-12-04 0:57 ` Rafael J. Wysocki
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=200512040126.14048.rjw@sisk.pl \
--to=rjw@sisk.pl \
--cc=adi@hexapodia.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®