1/* 2 * Copyright (C) 1995 by Pavel Antonov, Moscow, Russia. 3 * Copyright (C) 1995 by Andrey A. Chernov, Moscow, Russia. 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 19 unchanged lines hidden (view full) --- 28/* 29 * SDL Communications Riscom/8 (based on Cirrus Logic CL-CD180) driver 30 * 31 */ 32 33#include "rc.h" 34 35#if NRC > 0 |
36/*#define RCDEBUG*/ 37 38#include <sys/param.h> 39#include <sys/systm.h> 40#include <sys/tty.h> 41#include <sys/proc.h> 42#include <sys/conf.h> 43#include <sys/dkstat.h> 44#include <sys/fcntl.h> 45#include <sys/interrupt.h> 46#include <sys/kernel.h> |
47#include <machine/clock.h> 48#include <machine/ipl.h> 49 50#include <i386/isa/isa_device.h> 51 52#include <i386/isa/ic/cd180.h> 53#include <i386/isa/rcreg.h> 54 --- 82 unchanged lines hidden (view full) --- 137 struct tty *rc_tp; /* tty struct */ 138 u_char *rc_iptr; /* Chars input buffer */ 139 u_char *rc_hiwat; /* hi-water mark */ 140 u_char *rc_bufend; /* end of buffer */ 141 u_char *rc_optr; /* ptr in output buf */ 142 u_char *rc_obufend; /* end of output buf */ 143 u_char rc_ibuf[4 * RC_IBUFSIZE]; /* input buffer */ 144 u_char rc_obuf[RC_OBUFSIZE]; /* output buffer */ |
145} rc_chans[NRC * CD180_NCHAN]; 146 147static int rc_scheduled_event = 0; 148 149/* for pstat -t */ 150static struct tty rc_tty[NRC * CD180_NCHAN]; 151static const int nrc_tty = NRC * CD180_NCHAN; 152 --- 107 unchanged lines hidden (view full) --- 260 rc->rc_dtrwait = 3 * hz; 261 rc->rc_dcdwaits= 0; 262 rc->rc_hotchar = 0; 263 tp = rc->rc_tp = &rc_tty[chan + (dvp->id_unit * CD180_NCHAN)]; 264 ttychars(tp); 265 tp->t_lflag = tp->t_iflag = tp->t_oflag = 0; 266 tp->t_cflag = TTYDEF_CFLAG; 267 tp->t_ispeed = tp->t_ospeed = TTYDEF_SPEED; |
268 } 269 rcb->rcb_probed = RC_ATTACHED; 270 if (!rc_started) { 271 cdevsw_add(&rc_cdevsw); 272 register_swi(SWI_TTY, rcpoll); 273 rc_wakeup((void *)NULL); 274 rc_started = 1; 275 } --- 1220 unchanged lines hidden --- |