diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2011-02-01 08:51:45 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2011-02-02 09:28:14 -0500 |
commit | 79c9da0d0539fb341a1b48a2a5a23d974726de90 (patch) | |
tree | 9c13a5c5fb35b5f1fd92f6fe5875c549a6b6d1f0 /kernel/posix-cpu-timers.c | |
parent | d608c18203a969e5d14572a9861c646d0bb66872 (diff) |
posix-cpu-timers: Remove the stub nanosleep functions
CLOCK_THREAD_CPUTIME_ID implements stub functions for nanosleep and
nanosleep_restart, which return -EINVAL. That return value is
wrong. The correct return value is -ENOTSUP.
Remove the stubs and let the new dispatch code return the correct
error code.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: John Stultz <johnstul@us.ibm.com>
Tested-by: Richard Cochran <richard.cochran@omicron.at>
LKML-Reference: <20110201134418.422446502@linutronix.de>
Diffstat (limited to 'kernel/posix-cpu-timers.c')
-rw-r--r-- | kernel/posix-cpu-timers.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/kernel/posix-cpu-timers.c b/kernel/posix-cpu-timers.c index 9e617b00afa9..8dc4cd7faf89 100644 --- a/kernel/posix-cpu-timers.c +++ b/kernel/posix-cpu-timers.c | |||
@@ -1586,15 +1586,6 @@ static int thread_cpu_timer_create(struct k_itimer *timer) | |||
1586 | timer->it_clock = THREAD_CLOCK; | 1586 | timer->it_clock = THREAD_CLOCK; |
1587 | return posix_cpu_timer_create(timer); | 1587 | return posix_cpu_timer_create(timer); |
1588 | } | 1588 | } |
1589 | static int thread_cpu_nsleep(const clockid_t which_clock, int flags, | ||
1590 | struct timespec *rqtp, struct timespec __user *rmtp) | ||
1591 | { | ||
1592 | return -EINVAL; | ||
1593 | } | ||
1594 | static long thread_cpu_nsleep_restart(struct restart_block *restart_block) | ||
1595 | { | ||
1596 | return -EINVAL; | ||
1597 | } | ||
1598 | 1589 | ||
1599 | struct k_clock clock_posix_cpu = { | 1590 | struct k_clock clock_posix_cpu = { |
1600 | .clock_getres = posix_cpu_clock_getres, | 1591 | .clock_getres = posix_cpu_clock_getres, |
@@ -1623,8 +1614,6 @@ static __init int init_posix_cpu_timers(void) | |||
1623 | .clock_get = thread_cpu_clock_get, | 1614 | .clock_get = thread_cpu_clock_get, |
1624 | .clock_set = do_posix_clock_nosettime, | 1615 | .clock_set = do_posix_clock_nosettime, |
1625 | .timer_create = thread_cpu_timer_create, | 1616 | .timer_create = thread_cpu_timer_create, |
1626 | .nsleep = thread_cpu_nsleep, | ||
1627 | .nsleep_restart = thread_cpu_nsleep_restart, | ||
1628 | }; | 1617 | }; |
1629 | struct timespec ts; | 1618 | struct timespec ts; |
1630 | 1619 | ||