All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: David Daney <ddaney.cavm@gmail.com>
Cc: Prem Mallappa <prem.mallappa@gmail.com>,
	linux-mips <linux-mips@linux-mips.org>,
	Prem Mallappa <pmallappa@caviumnetworks.com>
Subject: Re: [PATCH] MIPS: KDUMP: Fix to access non-sectioned memory
Date: Thu, 3 Oct 2013 22:16:41 +0200	[thread overview]
Message-ID: <20131003201641.GC15556@linux-mips.org> (raw)
In-Reply-To: <524DBC02.6020009@gmail.com>

On Thu, Oct 03, 2013 at 11:48:34AM -0700, David Daney wrote:

> I wonder, how does /dev/mem handle it?  We should probably do what
> the mem driver does for this.

/dev/mem is converting physical address to virtual addresses using
xlate_dev_mem_ptr() which is defined as:

#define xlate_dev_mem_ptr(p)	__va(p)

which obviously is suffering from similar problems as Prem's suggested
patch.

Fortunately /dev/(k)mem have pretty much gotten out of fashion ;-)

The x86 implementation of xlate_dev_mem_ptr() is based on ioremap_cache()
which may be x86-specific - but very handy in situations like this and
there might also be devices which want to be mapped cached.

I'm considering to implement it since ages.  I just don't want a whole
flood of new cache modes like ioremap_uncached_accelerated() or maybe
ioremap_writeback_on_sunday_afternoons_only()  ;-)

  Ralf

      reply	other threads:[~2013-10-03 20:16 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-03  7:46 MIPS: KDUMP: fix for crashkernel to load from non-sectioned memory Prem Mallappa
2013-10-03  7:46 ` [PATCH] MIPS: KDUMP: Fix to access " Prem Mallappa
2013-10-03 18:29   ` Ralf Baechle
2013-10-03 18:48     ` David Daney
2013-10-03 20:16       ` Ralf Baechle [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=20131003201641.GC15556@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=ddaney.cavm@gmail.com \
    --cc=linux-mips@linux-mips.org \
    --cc=pmallappa@caviumnetworks.com \
    --cc=prem.mallappa@gmail.com \
    /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.