public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Patrick Mochel <mochel@digitalimplant.org>
Cc: Pavel Machek <pavel@ucw.cz>,
	Nigel Cunningham <ncunningham@users.sourceforge.net>,
	Linux Kernel list <linux-kernel@vger.kernel.org>
Subject: Re: swsusp vs  pgdir
Date: Sat, 24 Jan 2004 12:03:02 +1100	[thread overview]
Message-ID: <1074906182.835.47.camel@gaston> (raw)
In-Reply-To: <Pine.LNX.4.50.0401230839420.11276-100000@monsoon.he.net>

On Sat, 2004-01-24 at 03:45, Patrick Mochel wrote:

> A new pgdir is allocated on resume that does not overlap with any pages
> being restored. See relocate_pagedir() in the code..

Looking at the code, this is not a real HW pgdir but rather the
page copy list specific to swsusp. AFAIK, the HW pgdir is copied over.

> We assume that the kernel version is the same, and therefore that the code
> and static data are in same locations in memory. So, even if the kernel
> page tables get overwritten, we can still access the pointer to the pgdir.

Yes, the pgdir is there, but 1) it's getting overwriten, so if it
doesn't contain the same large page mapping on old and new, we are
screwed and 2) if accessing the linear mapping (when copying pages)
require going one level deeper into the page tables, then we are
possibly screwed too since those will be partly overwriten and won't
ever be in a "sane" state until the full copy is done.

Note that I don't have that problem with my current PPC hacks, as I
disable the MMU for the copy :)

Ben.



      parent reply	other threads:[~2004-01-24  1:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-23  4:58 swsusp vs pgdir Benjamin Herrenschmidt
2004-01-23  7:34 ` Pavel Machek
2004-01-23  7:43   ` Benjamin Herrenschmidt
2004-01-23  7:54     ` Pavel Machek
2004-01-23  8:21       ` Benjamin Herrenschmidt
2004-01-23 16:03       ` Patrick Mochel
2004-01-23 16:10         ` Benjamin Herrenschmidt
2004-01-23 16:45           ` Patrick Mochel
2004-01-23 16:53             ` Pavel Machek
2004-01-23 17:04             ` Pavel Machek
2004-01-24  1:03             ` Benjamin Herrenschmidt [this message]

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=1074906182.835.47.camel@gaston \
    --to=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mochel@digitalimplant.org \
    --cc=ncunningham@users.sourceforge.net \
    --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