mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] clocksource: import CLOCKSOURCE_MASK from the kernel
@ 2010-11-26 19:56 Jean-Christophe PLAGNIOL-VILLARD
  2010-11-29 14:14 ` [PATCH] clocksource: switch mask to CLOCKSOURCE_MASK Jean-Christophe PLAGNIOL-VILLARD
  0 siblings, 1 reply; 2+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2010-11-26 19:56 UTC (permalink / raw)
  To: barebox

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
---
 include/clock.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/include/clock.h b/include/clock.h
index 278f6e8..b9acdb9 100644
--- a/include/clock.h
+++ b/include/clock.h
@@ -3,6 +3,8 @@
 #ifndef CLOCK_H
 #define CLOCK_H
 
+#define CLOCKSOURCE_MASK(bits) (uint64_t)((bits) < 64 ? ((1ULL<<(bits))-1) : -1)
+
 struct clocksource {
 	uint32_t	shift;
 	uint32_t	mult;
-- 
1.7.1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-11-29 14:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-26 19:56 [PATCH] clocksource: import CLOCKSOURCE_MASK from the kernel Jean-Christophe PLAGNIOL-VILLARD
2010-11-29 14:14 ` [PATCH] clocksource: switch mask to CLOCKSOURCE_MASK Jean-Christophe PLAGNIOL-VILLARD

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox