tty.h (9823) | tty.h (9824) |
---|---|
1/*- 2 * Copyright (c) 1982, 1986, 1993 3 * The Regents of the University of California. All rights reserved. 4 * (c) UNIX System Laboratories, Inc. 5 * All or some portions of this file are derived from material licensed 6 * to the University of California by American Telephone and Telegraph 7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with 8 * the permission of UNIX System Laboratories, Inc. --- 22 unchanged lines hidden (view full) --- 31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 36 * SUCH DAMAGE. 37 * 38 * @(#)tty.h 8.6 (Berkeley) 1/21/94 | 1/*- 2 * Copyright (c) 1982, 1986, 1993 3 * The Regents of the University of California. All rights reserved. 4 * (c) UNIX System Laboratories, Inc. 5 * All or some portions of this file are derived from material licensed 6 * to the University of California by American Telephone and Telegraph 7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with 8 * the permission of UNIX System Laboratories, Inc. --- 22 unchanged lines hidden (view full) --- 31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 36 * SUCH DAMAGE. 37 * 38 * @(#)tty.h 8.6 (Berkeley) 1/21/94 |
39 * $Id: tty.h,v 1.27 1995/07/31 18:29:37 bde Exp $ | 39 * $Id: tty.h,v 1.28 1995/07/31 19:17:19 bde Exp $ |
40 */ 41 42#ifndef _SYS_TTY_H_ 43#define _SYS_TTY_H_ 44 45#include <sys/termios.h> 46#include <sys/select.h> /* For struct selinfo. */ 47 --- 101 unchanged lines hidden (view full) --- 149#define TS_CNTTB 0x01000 /* Counting tab width, ignore FLUSHO. */ 150#define TS_ERASE 0x02000 /* Within a \.../ for PRTRUB. */ 151#define TS_LNCH 0x04000 /* Next character is literal. */ 152#define TS_TYPEN 0x08000 /* Retyping suspended input (PENDIN). */ 153#define TS_LOCAL (TS_BKSL | TS_CNTTB | TS_ERASE | TS_LNCH | TS_TYPEN) 154 155/* Extras. */ 156#define TS_CAN_BYPASS_L_RINT 0x010000 /* Device in "raw" mode. */ | 40 */ 41 42#ifndef _SYS_TTY_H_ 43#define _SYS_TTY_H_ 44 45#include <sys/termios.h> 46#include <sys/select.h> /* For struct selinfo. */ 47 --- 101 unchanged lines hidden (view full) --- 149#define TS_CNTTB 0x01000 /* Counting tab width, ignore FLUSHO. */ 150#define TS_ERASE 0x02000 /* Within a \.../ for PRTRUB. */ 151#define TS_LNCH 0x04000 /* Next character is literal. */ 152#define TS_TYPEN 0x08000 /* Retyping suspended input (PENDIN). */ 153#define TS_LOCAL (TS_BKSL | TS_CNTTB | TS_ERASE | TS_LNCH | TS_TYPEN) 154 155/* Extras. */ 156#define TS_CAN_BYPASS_L_RINT 0x010000 /* Device in "raw" mode. */ |
157#define TS_CONNECTED 0x020000 /* Connection open. */ |
|
157#define TS_SNOOP 0x040000 /* Device is being snooped on. */ 158#define TS_SO_OCOMPLETE 0x080000 /* Wake up when output completes. */ | 158#define TS_SNOOP 0x040000 /* Device is being snooped on. */ 159#define TS_SO_OCOMPLETE 0x080000 /* Wake up when output completes. */ |
160#define TS_ZOMBIE 0x100000 /* Connection lost. */ |
|
159 160/* Character type information. */ 161#define ORDINARY 0 162#define CONTROL 1 163#define BACKSPACE 2 164#define NEWLINE 3 165#define TAB 4 166#define VTAB 5 --- 23 unchanged lines hidden (view full) --- 190#define isctty(p, tp) \ 191 ((p)->p_session == (tp)->t_session && (p)->p_flag & P_CONTROLT) 192 193/* Is p in background of tp? */ 194#define isbackground(p, tp) \ 195 (isctty((p), (tp)) && (p)->p_pgrp != (tp)->t_pgrp) 196 197/* Unique sleep addresses. */ | 161 162/* Character type information. */ 163#define ORDINARY 0 164#define CONTROL 1 165#define BACKSPACE 2 166#define NEWLINE 3 167#define TAB 4 168#define VTAB 5 --- 23 unchanged lines hidden (view full) --- 192#define isctty(p, tp) \ 193 ((p)->p_session == (tp)->t_session && (p)->p_flag & P_CONTROLT) 194 195/* Is p in background of tp? */ 196#define isbackground(p, tp) \ 197 (isctty((p), (tp)) && (p)->p_pgrp != (tp)->t_pgrp) 198 199/* Unique sleep addresses. */ |
198#define TSA_CARR_ON(tp) ((void *)&(tp)->t_rawq) /* XXX overloaded */ | 200#define TSA_CARR_ON(tp) ((void *)&(tp)->t_rawq) 201#define TSA_HUP_OR_INPUT(tp) ((void *)&(tp)->t_rawq.c_cf) |
199#define TSA_OCOMPLETE(tp) ((void *)&(tp)->t_outq.c_cl) 200#define TSA_OLOWAT(tp) ((void *)&(tp)->t_outq) 201#define TSA_PTC_READ(tp) ((void *)&(tp)->t_outq.c_cf) 202#define TSA_PTC_WRITE(tp) ((void *)&(tp)->t_rawq.c_cl) 203#define TSA_PTS_READ(tp) ((void *)&(tp)->t_canq) 204 205#ifdef KERNEL 206extern struct tty *constty; /* Temporary virtual console. */ --- 58 unchanged lines hidden --- | 202#define TSA_OCOMPLETE(tp) ((void *)&(tp)->t_outq.c_cl) 203#define TSA_OLOWAT(tp) ((void *)&(tp)->t_outq) 204#define TSA_PTC_READ(tp) ((void *)&(tp)->t_outq.c_cf) 205#define TSA_PTC_WRITE(tp) ((void *)&(tp)->t_rawq.c_cl) 206#define TSA_PTS_READ(tp) ((void *)&(tp)->t_canq) 207 208#ifdef KERNEL 209extern struct tty *constty; /* Temporary virtual console. */ --- 58 unchanged lines hidden --- |