[lkml]   [2001]   [Dec]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectQuestion on sys_readahead()
I have a question on sys_readahead and would appreciate 
some hint or a pointer.

- When was this call added?

- As far as i understand the code it reads the data into
the page cache. The data is ready sync and there is no
way to do this async and have a notification unless using
a separate thread.

A typical use i could see is preloading some data in the
page cache from a separate thread (eg. for a media player).

BTW: AFAICS the code is off by one if offset/count is not in
PAGE_SIZE chunks?

unsigned long start = offset >> PAGE_CACHE_SHIFT;
unsigned long len = (count + ((long)offset & ~PAGE_CACHE_MASK)) >> PAGE_CACHE_SHIFT;


Michael Marxmeier Marxmeier Software AG
E-Mail: Besenbruchstrasse 9
Phone : +49 202 2431440 42285 Wuppertal, Germany
Fax : +49 202 2431420
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:14    [W:0.061 / U:1.724 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site