lkml.org 
[lkml]   [2004]   [Feb]   [4]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateWed, 4 Feb 2004 17:29:04 -0800 (PST)
FromLinus Torvalds <>
SubjectRe: [Bugme-new] [Bug 2019] New: Bug from the mm subsystem involving X (fwd)

On Wed, 4 Feb 2004, Andrew Morton wrote:
> 
> pfn_valid() could become quite expensive indeed, and it lies on super-duper
> hotpaths.

Yes. However, sometimes it is the only choice. 

So it does need to be fixed, and if it ends up being a noticeable
perofmance problem, then we can look at the hot-paths one by one and see
if we can avoid using it. We probably can, most of the time.

> An alternative which is less conceptually clean but should work in this
> case is to mark all vma's which were created by /dev/mem mappings as VM_IO,
> and test that in remap_page_range().

Hmm.. Grepping for "pfn_valid()", I'm starting to suspect that yes, with a
VM_IO approach and a fixed virt_addr_valid(), there really aren't any
other uses.

(virt_addr_valid() is useful for debugging and for validation of untrusted
pointers, but pfn_valid() just isn't very good for it. Never really was:  
it started out as an ugly hack, and it never got cleaned up. It should be
easily fixable with something _proper_).

			Linus
-
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 14:00    [W:0.331 / U:0.120 seconds]
©2003-2008 Jasper Spaans