lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Fri, 15 Apr 2016 14:30:28 +0200
From:	Paolo Abeni <pabeni@...hat.com>
To:	David Miller <davem@...emloft.net>
Cc:	netdev@...r.kernel.org, mst@...hat.com, hannes@...essinduktion.org,
	ebiederm@...ssion.com, gkurz@...ux.vnet.ibm.com,
	jasowang@...hat.com
Subject: Re: [PATCH net-next] tun: use per cpu variables for stats accounting

On Thu, 2016-04-14 at 22:56 -0400, David Miller wrote:
> From: Paolo Abeni <pabeni@...hat.com>
> Date: Wed, 13 Apr 2016 10:52:20 +0200
> 
> > Currently the tun device accounting uses dev->stats without applying any
> > kind of protection, regardless that accounting happens in preemptible
> > process context.
> > This patch move the tun stats to a per cpu data structure, and protect
> > the updates with  u64_stats_update_begin()/u64_stats_update_end() or
> > this_cpu_inc according to the stat type. The per cpu stats are
> > aggregated by the newly added ndo_get_stats64 ops.
> > 
> > Signed-off-by: Paolo Abeni <pabeni@...hat.com>
> 
> Ok this seems reasonable, applied, thanks.
> 
> I guess most applications use tuntap by having two threads, one
> for transmit and one for receive processing?

Probably. I guess that an user space application can leverage multiple
transmit threads to improve the throughput.

Paolo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ