lkml.org 
[lkml]   [2006]   [Sep]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 05/16] GFS2: File and inode operations

>> Is not there a better way to do this? Note that there is also a "nfsd4" process
>> running. Do you really want to do a 'costly'
>>
>> strcmp(current->comm, "nfsd") != 0 && strcmp(current->comm, "nfsd4") != 0
>>
>> every time someone does a readdir? What if I run a userspace nfs daemon?
>> What if that userspace daemon is called differently?
>>
>> jengelh@linux01:7 08:28:14 ~ > ps -e | grep nfs
>> 5580 ? 00:00:08 rpc.nfsd
>> jengelh@linux01:7 08:28:30 ~ > rpm -qf /usr/sbin/rpc.nfsd
>> nfs-server-2.2beta51-209.2 (a userspace nfsd)
>
>Ah, now this is a very tricky one to solve. Its on my todo list to look
>at this area again. You are right that the test is bogus in that it
>should only respond to the in kernel NFS server and the reason for its

In that case, you could use the fact that ... (I'll express it in C code):

is_kernel_task = !current->mm;

>existence is due to locking issues with the way that NFS calls through
>the VFS layer.


Jan Engelhardt
--
-
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: 2006-09-04 17:03    [from the cache]
©2003-2011 Jasper Spaans