/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
/*
* merged together.
*/
#include "uucp.h"
static struct sg_spds {
int sp_val,
} spds[] = {
{ 50, B50},
{ 75, B75},
{ 110, B110},
{ 134, B134},
{ 150, B150},
{ 200, B200},
{ 300, B300},
{ 600, B600},
{1200, B1200},
{1800, B1800},
{2400, B2400},
{4800, B4800},
{9600, B9600},
#ifdef EXTA
{19200, EXTA},
#endif
#ifdef B19200
{19200, B19200},
#endif
#ifdef B38400
{38400, B38400},
#endif
{57600, B57600},
{76800, B76800},
{115200, B115200},
{153600, B153600},
{230400, B230400},
{307200, B307200},
{460800, B460800},
{921600, B921600},
{0, 0}
};
GLOBAL int
#ifdef PKSPEEDUP
#endif /* PKSPEEDUP */
GLOBAL int
#ifdef ATTSVTTY
/*
* tty -> terminal name
* spwant -> speed
* type -> type
*
* if spwant == 0, speed is untouched
* type is unused, but needed for compatibility
*
* return:
* none
*/
/*ARGSUSED*/
GLOBAL void
{
return;
} else {
for (i = 0; i < NCC; i++)
}
}
if (spwant > 0) {
break;
}
if (speed < 0)
} else { /* determine the current speed setting */
break;
}
}
/*
* In order to prevent attempts at split speed, all baud rate
* bitfields should be cleared. Thus cfsetispeed is used to
* set the speed to zero.
*/
(void) cfsetispeed(&ttbufs, 0);
#ifdef PKSPEEDUP
#endif /* PKSPEEDUP */
#ifdef NO_MODEM_CTRL
/* CLOCAL may cause problems on pdp11s with DHs */
} else
#endif /* NO_MODEM_CTRL */
/* set attributes associated with -h, -t, -e, and -o options */
if (line_8bit) {
} else {
if (Evenflag) { /* even parity -e */
} else if (Oddflag) { /* odd parity -o */
}
}
if (!Duplex) /* half duplex -h */
if (Terminal) /* -t */
} else { /* non-uucico */
}
if (istermios < 0) {
for (i = 0; i < NCC; i++)
} else {
}
}
GLOBAL void
int dcf;
{
return;
}
}
GLOBAL void
register int fn;
{
}
/*
* optimize line setting for sending or receiving files
* return:
* none
*/
GLOBAL void
register char type;
{
return;
} else {
for (i = 0; i < NCC; i++)
}
}
switch (type) {
case RCVFILE:
switch (ospeed) {
#ifdef B19200
case B19200:
#else
#ifdef EXTA
case EXTA:
#endif
#endif
#ifdef B38400
case B38400:
#endif
case B57600:
case B76800:
case B115200:
case B153600:
case B230400:
case B307200:
case B460800:
case B921600:
case B9600:
vtime = 1;
break;
case B4800:
vtime = 4;
break;
default:
vtime = 8;
break;
}
if (istermios < 0) {
for (i = 0; i < NCC; i++)
errno);
} else {
DEBUG(4,
"setline Ioctl failed errno=%d\n",
errno);
}
}
break;
case SNDFILE:
case RESET:
if (istermios < 0) {
for (i = 0; i < NCC; i++)
DEBUG(4,
"setline Ioctl failed errno=%d\n",
errno);
} else {
DEBUG(4,
"setline Ioctl failed errno=%d\n",
errno);
}
}
break;
}
}
GLOBAL int
savline()
{
Saved_line = FALSE;
} else {
Saved_line = TRUE;
}
} else {
Saved_line = TRUE;
}
return (0);
}
#ifdef SYTEK
/*
* int tty, spwant;
*
* return codes: none
*/
GLOBAL void
{
return;
} else {
for (i = 0; i < NCC; i++)
}
}
if (istermios < 0) {
for (i = 0; i < NCC; i++)
} else
}
GLOBAL void
int tty;
{
int ret;
return;
}
#endif /* SYTEK */
GLOBAL int
restline()
{
if (Saved_line == TRUE) {
if (Saved_termios < 0)
else
}
return (0);
}
#else /* !ATTSVTTY */
/*
* int tty, spwant;
*
* if spwant == 0, speed is untouched
* type is unused, but needed for compatibility
*
* return codes: none
*/
/*ARGSUSED*/
GLOBAL void
{
return;
if (spwant > 0) {
break;
}
} else {
break;
}
}
#ifdef PKSPEEDUP
#endif /* PKSPEEDUP */
}
GLOBAL void
int dcf;
{
}
/*
* genbrk send a break
*
* return codes; none
*/
GLOBAL void
{
#ifndef V8
#endif
}
}
/*
* V7 and RT aren't smart enough for this -- linebaudrate is the best
* they can do.
*/
/*ARGSUSED*/
GLOBAL void
GLOBAL int
savline()
{
Saved_line = FALSE;
else {
Saved_line = TRUE;
}
return (0);
}
GLOBAL int
restline()
{
if (Saved_line == TRUE)
return (0);
}
#endif