Re: [PATCH] MIPS: KDUMP: Fix to access non-sectioned memory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux