clocksource: use BIT() for clock source flags
PATCH 1/1 clocksource: use BIT() for clock source flags
Signed-off-by Yangtao Li <[email protected]>
--- include/linux/clocksource.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
include/linux/clocksource.h +8 -8
@@ -112,14 +112,14 @@ struct clocksource {/* * Clock source flags bits:: */ -#define CLOCK_SOURCE_IS_CONTINUOUS 0x01 -#define CLOCK_SOURCE_MUST_VERIFY 0x02 - -#define CLOCK_SOURCE_WATCHDOG 0x10 -#define CLOCK_SOURCE_VALID_FOR_HRES 0x20 -#define CLOCK_SOURCE_UNSTABLE 0x40 -#define CLOCK_SOURCE_SUSPEND_NONSTOP 0x80 -#define CLOCK_SOURCE_RESELECT 0x100 +#define CLOCK_SOURCE_IS_CONTINUOUS BIT(0) +#define CLOCK_SOURCE_MUST_VERIFY BIT(1) + +#define CLOCK_SOURCE_WATCHDOG BIT(4) +#define CLOCK_SOURCE_VALID_FOR_HRES BIT(5) +#define CLOCK_SOURCE_UNSTABLE BIT(6) +#define CLOCK_SOURCE_SUSPEND_NONSTOP BIT(7) +#define CLOCK_SOURCE_RESELECT BIT(8)/* simplify initialization of mask field */ #define CLOCKSOURCE_MASK (bits) GENMASK_ULL((bits) - 1, 0)
Signature · 1 line
2.17.0