summaryrefslogtreecommitdiffstats
path: root/kernel/posix-timers.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/posix-timers.c')
-rw-r--r--kernel/posix-timers.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c
index af936fd37140..44fcff131b38 100644
--- a/kernel/posix-timers.c
+++ b/kernel/posix-timers.c
@@ -41,6 +41,7 @@
#include <linux/init.h>
#include <linux/compiler.h>
#include <linux/idr.h>
+#include <linux/posix-clock.h>
#include <linux/posix-timers.h>
#include <linux/syscalls.h>
#include <linux/wait.h>
@@ -489,7 +490,8 @@ static void release_posix_timer(struct k_itimer *tmr, int it_id_set)
static struct k_clock *clockid_to_kclock(const clockid_t id)
{
if (id < 0)
- return (id & CLOCKFD_MASK) == CLOCKFD ? NULL : &clock_posix_cpu;
+ return (id & CLOCKFD_MASK) == CLOCKFD ?
+ &clock_posix_dynamic : &clock_posix_cpu;
if (id >= MAX_CLOCKS || !posix_clocks[id].clock_getres)
return NULL;
OpenPOWER on IntegriCloud