lkml.org 
[lkml]   [2003]   [Apr]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: read actor
On Thu, Apr 03, 2003 at 04:14:05PM +0200, fcorneli@elis.ugent.be wrote:
> Hi,
>
> When one uses do_generic_file_read to (in-kernel) read a file from the
> page cache one has to give a read_actor as parameter. Suppose different
> do_generic_file_read instances occur simultaneously, then how can a
> shared file_read_actor differentiate between the different
> do_generic_file_read instances that made a call to it?
> Shouldn't read_descriptor_t contain something like
> void *this_data;
> to make this possible?

do_generic_file_read is not an interface you are supposed to use, and any use
of it will lead to subtile races with filesystems that use the pagecache
but not plain generic_file_read. See the ->sendfile operation in 2.5
for a proper fix.

-
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 13:34    [W:0.030 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site