[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <51156494.3050300@zytor.com>
Date: Fri, 08 Feb 2013 12:48:20 -0800
From: "H. Peter Anvin" <hpa@...or.com>
To: Dave Hansen <dave@...ux.vnet.ibm.com>
CC: linux-kernel@...r.kernel.org, linux-mm@...ck.org, bp@...en8.de,
mingo@...nel.org, tglx@...utronix.de
Subject: Re: [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.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists