home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 15 / 15.iso / s / s053 / 8.ddi / usr / include / sys / ioctl.h < prev    next >
Encoding:
C/C++ Source or Header  |  1990-12-08  |  3.2 KB  |  124 lines

  1. /*    Copyright (c) 1990 UNIX System Laboratories, Inc.    */
  2. /*    Copyright (c) 1984, 1986, 1987, 1988, 1989, 1990 AT&T    */
  3. /*      All Rights Reserved      */
  4.  
  5. /*    THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF         */
  6. /*    UNIX System Laboratories, Inc.                         */
  7. /*    The copyright notice above does not evidence any       */
  8. /*    actual or intended publication of such source code.    */
  9.  
  10. #ifndef _SYS_IOCTL_H
  11. #define _SYS_IOCTL_H
  12.  
  13. #ident    "@(#)/usr/include/sys/ioctl.h.sl 1.1 4.0 12/08/90 50934 AT&T-USL"
  14. /*
  15.  *      There are some inherent problems in having a single file
  16.  *      ioctl.h, with both System V and BSD flags. Introducing
  17.  *  BSD flags into this file creates compilation problems
  18.  *  with flags such as ECHO, NL1 etc., if termio.h and ioctl.h
  19.  *      are included by the same file. Since these two files can
  20.  *  be only included by System V applications, /usr/inclule/sys/ioctl.h
  21.  *      will be System V mode and all the BSD flags will be turned off
  22.  *      using #ifdef BSD_COMP. This file will also exist in
  23.  *  /usr/ucbinclude/sys/ioctl.h for BSD applications but without the
  24.  *      BSD flags turned off. System V appliactions can use ioctl.h without
  25.  *      any changes, System V applications requiring BSD flags should
  26.  *      -D BSD_COMP when compiling (and be warned about the common
  27.  *      flags between System V and BSD) and BSD applications should
  28.  *  use /usr/ucbinclude/sys/ioctl.h.
  29.  *
  30.  */
  31.  
  32. /*
  33.  *    Ioctl commands
  34.  */
  35.  
  36.  
  37. /* BSD related defines */
  38.  
  39. #ifdef BSD_COMP
  40.  
  41. #include <sys/ttychars.h>
  42. #include <sys/ttydev.h>
  43. #include <sys/ttold.h>
  44.  
  45.  
  46. #define    TANDEM        O_TANDEM
  47. #define    CBREAK        O_CBREAK
  48. #ifndef _SGTTY_H
  49. #define    LCASE        O_LCASE
  50. #define    ECHO        O_ECHO
  51. #define    CRMOD        O_CRMOD
  52. #define    RAW        O_RAW
  53. #define    ODDP        O_ODDP
  54. #define    EVENP        O_EVENP
  55. #define    ANYP        O_ANYP
  56. #define    NLDELAY        O_NLDELAY
  57. #define        NL0        O_NL0
  58. #define        NL1        O_NL1
  59. #define        NL2        O_NL2
  60. #define        NL3        O_NL3
  61. #define    TBDELAY        O_TBDELAY
  62. #define        TAB0        O_TAB0
  63. #define        TAB1        O_TAB1
  64. #define        TAB2        O_TAB2
  65. #define    XTABS        O_XTABS
  66. #define    CRDELAY        O_CRDELAY
  67. #define        CR0        O_CR0
  68. #define        CR1        O_CR1
  69. #define        CR2        O_CR2
  70. #define        CR3        O_CR3
  71. #define    VTDELAY        O_VTDELAY
  72. #define        FF0        O_FF0
  73. #define        FF1        O_FF1
  74. #define    BSDELAY        O_BSDELAY
  75. #define        BS0        O_BS0
  76. #define        BS1        O_BS1
  77. #define     ALLDELAY    O_ALLDELAY
  78. #endif /* _SGTTY_H */
  79. #define    CRTBS        O_CRTBS
  80. #define    PRTERA        O_PRTERA
  81. #define    CRTERA        O_CRTERA
  82. #define    TILDE        O_TILDE
  83. #define    MDMBUF        O_MDMBUF
  84. #define    LITOUT        O_LITOUT
  85. #define    TOSTOP        O_TOSTOP
  86. #define    FLUSHO        O_FLUSHO
  87. #define    NOHANG        O_NOHANG
  88. #define    L001000        O_L001000
  89. #define    CRTKIL        O_CRTKIL
  90. #define    PASS8        O_PASS8
  91. #define    CTLECH        O_CTLECH
  92. #define    PENDIN        O_PENDIN
  93. #define    DECCTQ        O_DECCTQ
  94. #define    NOFLSH        O_NOFLSH
  95.  
  96. #include <sys/filio.h>
  97. #include <sys/sockio.h>
  98.  
  99. #endif /* BSD_COMP */
  100.  
  101.  
  102. /*
  103. **    Union for use by all device handler ioctl routines.
  104. */
  105. union ioctl_arg {
  106.     struct termio    *stparg;    /* ptr to termio struct */
  107.     struct Generic    *sparg;        /* ptr to generic struct */
  108.     char        *cparg;        /* ptr to character */
  109.     char        carg;        /* character */
  110.     int        *iparg;        /* ptr to integer */
  111.     int        iarg;        /* integer */
  112.     long            *lparg;         /* ptr to long */
  113.     long            larg;           /* long */
  114. };
  115.  
  116. /*
  117.  * Commands needed for XENIX ioctl() compatibility
  118.  */
  119.  
  120. #define    TIOC    ('T'<<8)
  121. #define    TCFLSH    (TIOC|7)
  122.  
  123. #endif    /* _SYS_IOCTL_H */
  124.