lkml.org 
[lkml]   [2006]   [May]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [rfc][patch] remove racy sync_page?


On Wed, 31 May 2006, Nick Piggin wrote:
>
> Now having a mechanism for a task to batch up requests might be a
> good idea. Eg.
>
> plug();
> submit reads
> unplug();
> wait for page

What do you think we're _talking_ about?

What do you think my example of sys_readahead() was all about?

WE DO HAVE EXACTLY THAT MECHANISM. IT'S CALLED PLUGGING!

> I'd think this would give us the benefits of corse grained (per-queue)
> plugging and more (e.g. it works when the request queue isn't empty).
> And it would be simpler because the unplug point is explicit and doesn't
> need to be kicked by lock_page or wait_on_page

What do you think plugging IS?

It's _exactly_ what you're talking about. And yes, we used to have
explicit unplugging (a long long long time ago), and IT SUCKED. People
would forget, but even more importantly, people would do it even when not
needed because they didn't have a good place to do it because the waiter
was in a totally different path.

The reason it's kicked by wait_on_page() is that is when it's needed.

Linus
-
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: 2009-11-18 23:46    [W:0.187 / U:0.228 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site