public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Pavel Machek <pavel@ucw.cz>
Cc: kernel list <linux-kernel@vger.kernel.org>, Andi Kleen <ak@muc.de>
Subject: Re: [PATCH][Fix] Prevent swsusp from corrupting page translation tables during resume on x86-64
Date: Mon, 26 Sep 2005 12:46:18 +0200	[thread overview]
Message-ID: <200509261246.19085.rjw@sisk.pl> (raw)
In-Reply-To: <20050925220738.GF2775@elf.ucw.cz>

Hi,

On Monday, 26 of September 2005 00:07, Pavel Machek wrote:
> Hi!
> 
> > The following patch fixes Bug #4959.  It creates temporary page translation
> > tables located in the page frames that are not overwritten by swsusp while copying
> > the image.
> > 
> > The temporary page translation tables are generally based on the existing ones
> > with the exception that the mappings using 4KB pages are replaced with the
> > equivalent mappings that use 2MB pages only.  The temporary page tables are
> > only used for copying the image.
> 
> Would not it be simpler to create them from scratch? mm/init.c has
> some handy functions, they should be applicable. [init_memory_mapping,
> phys_pud_init]. Perhaps even initialize only simple direct mapping,
> and place virt_to_phys() at strategic places?

Perhaps, but the outcome would be very much the same.  The problem is to what
extent we can use the existing constructs, because I'd rather like to avoid the situation
in which any future changes to the initialization code would have to be replicated
in the swsusp code.  I'll have a look at that, but I'm not sure.  Also I don't really know
what the Andi's preferences are with this respect.

Anyway do you think that creating temporary page tables at the beginning of
swsusp_arch_resume() is a good idea?  If not, where do you think should they be
created?

Greetings,
Rafael

  reply	other threads:[~2005-09-26 10:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-24 17:36 [PATCH][Fix] Prevent swsusp from corrupting page translation tables during resume on x86-64 Rafael J. Wysocki
2005-09-25 22:07 ` Pavel Machek
2005-09-26 10:46   ` Rafael J. Wysocki [this message]
2005-09-26 10:49     ` Pavel Machek
2005-09-27  8:07 ` [PATCH][Fix] Fix Bug #4959 (take 2) Rafael J. Wysocki
2005-09-27 13:32   ` Pavel Machek
2005-09-27 21:00     ` Rafael J. Wysocki
2005-09-27 21:08       ` Pavel Machek
2005-09-27 23:26         ` Rafael J. Wysocki
2005-09-27 23:43           ` Pavel Machek
2005-09-28  8:25             ` Rafael J. Wysocki
2005-09-28 10:29 ` [PATCH][Fix] Fix Bug #4959 (take 3) Rafael J. Wysocki
  -- strict thread matches above, loose matches on Subject: below --
2005-09-24 17:34 [PATCH][Fix] Prevent swsusp from corrupting page translation tables during resume on x86-64 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=200509261246.19085.rjw@sisk.pl \
    --to=rjw@sisk.pl \
    --cc=ak@muc.de \
    --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