From 532d0fa4d104ca3e37dd38bc5073376fcc3c2712 Mon Sep 17 00:00:00 2001 From: Jeff Dike Date: Tue, 16 Oct 2007 01:27:21 -0700 Subject: uml: eliminate hz() Eliminate hz() since its only purpose was to provide a kernel-space constant to userspace code. This can be done instead by providing the constant directly through kernel_constants.h. Signed-off-by: Jeff Dike Cc: Thomas Gleixner Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- arch/um/os-Linux/time.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'arch/um/os-Linux/time.c') diff --git a/arch/um/os-Linux/time.c b/arch/um/os-Linux/time.c index f22fcdfd4250..5939653f99ea 100644 --- a/arch/um/os-Linux/time.c +++ b/arch/um/os-Linux/time.c @@ -8,14 +8,13 @@ #include #include #include -#include "kern_util.h" #include "kern_constants.h" #include "os.h" #include "user.h" int set_interval(int is_virtual) { - int usec = 1000000/hz(); + int usec = 1000000/UM_HZ; int timer_type = is_virtual ? ITIMER_VIRTUAL : ITIMER_REAL; struct itimerval interval = ((struct itimerval) { { 0, usec }, { 0, usec } }); @@ -43,8 +42,8 @@ void disable_timer(void) void switch_timers(int to_real) { struct itimerval disable = ((struct itimerval) { { 0, 0 }, { 0, 0 }}); - struct itimerval enable = ((struct itimerval) { { 0, 1000000/hz() }, - { 0, 1000000/hz() }}); + struct itimerval enable = ((struct itimerval) { { 0, 1000000/UM_HZ }, + { 0, 1000000/UM_HZ }}); int old, new; if (to_real) { -- cgit v1.2.3