X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=arch%2Fum%2Fos-Linux%2Firq.c;h=3788d4568d3329008aa6706d3dce3acc5eb81b4f;hb=9464c7cf61b9433057924c36e6e02f303a00e768;hp=7555bf9c33d90670bf11deaf2046e034e4ef882f;hpb=41689045f6a3cbe0550e1d34e9cc20d2e8c432ba;p=linux-2.6.git diff --git a/arch/um/os-Linux/irq.c b/arch/um/os-Linux/irq.c index 7555bf9c3..3788d4568 100644 --- a/arch/um/os-Linux/irq.c +++ b/arch/um/os-Linux/irq.c @@ -52,6 +52,11 @@ int os_waiting_for_events(struct irq_fd *active_fds) return n; } +int os_isatty(int fd) +{ + return isatty(fd); +} + int os_create_pollfd(int fd, int events, void *tmp_pfd, int size_tmpfds) { if (pollfds_num == pollfds_size) { @@ -137,14 +142,17 @@ void os_set_ioignore(void) void init_irq_signals(int on_sigstack) { + __sighandler_t h; int flags; flags = on_sigstack ? SA_ONSTACK : 0; + if (timer_irq_inited) + h = (__sighandler_t)alarm_handler; + else + h = boot_timer_handler; - set_handler(SIGVTALRM, (__sighandler_t) alarm_handler, - flags | SA_RESTART, SIGUSR1, SIGIO, SIGWINCH, SIGALRM, -1); - set_handler(SIGALRM, (__sighandler_t) alarm_handler, - flags | SA_RESTART, SIGUSR1, SIGIO, SIGWINCH, SIGALRM, -1); + set_handler(SIGVTALRM, h, flags | SA_RESTART, + SIGUSR1, SIGIO, SIGWINCH, SIGALRM, -1); set_handler(SIGIO, (__sighandler_t) sig_handler, flags | SA_RESTART, SIGUSR1, SIGIO, SIGWINCH, SIGALRM, SIGVTALRM, -1); signal(SIGWINCH, SIG_IGN);