diff options
| author | David S. Miller <davem@davemloft.net> | 2015-01-02 16:47:51 -0500 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2015-01-02 16:47:51 -0500 |
| commit | dd9553988879a3ff71a86323b88409e7631c4e5d (patch) | |
| tree | 5d81ba6687d57e773084e7d80a66f3ecbce59796 /include/linux | |
| parent | b422da7c366fbf0899db1fdc808fc5fd6700dec5 (diff) | |
| parent | 5ce07a5cef5094168d25296773681bc287e21e3b (diff) | |
Merge branch 'timecounter-next'
Richard Cochran says:
====================
Fixing the "Time Counter fixes and improvements"
For this series I had only tested the build with ARCH=x86 and arm, but
others like sparc64, microblaze, powerpc, and s390 will fail because
they somehow don't indirectly include clocksource.h for the drivers in
question.
This series fixes the build issues reported by:
kbuild test robot <fengguang.wu@intel.com>
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/timecounter.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/timecounter.h b/include/linux/timecounter.h index 74f45496e6d1..4382035a75bb 100644 --- a/include/linux/timecounter.h +++ b/include/linux/timecounter.h @@ -19,6 +19,9 @@ #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. @@ -29,7 +32,7 @@ * @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) */ |
