lkml.org 
[lkml]   [2011]   [May]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 00/13] blk-throttle: lockless bio processing for no throttle rule group [V2]
On Thu, May 19, 2011 at 03:38:18PM -0400, Vivek Goyal wrote:
> Hi,
>
> This is V2 of the patch. Changes from V1 are.
>
> - Dropped first patch of the series which has already been merged.
> - Fixed couple of white space warnings.
>
> Jens, I am sending this series on your both the ids. See if both produce
> warnings.
>
> Block throttling code takes request queue lock for every incoming bio
> (blk_throtl_bio()). This is true even if there are no throttle rules in
> the group. This is a common case for root cgroup where distributions
> will have throttling support compiled in but a vast majority of users
> will not be specifying throttling rule.
>
> This patch series tries to make bio processing lockless (no requeust
> queue lock), if there are no rules specified for the group. Once
> a bio is submitted, under rcu_read_lock() we search for the group,
> update the stats and release the rcu lock. request queue lock is taken
> only if there are throttling rules specified in the group.
>
> I have made some of the dispatch stats per cpu so that these can be updated
> without taking request queue lock.

Also forgot to mention that now throttling path does not take blkg->stat_lock
at all. Throttling updates only 3 stats and all these 3 stats have been
converted to per cpu, hence we got rid of the need of taking blkg->stat_lock
also.

Divyesh, can you have a look at locking changes around stats and see if
you have any concerns.

Thanks
Vivek


\
 
 \ /
  Last update: 2011-05-19 22:01    [from the cache]
©2003-2011 Jasper Spaans