lkml.org 
[lkml]   [2001]   [Jun]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subject[BUG] bug in mmap_kmem
Hi,

The problem is that mmaping a segment <addr,len> from /dev/kmem gives
differnet results than reading the same <addr,len>.

It seems that the bug is that mmap_kmem is a macro for mmap_mem (for
/dev/mem).
mmap_mem maps a _physical_ offset into a vm area vma, while mmap_kmem
should map a _virtual_ offset into a vm area.

I hacked it to work by copying mmap_mem to mmap_kmem and adding __pa() in
the proper assginment, but I don't know how to check if the offset is
valid in the kernel virtual memory. Maybe someone who knows the mm code
better can fix this?

Thanks,

Yoav Etsion

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:55    [W:0.034 / U:0.884 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site