By the way, in case anybody is interested, I've done a little bit of
historical digging work. The functions in question date back to
aa0010f8 from 2012. Before that commit, statistics structures would be
incremented after each tunnel's driver itself dereferenced the per-cpu
variable. When this got
On Thu, Nov 12, 2015 at 5:25 PM, Hannes Frederic Sowa
wrote:
> The canonical way is get_cpu_ptr(stats) / put_cpu_ptr.
Thanks for the pointer. Fixed in v2.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majord...@vger.kernel.org
More majordomo info
On Thu, Nov 12, 2015, at 16:30, Jason A. Donenfeld wrote:
> if (err > 0) {
> - struct pcpu_sw_netstats *tstats = this_cpu_ptr(stats);
> -
> + struct pcpu_sw_netstats *tstats;
> + preempt_disable();
> + tstats = this_cpu_ptr(stats);
The