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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAEP_g=9AS1_vB2=Cjxf=XJrbZAL6qj_qN0Ut7D_J0p3ZJHreOA@mail.gmail.com>
Date:	Sat, 19 Nov 2011 10:19:42 -0800
From:	Jesse Gross <jesse@...ira.com>
To:	David Miller <davem@...emloft.net>
Cc:	stephen.hemminger@...tta.com, netdev@...r.kernel.org,
	dev@...nvswitch.org
Subject: Re: [PATCH net-next 4/4] net: Add Open vSwitch kernel components.

On Fri, Nov 18, 2011 at 5:37 PM, David Miller <davem@...emloft.net> wrote:
> From: Stephen Hemminger <stephen.hemminger@...tta.com>
> Date: Fri, 18 Nov 2011 17:09:17 -0800 (PST)
>
>>
>>> On Fri, Nov 18, 2011 at 3:23 PM, Stephen Hemminger
>>> <shemminger@...tta.com> wrote:
>>> > On Fri, 18 Nov 2011 15:12:18 -0800
>>> > Jesse Gross <jesse@...ira.com> wrote:
>>> >
>>> >> +             write_seqcount_begin(&stats->seqlock);
>>> >> +             stats->tx_packets++;
>>> >> +             stats->tx_bytes += sent;
>>> >> +             write_seqcount_end(&stats->seqlock);
>>> >
>>> > There is a u64_stats_sync set of macros for this. It has the
>>> > advantage of becoming a NOP on 64 bit platforms.
>>>
>>> The reason why I did it this way is it ties the packet and byte count
>>> together.
>>
>> Ok, but why bother?
>> No other software counters bother to group bytes/packets. Even
>> hardware counters get read separately.
>
> Agreed, this is totally pointless.  Please use the u64 state interfaces.

That's fine, I'll change it.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ