From: Pavel Machek <pavel@ucw.cz>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Andrew Morton <akpm@osdl.org>,
kernel list <linux-kernel@vger.kernel.org>
Subject: Re: [swsusp] separate snapshot functionality to separate file
Date: Tue, 4 Oct 2005 01:17:15 +0200 [thread overview]
Message-ID: <20051003231715.GA17458@elf.ucw.cz> (raw)
In-Reply-To: <200510032339.08217.rjw@sisk.pl>
Hi!
> > Split swsusp.c into swsusp.c and snapshot.c. Snapshot only cares
> > provides system snapshot/restore functionality, while swsusp.c will
> > provide disk i/o. It should enable untangling of the code in future;
> > swsusp.c parts can mostly be done in userspace.
> >
> > No code changes.
>
> I think that the functions:
>
> read_suspend_image()
> read_pagedir()
> swsusp_pagedir_relocate() (BTW, why there's "swsusp_"?)
> check_pagedir() (BTW, misleading name)
> data_read()
> eat_page()
> get_usable_page()
> free_eaten_memory()
>
> should be moved to snapshot.c as well, because they are in fact
> symmetrical to what's there (they perform the reverse of creating
> the snapshot and use analogous data structures). IMO the code
> change required would not be so drammatic and all of the functions
> that _operate_ on the snapshot would be in the same file.
No. read_suspend_image/read_pagedir/data_read is image reading. That
does not belong to snaphost. The rest is notthat clear, but I have it
working in userspace.
Image creation is still done in kernel space, but I think that kernel
<-> user interface is going to be cleaner that way, and I do not think
pushing it to user is so huge win.
Yes, names are not ideal, but that will be followup patch.
Pavel
--
if you have sharp zaurus hardware you don't need... you know my address
next prev parent reply other threads:[~2005-10-03 23:17 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-02 23:13 [swsusp] separate snapshot functionality to separate file Pavel Machek
2005-10-03 21:39 ` Rafael J. Wysocki
2005-10-03 23:17 ` Pavel Machek [this message]
2005-10-04 15:11 ` Rafael J. Wysocki
2005-10-04 20:53 ` Pavel Machek
2005-10-04 22:34 ` Nigel Cunningham
2005-10-05 8:41 ` Pavel Machek
2005-10-05 21:21 ` Lorenzo Colitti
2005-10-05 22:21 ` Nigel Cunningham
2005-10-05 22:44 ` Pavel Machek
2005-10-05 22:54 ` Lorenzo Colitti
2005-10-05 22:57 ` Pavel Machek
2005-10-05 23:00 ` Pavel Machek
2005-10-05 23:18 ` Lorenzo Colitti
2005-10-06 10:10 ` Alon Bar-Lev
2005-10-06 8:20 ` Pavel Machek
2005-10-09 23:41 ` Nigel Cunningham
2005-10-04 22:47 ` Rafael J. Wysocki
2005-10-05 0:06 ` Pavel Machek
2005-10-05 8:20 ` Rafael J. Wysocki
2005-10-05 8:33 ` Pavel Machek
2005-10-06 8:23 ` Rafael J. Wysocki
2005-10-06 10:42 ` Pavel Machek
2005-10-06 13:29 ` 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=20051003231715.GA17458@elf.ucw.cz \
--to=pavel@ucw.cz \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rjw@sisk.pl \
/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