diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/sbus/char/Kconfig | 14 | ||||
-rw-r--r-- | drivers/sbus/char/aurora.c | 6 | ||||
-rw-r--r-- | drivers/sbus/char/bbc_envctrl.c | 3 | ||||
-rw-r--r-- | drivers/sbus/char/envctrl.c | 10 | ||||
-rw-r--r-- | drivers/sbus/char/vfc_i2c.c | 8 |
5 files changed, 13 insertions, 28 deletions
diff --git a/drivers/sbus/char/Kconfig b/drivers/sbus/char/Kconfig index 90d8ef1f0bcc..a41778a490d6 100644 --- a/drivers/sbus/char/Kconfig +++ b/drivers/sbus/char/Kconfig | |||
@@ -71,20 +71,6 @@ config SUN_JSFLASH | |||
71 | 71 | ||
72 | # XXX Why don't we do "source drivers/char/Config.in" somewhere? | 72 | # XXX Why don't we do "source drivers/char/Config.in" somewhere? |
73 | # no shit | 73 | # no shit |
74 | config APM_RTC_IS_GMT | ||
75 | bool | ||
76 | depends on EXPERIMENTAL && SPARC32 && PCI | ||
77 | default y | ||
78 | help | ||
79 | Say Y here if your RTC (Real Time Clock a.k.a. hardware clock) | ||
80 | stores the time in GMT (Greenwich Mean Time). Say N if your RTC | ||
81 | stores localtime. | ||
82 | |||
83 | It is in fact recommended to store GMT in your RTC, because then you | ||
84 | don't have to worry about daylight savings time changes. The only | ||
85 | reason not to use GMT in your RTC is if you also run a broken OS | ||
86 | that doesn't understand GMT. | ||
87 | |||
88 | config RTC | 74 | config RTC |
89 | tristate "PC-style Real Time Clock Support" | 75 | tristate "PC-style Real Time Clock Support" |
90 | depends on PCI && EXPERIMENTAL && SPARC32 | 76 | depends on PCI && EXPERIMENTAL && SPARC32 |
diff --git a/drivers/sbus/char/aurora.c b/drivers/sbus/char/aurora.c index 650d5e924f47..d96cc47de566 100644 --- a/drivers/sbus/char/aurora.c +++ b/drivers/sbus/char/aurora.c | |||
@@ -1515,8 +1515,7 @@ static void aurora_close(struct tty_struct * tty, struct file * filp) | |||
1515 | */ | 1515 | */ |
1516 | timeout = jiffies+HZ; | 1516 | timeout = jiffies+HZ; |
1517 | while(port->SRER & SRER_TXEMPTY) { | 1517 | while(port->SRER & SRER_TXEMPTY) { |
1518 | current->state = TASK_INTERRUPTIBLE; | 1518 | msleep_interruptible(jiffies_to_msecs(port->timeout)); |
1519 | schedule_timeout(port->timeout); | ||
1520 | if (time_after(jiffies, timeout)) | 1519 | if (time_after(jiffies, timeout)) |
1521 | break; | 1520 | break; |
1522 | } | 1521 | } |
@@ -1533,8 +1532,7 @@ static void aurora_close(struct tty_struct * tty, struct file * filp) | |||
1533 | port->tty = 0; | 1532 | port->tty = 0; |
1534 | if (port->blocked_open) { | 1533 | if (port->blocked_open) { |
1535 | if (port->close_delay) { | 1534 | if (port->close_delay) { |
1536 | current->state = TASK_INTERRUPTIBLE; | 1535 | msleep_interruptible(jiffies_to_msecs(port->close_delay)); |
1537 | schedule_timeout(port->close_delay); | ||
1538 | } | 1536 | } |
1539 | wake_up_interruptible(&port->open_wait); | 1537 | wake_up_interruptible(&port->open_wait); |
1540 | } | 1538 | } |
diff --git a/drivers/sbus/char/bbc_envctrl.c b/drivers/sbus/char/bbc_envctrl.c index d5259f7fee6d..b8a2c7353b0a 100644 --- a/drivers/sbus/char/bbc_envctrl.c +++ b/drivers/sbus/char/bbc_envctrl.c | |||
@@ -4,13 +4,14 @@ | |||
4 | * Copyright (C) 2001 David S. Miller (davem@redhat.com) | 4 | * Copyright (C) 2001 David S. Miller (davem@redhat.com) |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #define __KERNEL_SYSCALLS__ | ||
8 | |||
7 | #include <linux/kernel.h> | 9 | #include <linux/kernel.h> |
8 | #include <linux/sched.h> | 10 | #include <linux/sched.h> |
9 | #include <linux/slab.h> | 11 | #include <linux/slab.h> |
10 | #include <linux/delay.h> | 12 | #include <linux/delay.h> |
11 | #include <asm/oplib.h> | 13 | #include <asm/oplib.h> |
12 | #include <asm/ebus.h> | 14 | #include <asm/ebus.h> |
13 | #define __KERNEL_SYSCALLS__ | ||
14 | static int errno; | 15 | static int errno; |
15 | #include <asm/unistd.h> | 16 | #include <asm/unistd.h> |
16 | 17 | ||
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__ | ||
39 | static int errno; | 40 | static 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) { |
diff --git a/drivers/sbus/char/vfc_i2c.c b/drivers/sbus/char/vfc_i2c.c index 95e3cebf792c..1faf1e75f71f 100644 --- a/drivers/sbus/char/vfc_i2c.c +++ b/drivers/sbus/char/vfc_i2c.c | |||
@@ -88,14 +88,16 @@ void vfc_i2c_delay_wakeup(struct vfc_dev *dev) | |||
88 | 88 | ||
89 | void vfc_i2c_delay_no_busy(struct vfc_dev *dev, unsigned long usecs) | 89 | void vfc_i2c_delay_no_busy(struct vfc_dev *dev, unsigned long usecs) |
90 | { | 90 | { |
91 | DEFINE_WAIT(wait); | ||
91 | init_timer(&dev->poll_timer); | 92 | init_timer(&dev->poll_timer); |
92 | dev->poll_timer.expires = jiffies + | 93 | dev->poll_timer.expires = jiffies + usecs_to_jiffies(usecs); |
93 | ((unsigned long)usecs*(HZ))/1000000; | ||
94 | dev->poll_timer.data=(unsigned long)dev; | 94 | dev->poll_timer.data=(unsigned long)dev; |
95 | dev->poll_timer.function=(void *)(unsigned long)vfc_i2c_delay_wakeup; | 95 | dev->poll_timer.function=(void *)(unsigned long)vfc_i2c_delay_wakeup; |
96 | add_timer(&dev->poll_timer); | 96 | add_timer(&dev->poll_timer); |
97 | sleep_on(&dev->poll_wait); | 97 | prepare_to_wait(&dev->poll_wait, &wait, TASK_UNINTERRUPTIBLE); |
98 | schedule(); | ||
98 | del_timer(&dev->poll_timer); | 99 | del_timer(&dev->poll_timer); |
100 | finish_wait(&dev->poll_wait, &wait); | ||
99 | } | 101 | } |
100 | 102 | ||
101 | void inline vfc_i2c_delay(struct vfc_dev *dev) | 103 | void inline vfc_i2c_delay(struct vfc_dev *dev) |