aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/sbus/char/envctrl.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/sbus/char/envctrl.c')
-rw-r--r--drivers/sbus/char/envctrl.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/sbus/char/envctrl.c b/drivers/sbus/char/envctrl.c
index f6ed35b24f43..9a8c572554f5 100644
--- a/drivers/sbus/char/envctrl.c
+++ b/drivers/sbus/char/envctrl.c
@@ -19,6 +19,8 @@
19 * Daniele Bellucci <bellucda@tiscali.it> 19 * Daniele Bellucci <bellucda@tiscali.it>
20 */ 20 */
21 21
22#define __KERNEL_SYSCALLS__
23
22#include <linux/config.h> 24#include <linux/config.h>
23#include <linux/module.h> 25#include <linux/module.h>
24#include <linux/sched.h> 26#include <linux/sched.h>
@@ -35,7 +37,6 @@
35#include <asm/uaccess.h> 37#include <asm/uaccess.h>
36#include <asm/envctrl.h> 38#include <asm/envctrl.h>
37 39
38#define __KERNEL_SYSCALLS__
39static int errno; 40static int errno;
40#include <asm/unistd.h> 41#include <asm/unistd.h>
41 42
@@ -1007,7 +1008,7 @@ static int kenvctrld(void *__unused)
1007 return -ENODEV; 1008 return -ENODEV;
1008 } 1009 }
1009 1010
1010 poll_interval = 5 * HZ; /* TODO env_mon_interval */ 1011 poll_interval = 5000; /* TODO env_mon_interval */
1011 1012
1012 daemonize("kenvctrld"); 1013 daemonize("kenvctrld");
1013 allow_signal(SIGKILL); 1014 allow_signal(SIGKILL);
@@ -1016,10 +1017,7 @@ static int kenvctrld(void *__unused)
1016 1017
1017 printk(KERN_INFO "envctrl: %s starting...\n", current->comm); 1018 printk(KERN_INFO "envctrl: %s starting...\n", current->comm);
1018 for (;;) { 1019 for (;;) {
1019 current->state = TASK_INTERRUPTIBLE; 1020 if(msleep_interruptible(poll_interval))
1020 schedule_timeout(poll_interval);
1021
1022 if(signal_pending(current))
1023 break; 1021 break;
1024 1022
1025 for (whichcpu = 0; whichcpu < ENVCTRL_MAX_CPU; ++whichcpu) { 1023 for (whichcpu = 0; whichcpu < ENVCTRL_MAX_CPU; ++whichcpu) {