The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/bsd/sys/ioctl_compat.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /*
    2  * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
    3  *
    4  * @APPLE_LICENSE_HEADER_START@
    5  * 
    6  * Copyright (c) 1999-2003 Apple Computer, Inc.  All Rights Reserved.
    7  * 
    8  * This file contains Original Code and/or Modifications of Original Code
    9  * as defined in and that are subject to the Apple Public Source License
   10  * Version 2.0 (the 'License'). You may not use this file except in
   11  * compliance with the License. Please obtain a copy of the License at
   12  * http://www.opensource.apple.com/apsl/ and read it before using this
   13  * file.
   14  * 
   15  * The Original Code and all software distributed under the License are
   16  * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
   17  * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
   18  * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
   19  * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
   20  * Please see the License for the specific language governing rights and
   21  * limitations under the License.
   22  * 
   23  * @APPLE_LICENSE_HEADER_END@
   24  */
   25 /* Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved */
   26 /*
   27  * Copyright (c) 1990, 1993
   28  *      The Regents of the University of California.  All rights reserved.
   29  * (c) UNIX System Laboratories, Inc.
   30  * All or some portions of this file are derived from material licensed
   31  * to the University of California by American Telephone and Telegraph
   32  * Co. or Unix System Laboratories, Inc. and are reproduced herein with
   33  * the permission of UNIX System Laboratories, Inc.
   34  *
   35  * Redistribution and use in source and binary forms, with or without
   36  * modification, are permitted provided that the following conditions
   37  * are met:
   38  * 1. Redistributions of source code must retain the above copyright
   39  *    notice, this list of conditions and the following disclaimer.
   40  * 2. Redistributions in binary form must reproduce the above copyright
   41  *    notice, this list of conditions and the following disclaimer in the
   42  *    documentation and/or other materials provided with the distribution.
   43  * 3. All advertising materials mentioning features or use of this software
   44  *    must display the following acknowledgement:
   45  *      This product includes software developed by the University of
   46  *      California, Berkeley and its contributors.
   47  * 4. Neither the name of the University nor the names of its contributors
   48  *    may be used to endorse or promote products derived from this software
   49  *    without specific prior written permission.
   50  *
   51  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
   52  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   53  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   54  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
   55  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
   56  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
   57  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
   58  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
   59  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
   60  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   61  * SUCH DAMAGE.
   62  *
   63  *      @(#)ioctl_compat.h      8.4 (Berkeley) 1/21/94
   64  */
   65 
   66 #ifndef _SYS_IOCTL_COMPAT_H_
   67 #define _SYS_IOCTL_COMPAT_H_
   68 
   69 #include <sys/ttychars.h>
   70 #include <sys/ttydev.h>
   71 
   72 struct tchars {
   73         char    t_intrc;        /* interrupt */
   74         char    t_quitc;        /* quit */
   75         char    t_startc;       /* start output */
   76         char    t_stopc;        /* stop output */
   77         char    t_eofc;         /* end-of-file */
   78         char    t_brkc;         /* input delimiter (like nl) */
   79 };
   80 
   81 struct ltchars {
   82         char    t_suspc;        /* stop process signal */
   83         char    t_dsuspc;       /* delayed stop process signal */
   84         char    t_rprntc;       /* reprint line */
   85         char    t_flushc;       /* flush output (toggles) */
   86         char    t_werasc;       /* word erase */
   87         char    t_lnextc;       /* literal next character */
   88 };
   89 
   90 /*
   91  * Structure for TIOCGETP and TIOCSETP ioctls.
   92  */
   93 #ifndef _SGTTYB_
   94 #define _SGTTYB_
   95 struct sgttyb {
   96         char    sg_ispeed;              /* input speed */
   97         char    sg_ospeed;              /* output speed */
   98         char    sg_erase;               /* erase character */
   99         char    sg_kill;                /* kill character */
  100         short   sg_flags;               /* mode flags */
  101 };
  102 #endif
  103 
  104 #ifdef USE_OLD_TTY
  105 # undef  TIOCGETD
  106 # define TIOCGETD       _IOR('t', 0, int)       /* get line discipline */
  107 # undef  TIOCSETD
  108 # define TIOCSETD       _IOW('t', 1, int)       /* set line discipline */
  109 #else
  110 # define OTIOCGETD      _IOR('t', 0, int)       /* get line discipline */
  111 # define OTIOCSETD      _IOW('t', 1, int)       /* set line discipline */
  112 #endif
  113 #define TIOCHPCL        _IO('t', 2)             /* hang up on last close */
  114 #define TIOCGETP        _IOR('t', 8,struct sgttyb)/* get parameters -- gtty */
  115 #define TIOCSETP        _IOW('t', 9,struct sgttyb)/* set parameters -- stty */
  116 #define TIOCSETN        _IOW('t',10,struct sgttyb)/* as above, but no flushtty*/
  117 #define TIOCSETC        _IOW('t',17,struct tchars)/* set special characters */
  118 #define TIOCGETC        _IOR('t',18,struct tchars)/* get special characters */
  119 #define         TANDEM          0x00000001      /* send stopc on out q full */
  120 #define         CBREAK          0x00000002      /* half-cooked mode */
  121 #define         LCASE           0x00000004      /* simulate lower case */
  122 #define         ECHO            0x00000008      /* echo input */
  123 #define         CRMOD           0x00000010      /* map \r to \r\n on output */
  124 #define         RAW             0x00000020      /* no i/o processing */
  125 #define         ODDP            0x00000040      /* get/send odd parity */
  126 #define         EVENP           0x00000080      /* get/send even parity */
  127 #define         ANYP            0x000000c0      /* get any parity/send none */
  128 #define         NLDELAY         0x00000300      /* \n delay */
  129 #define                 NL0     0x00000000
  130 #define                 NL1     0x00000100      /* tty 37 */
  131 #define                 NL2     0x00000200      /* vt05 */
  132 #define                 NL3     0x00000300
  133 #define         TBDELAY         0x00000c00      /* horizontal tab delay */
  134 #define                 TAB0    0x00000000
  135 #define                 TAB1    0x00000400      /* tty 37 */
  136 #define                 TAB2    0x00000800
  137 #define         XTABS           0x00000c00      /* expand tabs on output */
  138 #define         CRDELAY         0x00003000      /* \r delay */
  139 #define                 CR0     0x00000000
  140 #define                 CR1     0x00001000      /* tn 300 */
  141 #define                 CR2     0x00002000      /* tty 37 */
  142 #define                 CR3     0x00003000      /* concept 100 */
  143 #define         VTDELAY         0x00004000      /* vertical tab delay */
  144 #define                 FF0     0x00000000
  145 #define                 FF1     0x00004000      /* tty 37 */
  146 #define         BSDELAY         0x00008000      /* \b delay */
  147 #define                 BS0     0x00000000
  148 #define                 BS1     0x00008000
  149 #define         ALLDELAY        (NLDELAY|TBDELAY|CRDELAY|VTDELAY|BSDELAY)
  150 #define         CRTBS           0x00010000      /* do backspacing for crt */
  151 #define         PRTERA          0x00020000      /* \ ... / erase */
  152 #define         CRTERA          0x00040000      /* " \b " to wipe out char */
  153 #define         TILDE           0x00080000      /* hazeltine tilde kludge */
  154 #define         MDMBUF          0x00100000      /*start/stop output on carrier*/
  155 #define         LITOUT          0x00200000      /* literal output */
  156 #define         TOSTOP          0x00400000      /*SIGSTOP on background output*/
  157 #define         FLUSHO          0x00800000      /* flush output to terminal */
  158 #define         NOHANG          0x01000000      /* (no-op) was no SIGHUP on carrier drop */
  159 #define         L001000         0x02000000
  160 #define         CRTKIL          0x04000000      /* kill line with " \b " */
  161 #define         PASS8           0x08000000
  162 #define         CTLECH          0x10000000      /* echo control chars as ^X */
  163 #define         PENDIN          0x20000000      /* tp->t_rawq needs reread */
  164 #define         DECCTQ          0x40000000      /* only ^Q starts after ^S */
  165 #define         NOFLSH          0x80000000      /* no output flush on signal */
  166 #define TIOCLBIS        _IOW('t', 127, int)     /* bis local mode bits */
  167 #define TIOCLBIC        _IOW('t', 126, int)     /* bic local mode bits */
  168 #define TIOCLSET        _IOW('t', 125, int)     /* set entire local mode word */
  169 #define TIOCLGET        _IOR('t', 124, int)     /* get local modes */
  170 #define         LCRTBS          (CRTBS>>16)
  171 #define         LPRTERA         (PRTERA>>16)
  172 #define         LCRTERA         (CRTERA>>16)
  173 #define         LTILDE          (TILDE>>16)
  174 #define         LMDMBUF         (MDMBUF>>16)
  175 #define         LLITOUT         (LITOUT>>16)
  176 #define         LTOSTOP         (TOSTOP>>16)
  177 #define         LFLUSHO         (FLUSHO>>16)
  178 #define         LNOHANG         (NOHANG>>16)
  179 #define         LCRTKIL         (CRTKIL>>16)
  180 #define         LPASS8          (PASS8>>16)
  181 #define         LCTLECH         (CTLECH>>16)
  182 #define         LPENDIN         (PENDIN>>16)
  183 #define         LDECCTQ         (DECCTQ>>16)
  184 #define         LNOFLSH         (NOFLSH>>16)
  185 #define TIOCSLTC        _IOW('t',117,struct ltchars)/* set local special chars*/
  186 #define TIOCGLTC        _IOR('t',116,struct ltchars)/* get local special chars*/
  187 #define OTIOCCONS       _IO('t', 98)    /* for hp300 -- sans int arg */
  188 #define OTTYDISC        0
  189 #define NETLDISC        1
  190 #define NTTYDISC        2
  191 
  192 #define TIOCGSID        _IOR('t', 99, int)      /* For svr4 -- get session id */
  193 
  194 #endif /* !_SYS_IOCTL_COMPAT_H_ */

Cache object: 0c73f621843d3a2cc70243301271126c


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.