From: Gao Feng <f...@ikuai8.com> Date: Thu, 3 Nov 2016 22:38:28 +0800
> On Thu, Nov 3, 2016 at 10:31 PM, Eric Dumazet <eric.duma...@gmail.com> wrote: >> On Thu, 2016-11-03 at 21:39 +0800, Gao Feng wrote: >>> Hi Eric, >>> >>> On Thu, Nov 3, 2016 at 9:30 PM, Eric Dumazet <eric.duma...@gmail.com> wrote: >>> > On Thu, 2016-11-03 at 21:03 +0800, f...@ikuai8.com wrote: >>> >> From: Gao Feng <f...@ikuai8.com> >>> >> >>> >> The dropped count of veth is located in struct veth_priv, but other >>> >> statistics like packets and bytes are in another struct pcpu_vstats. >>> >> Now keep these three counters in the same struct. >>> >> >>> >> Signed-off-by: Gao Feng <f...@ikuai8.com> >>> >> --- >>> >> v2: Use right "peer" instead of "dev"; >>> >> v1: Initial version >>> > >>> > May I ask : Why ? >>> >>> Just because I think statistics should be in the same struct. >> >> That is not a good reason then. > > Because other net devices put the statistics together. Organizational "prettyness" is not argument for this change, when the downsides are fundamentally clear: 1) It is not a fast-path accessed statistic, so the per-cpu'ness is not important. 2) We aim to minimize the amount of per-cpu data in the kernel because it is expensive. So when not necessary, as is the case here, we do not user per-cpu data. There are no good reasons to make this change, so I am dropping your patch.