From: Ben Gras Date: Sun, 4 Sep 2005 18:16:44 +0000 (+0000) Subject: Make compiling with 0 pty's or rs232 lines possible (Al's patch) X-Git-Tag: v3.1.0~195 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/zpipe.c?a=commitdiff_plain;h=a32fa468f3fa3adde70ba2878b3770f77db8e56c;p=minix.git Make compiling with 0 pty's or rs232 lines possible (Al's patch) --- diff --git a/drivers/tty/tty.c b/drivers/tty/tty.c index 805e555f0..9961f393f 100644 --- a/drivers/tty/tty.c +++ b/drivers/tty/tty.c @@ -204,8 +204,10 @@ PUBLIC void main(void) case HARD_INT: { /* hardware interrupt notification */ if (tty_mess.NOTIFY_ARG & kbd_irq_set) kbd_interrupt(&tty_mess);/* fetch chars from keyboard */ +#if NR_RS_LINES > 0 if (tty_mess.NOTIFY_ARG & rs_irq_set) rs_interrupt(&tty_mess);/* serial I/O */ +#endif expire_timers(); /* run watchdogs of expired timers */ continue; /* contine to check for events */ } @@ -346,8 +348,10 @@ message *m_ptr; } } +#if NR_PTYS > 0 if (!event_found) event_found = pty_status(m_ptr); +#endif if (! event_found) { /* No events of interest were found. Return an empty message. */ @@ -877,8 +881,10 @@ tty_t *tp; /* TTY to check for events. */ } if(tp->tty_select_ops) select_retry(tp); +#if NR_PTYS > 0 if(ispty(tp)) select_retry_pty(tp); +#endif } /*===========================================================================*