Files
android_kernel_xiaomi_sm8450/include/linux
Nikolay Borisov 3e8f399da4 writeback: rework wb_[dec|inc]_stat family of functions
Currently the writeback statistics code uses a percpu counters to hold
various statistics.  Furthermore we have 2 families of functions - those
which disable local irq and those which doesn't and whose names begin
with double underscore.  However, they both end up calling
__add_wb_stats which in turn calls percpu_counter_add_batch which is
already irq-safe.

Exploiting this fact allows to eliminated the __wb_* functions since
they don't add any further protection than we already have.
Furthermore, refactor the wb_* function to call __add_wb_stat directly
without the irq-disabling dance.  This will likely result in better
runtime of code which deals with modifying the stat counters.

While at it also document why percpu_counter_add_batch is in fact
preempt and irq-safe since at least 3 people got confused.

Link: http://lkml.kernel.org/r/1498029937-27293-1-git-send-email-nborisov@suse.com
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Acked-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Jan Kara <jack@suse.cz>
Cc: Josef Bacik <jbacik@fb.com>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-07-12 16:26:05 -07:00
..
2017-04-21 10:45:01 -04:00
2017-06-03 19:29:26 +09:00
2017-07-03 01:43:45 -07:00
2017-06-08 18:52:36 -07:00
2017-07-03 17:00:59 -06:00
2017-02-10 15:52:24 -05:00
2017-07-06 16:24:33 -07:00
2017-07-01 16:15:13 -07:00
2017-07-01 16:15:13 -07:00
2017-07-03 02:22:52 -07:00
2017-07-03 16:56:28 -06:00
2017-05-24 12:43:30 -04:00
2017-06-05 16:59:12 +02:00
2017-04-18 20:41:12 +02:00
2017-06-22 15:43:47 +01:00
2017-06-09 11:52:07 +02:00
2017-05-18 10:30:19 -06:00
2017-07-10 16:32:31 -07:00
2017-07-07 09:49:24 +10:00
2017-04-10 17:15:02 +02:00
2017-04-27 05:13:04 -04:00
2017-07-07 20:09:10 -04:00
2017-06-05 16:59:10 +02:00
2017-03-21 10:15:47 +02:00
2017-05-18 10:07:41 -04:00
2017-05-18 10:07:40 -04:00
2017-06-21 14:37:12 -04:00
2017-07-10 16:32:34 -07:00
2017-07-12 16:26:01 -07:00
2017-05-03 15:52:10 -07:00
2017-06-04 16:53:00 +02:00
2017-02-24 17:46:57 -08:00
2017-04-24 14:30:46 -04:00
2017-04-26 13:03:04 -04:00
2017-07-12 16:26:02 -07:00
2017-05-26 10:10:37 +02:00
2017-05-18 10:07:40 -04:00
2017-02-13 21:44:09 -05:00
2017-06-29 10:48:57 +01:00
2017-05-03 15:52:10 -07:00
2017-06-08 10:35:49 +02:00
2017-07-06 16:24:30 -07:00
2017-03-26 15:09:45 +02:00
2017-06-15 12:12:40 -04:00
2017-06-08 18:52:42 -07:00
2017-06-01 14:53:04 -04:00
2017-03-09 15:42:33 +01:00
2017-05-09 16:43:22 +03:00
2017-06-09 11:54:54 +02:00