#include <linux/types.h>
 
+/* simplify initialization of mask field */
+#define CYCLECOUNTER_MASK(bits) (cycle_t)((bits) < 64 ? ((1ULL<<(bits))-1) : -1)
+
 /**
  * struct cyclecounter - hardware abstraction for a free running counter
  *     Provides completely state-free accessors to the underlying hardware.
  * @read:              returns the current cycle value
  * @mask:              bitmask for two's complement
  *                     subtraction of non 64 bit counters,
- *                     see CLOCKSOURCE_MASK() helper macro
+ *                     see CYCLECOUNTER_MASK() helper macro
  * @mult:              cycle to nanosecond multiplier
  * @shift:             cycle to nanosecond divisor (power of two)
  */