Skip to content

Commit 84663a5

Browse files
t-8chThomas Gleixner
authored andcommitted
hrtimer: Remove public definition of HIGH_RES_NSEC
This constant is only used in a single place and is has a very generic name polluting the global namespace. Move the constant closer to its only user. Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@kernel.org> Link: https://patch.msgid.link/20260107-hrtimer-header-cleanup-v1-2-1a698ef0ddae@linutronix.de
1 parent 0483e5e commit 84663a5

2 files changed

Lines changed: 8 additions & 12 deletions

File tree

include/linux/hrtimer_defs.h

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,6 @@
66
#include <linux/timerqueue.h>
77
#include <linux/seqlock.h>
88

9-
#ifdef CONFIG_HIGH_RES_TIMERS
10-
11-
/*
12-
* The resolution of the clocks. The resolution value is returned in
13-
* the clock_getres() system call to give application programmers an
14-
* idea of the (in)accuracy of timers. Timer values are rounded up to
15-
* this resolution values.
16-
*/
17-
# define HIGH_RES_NSEC 1
18-
19-
#endif
20-
219
#ifdef CONFIG_64BIT
2210
# define __hrtimer_clock_base_align ____cacheline_aligned
2311
#else

kernel/time/hrtimer.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,14 @@
4949

5050
#include "tick-internal.h"
5151

52+
/*
53+
* The resolution of the clocks. The resolution value is returned in
54+
* the clock_getres() system call to give application programmers an
55+
* idea of the (in)accuracy of timers. Timer values are rounded up to
56+
* this resolution values.
57+
*/
58+
#define HIGH_RES_NSEC 1
59+
5260
/*
5361
* Masks for selecting the soft and hard context timers from
5462
* cpu_base->active

0 commit comments

Comments
 (0)