X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Flinux%2Ftty_ldisc.h;h=deacf01e50e8a5e6351e898b6f6910e69581f732;hb=c7b5ebbddf7bcd3651947760f423e3783bbe6573;hp=cb7ca58e44e8e6031fd1d1a45edbb278a3c20815;hpb=9213980e6a70d8473e0ffd4b39ab5b6caaba9ff5;p=linux-2.6.git diff --git a/include/linux/tty_ldisc.h b/include/linux/tty_ldisc.h index cb7ca58e4..deacf01e5 100644 --- a/include/linux/tty_ldisc.h +++ b/include/linux/tty_ldisc.h @@ -95,6 +95,13 @@ * that line discpline should try to send more characters to the * low-level driver for transmission. If the line discpline does * not have any more data to send, it can just return. + * + * int (*hangup)(struct tty_struct *) + * + * Called on a hangup. Tells the discipline that it should + * cease I/O to the tty driver. Can sleep. The driver should + * seek to perform this action quickly but should wait until + * any pending driver I/O is completed. */ #include @@ -122,6 +129,7 @@ struct tty_ldisc { void (*set_termios)(struct tty_struct *tty, struct termios * old); unsigned int (*poll)(struct tty_struct *, struct file *, struct poll_table_struct *); + int (*hangup)(struct tty_struct *tty); /* * The following routines are called from below. @@ -132,6 +140,8 @@ struct tty_ldisc { void (*write_wakeup)(struct tty_struct *); struct module *owner; + + int refcount; }; #define TTY_LDISC_MAGIC 0x5403