diff options
author | Jeff Dike <jdike@addtoit.com> | 2006-07-10 07:45:11 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-07-10 16:24:24 -0400 |
commit | 8e64d96aeb495709c13307e2d79f3ee37e96aa4e (patch) | |
tree | 41532136fdd081d561343be876d3068464821910 /arch/um/kernel/irq.c | |
parent | bfaafd7184f044c63cd937cb0ffb4334b4ec7635 (diff) |
[PATCH] uml: remove os_isatty
os_isatty can be made to disappear by moving maybe_sigio_broken from kernel to
user code. This also lets write_sigio_workaround become static.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/um/kernel/irq.c')
-rw-r--r-- | arch/um/kernel/irq.c | 17 |
1 files changed, 2 insertions, 15 deletions
diff --git a/arch/um/kernel/irq.c b/arch/um/kernel/irq.c index 27bc58ad38fd..589c69a75043 100644 --- a/arch/um/kernel/irq.c +++ b/arch/um/kernel/irq.c | |||
@@ -110,19 +110,6 @@ void sigio_handler(int sig, union uml_pt_regs *regs) | |||
110 | free_irqs(); | 110 | free_irqs(); |
111 | } | 111 | } |
112 | 112 | ||
113 | static void maybe_sigio_broken(int fd, int type) | ||
114 | { | ||
115 | if (os_isatty(fd)) { | ||
116 | if ((type == IRQ_WRITE) && !pty_output_sigio) { | ||
117 | write_sigio_workaround(); | ||
118 | add_sigio_fd(fd, 0); | ||
119 | } else if ((type == IRQ_READ) && !pty_close_sigio) { | ||
120 | write_sigio_workaround(); | ||
121 | add_sigio_fd(fd, 1); | ||
122 | } | ||
123 | } | ||
124 | } | ||
125 | |||
126 | static DEFINE_SPINLOCK(irq_lock); | 113 | static DEFINE_SPINLOCK(irq_lock); |
127 | 114 | ||
128 | int activate_fd(int irq, int fd, int type, void *dev_id) | 115 | int activate_fd(int irq, int fd, int type, void *dev_id) |
@@ -221,7 +208,7 @@ int activate_fd(int irq, int fd, int type, void *dev_id) | |||
221 | /* This calls activate_fd, so it has to be outside the critical | 208 | /* This calls activate_fd, so it has to be outside the critical |
222 | * section. | 209 | * section. |
223 | */ | 210 | */ |
224 | maybe_sigio_broken(fd, type); | 211 | maybe_sigio_broken(fd, (type == IRQ_READ)); |
225 | 212 | ||
226 | return(0); | 213 | return(0); |
227 | 214 | ||
@@ -318,7 +305,7 @@ void reactivate_fd(int fd, int irqnum) | |||
318 | /* This calls activate_fd, so it has to be outside the critical | 305 | /* This calls activate_fd, so it has to be outside the critical |
319 | * section. | 306 | * section. |
320 | */ | 307 | */ |
321 | maybe_sigio_broken(fd, irq->type); | 308 | maybe_sigio_broken(fd, (irq->type == IRQ_READ)); |
322 | } | 309 | } |
323 | 310 | ||
324 | void deactivate_fd(int fd, int irqnum) | 311 | void deactivate_fd(int fd, int irqnum) |