lkml.org 
[lkml]   [2011]   [Feb]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: virt_to_page for userspace pointers
On 02/13/2011 05:06 PM, Alan Cox wrote:
>>> If you don't lock the page, you have no guarantee that it won't get
>>> swapped out or migrated while you look at the physical page.
>>
>> That's fine, I know that if the page is there at all then it has been
>> locked by a (different) kernel driver. Is there any way to find out what
>> I want?
>
> How do you know the other driver isn't in the middle of releasing the
> page ? Doing that deep in mm code without locking inversions will be fun.

I have complete control over the environment, and I know that my code
will only be called after the other driver has set up the mapping and
the mapping will continue to exist until my code returns.

Please let me risk to shoot myself in the foot, just tell me if there is
a function to do so.. I take full responsibility.


Thanks,

-Nikolaus

--
»Time flies like an arrow, fruit flies like a Banana.«

PGP fingerprint: 5B93 61F8 4EA2 E279 ABF6 02CF A9AD B7F8 AE4E 425C
--
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: 2011-02-13 23:15    [W:0.109 / U:0.684 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site