lkml.org 
[lkml]   [2013]   [Feb]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 2/2] make /dev/kmem return error for highmem
    On 02/08/2013 12:28 PM, Dave Hansen wrote:
    > I was auding the /dev/mem code for more questionable uses of
    > __pa(), and ran across this.
    >
    > My assumption is that if you use /dev/kmem, you expect to be
    > able to read the kernel virtual mappings. However, those
    > mappings _stop_ as soon as we hit high memory. The
    > pfn_valid() check in here is good for memory holes, but since
    > highmem pages are still valid, it does no good for those.
    >
    > Also, since we are now checking that __pa() is being done on
    > valid virtual addresses, this might have tripped the new
    > check. Even with the new check, this code would have been
    > broken with the NUMA remapping code had we not ripped it
    > out:
    >

    It would be great if you could take a stab at fixing /dev/mem and
    /dev/kmem... there are a bunch of problems with both which seem to
    really translate to "HIGHMEM was never properly implemented"...

    -hpa


    --
    H. Peter Anvin, Intel Open Source Technology Center
    I work for Intel. I don't speak on their behalf.



    \
     
     \ /
      Last update: 2013-02-08 22:21    [W:3.197 / U:0.084 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site