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
| ||
|
Date: Wed, 13 Feb 2013 13:18:54 -0500 (EST) From: David Miller <davem@...emloft.net> To: paul.gortmaker@...driver.com Cc: netdev@...r.kernel.org, claudiu.manoil@...escale.com, eric.dumazet@...il.com Subject: Re: [PATCH net-next 0/2] gianfar: make local stats atomic64 From: Paul Gortmaker <paul.gortmaker@...driver.com> Date: Tue, 12 Feb 2013 19:24:22 -0500 > Eric noticed that the handling of local u64 ethtool counters for > this driver commonly found on Freescale ppc-32 boards was racy. > > However, before converting them over to atomic64_t, I noticed > that an internal struct was being used to determine the offsets > for exporting this data into the ethtool buffer, and in doing > so, it assumed that the counters would always be u64. Rather > than keep this implicit assumption, a simple code cleanup gets > rid of the struct completely, and leaves less conversion sites. > > The alternative solution would have been to take advantage of > the fact that the counters are all relating to error conditions, > and hence make them internally u32. In doing so, we'd be assuming > that U32_MAX of any particular error condition is highly unlikely. > This might have made sense if any increments were in a hot path. > > Tested with "ethtool -S eth0" on sbc8548 board. ... > git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux.git gfar-ethtool-atomic Pulled, thanks Paul. -- 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