Re: infos on /dev/mem



Georg Acher wrote:
Unfortunately, /dev/mem represents not the physical memory space as a CPU without
MMU would see it. It covers only the lower 16MB. The remaining RAM is not
accessible and mapped to a null page. If you limit the memory at boot time with
the "mem=xxx" option, the unused memory above the xxx is accessible again.
However, the PCI memory mapped IO can always be accessed by /dev/mem.

This isn't the case with the several kernels I am looking at (including
at least three 2.6 versions and a couple of 2.4 versions), all of which
allow mapping of arbitrary physical addresses. Are you perhaps looking
at code that is specific to a particular architecture?

The mem=xxx specification merely redefines what is considered the top
of ordinary memory and hence affects only the "page protection" bits
with which the memory is accessed, usually by mapping pages above that
point uncached.

GH

.



Relevant Pages

  • Re: ten thousand small processes
    ... Stack needs to be executable for the current signal trampoline ... the use of malloc() that is causing your primary ... if there is any heap memory in use at all, no matter what you do, ... either directly, as a 4M page mapping (not used for user processes, ...
    (freebsd-performance)
  • Re: Memory management
    ... The real problem for me is that I would like to use the data cache in the ... ARM but it require the MMU to be enabled ... and MMU requires some RAM for working. ... I understand caching and memory protection are similar in some points but I ...
    (comp.arch.embedded)
  • Re: PCI memory allocation bug with CONFIG_HIGHMEM
    ... > IMHO the only reliable way to get physical bus space for mappings ... > is to allocate some memory and map the mapping over that. ... the RAM addresses are decoded by the ... the way this works is that there are magic northbridge mapping ...
    (Linux-Kernel)
  • [PATCH, RFD]: Unbreak no-mmu mmap
    ... Here's a patch to move nommu mmap/munmap ever so slightly closer to mmu ... If this flag is used, more memory is kept available, but fragmentation ... Every VMA can be in two states: either it manages a power-of-2 sized compound ... mapping we're capable of supporting ...
    (Linux-Kernel)
  • [PATCH] NOMMU: Unbreak no-mmu mmap
    ... Here's a patch to move nommu mmap/munmap ever so slightly closer to mmu ... If this flag is used, more memory is kept available, but fragmentation ... Every VMA can be in two states: either it manages a power-of-2 sized compound ... mapping we're capable of supporting ...
    (Linux-Kernel)