[lkml]   [2009]   [Jun]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: running get_user_pages() from kernel thread
On Tue, Jun 16, 2009 at 09:05:27PM +0300, Izik Eidus wrote:
> So the question is: is this thing is by desgin? (that kernel thread cant
> call get_user_pages???), should i use something like switch_mm()??

I think switch_mm trick should be used for page faults, but gup
shouldn't require it because it gets the 'mm' as parameter and the
current->mm has to be irrelevant. current->mm is only relevant for
gup-fast (obviously :). So I think the only bit that needs fixing is
grab_swap_token to not run if current->mm is null.

 \ /
  Last update: 2009-06-16 20:15    [W:0.059 / U:5.476 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site