Annotation of researchv9/sys/h/nttyld.h, revision 1.1.1.1

1.1       root        1: /*
                      2:  * new tty line discipline processing
                      3:  */
                      4: 
                      5: struct nttyld {
                      6: 
                      7:        struct  queue *nt_outq;         /* for echoed characters */
                      8:        struct  queue *nt_readq;        /* for processed input characters */
                      9: 
                     10: #define NT_NIN 256
                     11:        char    nt_in[NT_NIN];  /* cooked mode input buffer */
                     12:        short   nt_nin;         /* current number of characters in nt_in */
                     13: 
                     14:        short   nt_flags;       /* ioctl [gs]ettable modes */
                     15:        short   nt_state;       /* internal state, not visible externally */
                     16:        char    nt_col;         /* printing column of device */
                     17:        char    nt_delct;       /* number of delimiters in read queue */
                     18: 
                     19:        char    nt_erase;       /* erase character */
                     20:        char    nt_kill;        /* kill character */
                     21:        struct  tchars nt_tchr;
                     22: #define nt_intrc       nt_tchr.t_intrc
                     23: #define nt_quitc       nt_tchr.t_quitc
                     24: #define nt_startc      nt_tchr.t_startc
                     25: #define nt_stopc       nt_tchr.t_stopc
                     26: #define nt_eofc                nt_tchr.t_eofc
                     27: #define nt_brkc                nt_tchr.t_brkc
                     28: 
                     29:        /*
                     30:         * local:
                     31:         */
                     32:        short   nt_trash;       /* nt_nin after last write() data processed */
                     33:        short   nt_rocol;       /* nt_col when nt_nin==0 */
                     34:        short   nt_local;       /* local mode bits */
                     35:        short   nt_lstate;      /* local state bits */
                     36: 
                     37:        struct  ltchars nt_ltchr;
                     38: #define nt_suspc       nt_ltchr.t_suspc
                     39: #define nt_dsuspc      nt_ltchr.t_dsuspc
                     40: #define nt_rprntc      nt_ltchr.t_rprntc
                     41: #define nt_flushc      nt_ltchr.t_flushc
                     42: #define nt_werasc      nt_ltchr.t_werasc
                     43: #define nt_lnextc      nt_ltchr.t_lnextc
                     44: #define nt_urotc       nt_luchr.t_urotc
                     45: };
                     46: 
                     47: 
                     48: /*
                     49:  * values for nt_state:
                     50:  */
                     51: #define NT_STOP                001     /* stopped by stop character */
                     52: #define NT_ESC         002     /* have just seen \ or lnext character */
                     53: #define NT_CR          004     /* turning LF into CRLF */
                     54: #define NT_USE         010     /* nttyld structure in use */
                     55: #define NT_CASE                020     /* adding \ for upper-case-only terminals */
                     56: #define NT_ECHO                040     /* echoed something for ntin */
                     57: 
                     58: 
                     59: /*
                     60:  * default local special characters (struct ltchars)
                     61:  */
                     62: #define CSUSP  CTRL(z)
                     63: #define CDSUSP CTRL(y)
                     64: #define CRPRNT CTRL(r)
                     65: #define CFLUSH CTRL(o)
                     66: #define CWERAS CTRL(w)
                     67: #define CLNEXT CTRL(v)
                     68: 
                     69: 
                     70: /*
                     71:  * Ioctl message format.
                     72:  */
                     73: 
                     74: struct ntioc {
                     75:        int     command;
                     76: 
                     77:        union {
                     78:                struct sgttyb   sg;
                     79:                struct tchars   tchr;
                     80:                struct ltchars  ltchr;
                     81:                short           local;
                     82:                char            chr[16];
                     83:        } arg;
                     84: };

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.