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: <20131225114934.GA5378@netboy>
Date:	Wed, 25 Dec 2013 12:49:36 +0100
From:	Richard Cochran <richardcochran@...il.com>
To:	Hadar Hen Zion <hadarh@...lanox.com>
Cc:	Shawn Bohrer <shawn.bohrer@...il.com>,
	"David S. Miller" <davem@...emloft.net>,
	Or Gerlitz <ogerlitz@...lanox.com>,
	Amir Vadai <amirv@...lanox.com>, netdev@...r.kernel.org,
	tomk@...advisors.com, Shawn Bohrer <sbohrer@...advisors.com>
Subject: Re: [PATCH net-next 1/2] mlx4_en: Add PTP hardware clock

On Tue, Dec 24, 2013 at 05:38:35PM +0200, Hadar Hen Zion wrote:
> 
> The spin lock is needed when reading hardware registers.

Or when using a structure of fields that act together as one object.

> My suggestion is to stay with spin locks in all the places
> protecting timecounter_read()/timecounter_init() and just remove the
> spin lock from timecounter_cyc2time()

If you look at the implementation of timecounter_cyc2time, you will
see that locks are, in fact, needed.

See also the comments in clocksource.h.

Thanks,
Richard
--
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