Re: [PATCH 03/19] fs: Convert nr_inodes and nr_unused to per-cpu counters

Christoph Hellwig
2010-10-17T01:12:08Z

On Sun, Oct 17, 2010 at 12:09:44PM +1100, Dave Chinner wrote:
> > fwiw, for_each_*_cpu() takes longer than a single jiffy tick on those
> > machines.
>
> Yes, agreed. I'm not sure we need exact summation for these counters,
> but I haven't wanted to bring inaccuracies into the code at this
> point in time. I need to investigate the effect of using the
> approximate summation values in all the cases they are used.

Use of the dirty inodes numbers in the writeback code is something
that does not make much sense. It was added as an undocumented
workaround somewhere in the old writeback code, and spread to even
more sites over time. I'm pretty sure we don't actually need it,
but I'm not quite sure what we actually need.