1*7c478bd9Sstevel@tonic-gate /* 2*7c478bd9Sstevel@tonic-gate * CDDL HEADER START 3*7c478bd9Sstevel@tonic-gate * 4*7c478bd9Sstevel@tonic-gate * The contents of this file are subject to the terms of the 5*7c478bd9Sstevel@tonic-gate * Common Development and Distribution License, Version 1.0 only 6*7c478bd9Sstevel@tonic-gate * (the "License"). You may not use this file except in compliance 7*7c478bd9Sstevel@tonic-gate * with the License. 8*7c478bd9Sstevel@tonic-gate * 9*7c478bd9Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10*7c478bd9Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 11*7c478bd9Sstevel@tonic-gate * See the License for the specific language governing permissions 12*7c478bd9Sstevel@tonic-gate * and limitations under the License. 13*7c478bd9Sstevel@tonic-gate * 14*7c478bd9Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 15*7c478bd9Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16*7c478bd9Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 17*7c478bd9Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 18*7c478bd9Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 19*7c478bd9Sstevel@tonic-gate * 20*7c478bd9Sstevel@tonic-gate * CDDL HEADER END 21*7c478bd9Sstevel@tonic-gate */ 22*7c478bd9Sstevel@tonic-gate /* 23*7c478bd9Sstevel@tonic-gate * Copyright (c) 1983, 1991, by Sun Microsystems, Inc. 24*7c478bd9Sstevel@tonic-gate */ 25*7c478bd9Sstevel@tonic-gate 26*7c478bd9Sstevel@tonic-gate #ifndef _SYS_SER_ZSCC_H 27*7c478bd9Sstevel@tonic-gate #define _SYS_SER_ZSCC_H 28*7c478bd9Sstevel@tonic-gate 29*7c478bd9Sstevel@tonic-gate #pragma ident "%Z%%M% %I% %E% SMI" 30*7c478bd9Sstevel@tonic-gate 31*7c478bd9Sstevel@tonic-gate /* 32*7c478bd9Sstevel@tonic-gate * Zilog 8530 SCC Serial Communications Controller 33*7c478bd9Sstevel@tonic-gate * 34*7c478bd9Sstevel@tonic-gate * This is a dual uart chip with on-chip baud rate generators. 35*7c478bd9Sstevel@tonic-gate * It is about as brain-damaged as the typical modern uart chip, 36*7c478bd9Sstevel@tonic-gate * but it does have a lot of features as well as the usual lot of 37*7c478bd9Sstevel@tonic-gate * brain damage around addressing, write-onlyness, etc. 38*7c478bd9Sstevel@tonic-gate */ 39*7c478bd9Sstevel@tonic-gate 40*7c478bd9Sstevel@tonic-gate #ifdef __cplusplus 41*7c478bd9Sstevel@tonic-gate extern "C" { 42*7c478bd9Sstevel@tonic-gate #endif 43*7c478bd9Sstevel@tonic-gate 44*7c478bd9Sstevel@tonic-gate /* 45*7c478bd9Sstevel@tonic-gate * SCC registers: 46*7c478bd9Sstevel@tonic-gate * 47*7c478bd9Sstevel@tonic-gate * There are 16 write registers and 9 read registers in each channel. 48*7c478bd9Sstevel@tonic-gate * As usual, the two channels are ALMOST orthogonal, not exactly. Most regs 49*7c478bd9Sstevel@tonic-gate * can only be written to, or read, but not both. To access one, you must 50*7c478bd9Sstevel@tonic-gate * first write to register 0 with the number of the register you 51*7c478bd9Sstevel@tonic-gate * are interested in, then read/write the actual value, and hope that 52*7c478bd9Sstevel@tonic-gate * nobody interrupts you in between. 53*7c478bd9Sstevel@tonic-gate */ 54*7c478bd9Sstevel@tonic-gate 55*7c478bd9Sstevel@tonic-gate /* bits in RR0 */ 56*7c478bd9Sstevel@tonic-gate #define ZSRR0_RX_READY 0x01 /* received character available */ 57*7c478bd9Sstevel@tonic-gate #define ZSRR0_TIMER 0x02 /* if R15_TIMER, timer reached 0 */ 58*7c478bd9Sstevel@tonic-gate #define ZSRR0_TX_READY 0x04 /* transmit buffer empty */ 59*7c478bd9Sstevel@tonic-gate #define ZSRR0_CD 0x08 /* CD input (latched if R15_CD) */ 60*7c478bd9Sstevel@tonic-gate #define ZSRR0_SYNC 0x10 /* SYNC input (latched if R15_SYNC) */ 61*7c478bd9Sstevel@tonic-gate #define ZSRR0_CTS 0x20 /* CTS input (latched if R15_CTS) */ 62*7c478bd9Sstevel@tonic-gate #define ZSRR0_TXUNDER 0x40 /* (SYNC) Xmitter underran */ 63*7c478bd9Sstevel@tonic-gate #define ZSRR0_BREAK 0x80 /* received break detected */ 64*7c478bd9Sstevel@tonic-gate 65*7c478bd9Sstevel@tonic-gate /* bits in RR1 */ 66*7c478bd9Sstevel@tonic-gate #define ZSRR1_ALL_SENT 0x01 /* all chars fully transmitted */ 67*7c478bd9Sstevel@tonic-gate #define ZSRR1_PE 0x10 /* parity error (latched, must reset) */ 68*7c478bd9Sstevel@tonic-gate #define ZSRR1_DO 0x20 /* data overrun (latched, must reset) */ 69*7c478bd9Sstevel@tonic-gate #define ZSRR1_FE 0x40 /* framing/CRC error (not latched) */ 70*7c478bd9Sstevel@tonic-gate #define ZSRR1_RXEOF 0x80 /* end of recv sdlc frame */ 71*7c478bd9Sstevel@tonic-gate 72*7c478bd9Sstevel@tonic-gate /* 73*7c478bd9Sstevel@tonic-gate * bits in R/WR2 -- interrupt vector number. 74*7c478bd9Sstevel@tonic-gate * 75*7c478bd9Sstevel@tonic-gate * NOTE that RR2 in channel A is unmodified, while in channel B it is 76*7c478bd9Sstevel@tonic-gate * modified by the current status of the UARTs. (This is independent 77*7c478bd9Sstevel@tonic-gate * of the setting of WR9_VIS.) If no interrupts are pending, the modified 78*7c478bd9Sstevel@tonic-gate * status is Channel B Special Receive. It can be written from 79*7c478bd9Sstevel@tonic-gate * either channel. 80*7c478bd9Sstevel@tonic-gate */ 81*7c478bd9Sstevel@tonic-gate 82*7c478bd9Sstevel@tonic-gate #define ZSR2_TX_EMPTY_B 0x0 83*7c478bd9Sstevel@tonic-gate #define ZSR2_XSINT_B 0x2 84*7c478bd9Sstevel@tonic-gate #define ZSR2_RX_AVAIL_B 0x4 85*7c478bd9Sstevel@tonic-gate #define ZSR2_SRINT_B_OR_NONE 0x6 86*7c478bd9Sstevel@tonic-gate #define ZSR2_TX_EMPTY_A 0x8 87*7c478bd9Sstevel@tonic-gate #define ZSR2_XSINT_A 0xA 88*7c478bd9Sstevel@tonic-gate #define ZSR2_RX_AVAIL_A 0xC 89*7c478bd9Sstevel@tonic-gate #define ZSR2_SRINT_A 0xE 90*7c478bd9Sstevel@tonic-gate 91*7c478bd9Sstevel@tonic-gate #define ZSR2_STATUS_ALL 0xE 92*7c478bd9Sstevel@tonic-gate 93*7c478bd9Sstevel@tonic-gate 94*7c478bd9Sstevel@tonic-gate /* 95*7c478bd9Sstevel@tonic-gate * bits in RR3 -- Interrupt Pending flags for both channels (this reg can 96*7c478bd9Sstevel@tonic-gate * only be read in Channel A, tho. Thanks guys.) 97*7c478bd9Sstevel@tonic-gate */ 98*7c478bd9Sstevel@tonic-gate #define ZSRR3_IP_B_STAT 0x01 /* Ext/status int pending, chan B */ 99*7c478bd9Sstevel@tonic-gate #define ZSRR3_IP_B_TX 0x02 /* Transmit int pending, chan B */ 100*7c478bd9Sstevel@tonic-gate #define ZSRR3_IP_B_RX 0x04 /* Receive int pending, chan B */ 101*7c478bd9Sstevel@tonic-gate #define ZSRR3_IP_A_STAT 0x08 /* Ditto for channel A */ 102*7c478bd9Sstevel@tonic-gate #define ZSRR3_IP_A_TX 0x10 103*7c478bd9Sstevel@tonic-gate #define ZSRR3_IP_A_RX 0x20 104*7c478bd9Sstevel@tonic-gate 105*7c478bd9Sstevel@tonic-gate /* bits in RR8 -- this is the same as reading the Data port */ 106*7c478bd9Sstevel@tonic-gate 107*7c478bd9Sstevel@tonic-gate /* bits in RR10 -- DPLL and SDLC Loop Mode status -- not entered */ 108*7c478bd9Sstevel@tonic-gate 109*7c478bd9Sstevel@tonic-gate /* bits in R/WR12 -- lower byte of time constant for baud rate generator */ 110*7c478bd9Sstevel@tonic-gate /* bits in R/WR13 -- upper byte of time constant for baud rate generator */ 111*7c478bd9Sstevel@tonic-gate 112*7c478bd9Sstevel@tonic-gate /* bits in R/WR15 -- interrupt enables for status conditions */ 113*7c478bd9Sstevel@tonic-gate #define ZSR15_TIMER 0x02 /* ie if baud rate generator = 0 */ 114*7c478bd9Sstevel@tonic-gate #define ZSR15_CD 0x08 /* ie transition on CD (car. det.) */ 115*7c478bd9Sstevel@tonic-gate #define ZSR15_SYNC 0x10 /* ie transition on SYNC (gen purp) */ 116*7c478bd9Sstevel@tonic-gate #define ZSR15_CTS 0x20 /* ie transition on CTS (clr to send) */ 117*7c478bd9Sstevel@tonic-gate #define ZSR15_TX_UNDER 0x40 /* (SYNC) ie transmit underrun */ 118*7c478bd9Sstevel@tonic-gate #define ZSR15_BREAK 0x80 /* ie on start, and end, of break */ 119*7c478bd9Sstevel@tonic-gate 120*7c478bd9Sstevel@tonic-gate /* Write register 0 -- common commands and Register Pointers */ 121*7c478bd9Sstevel@tonic-gate #define ZSWR0_REG 0x0F /* mask: next reg to read/write */ 122*7c478bd9Sstevel@tonic-gate #define ZSWR0_RESET_STATUS 0x10 /* reset status bit latches */ 123*7c478bd9Sstevel@tonic-gate #define ZSWR0_SEND_ABORT 0x18 /* SDLC: send abort */ 124*7c478bd9Sstevel@tonic-gate #define ZSWR0_FIRST_RX 0x20 /* in WR1_RX_FIRST_IE, enab next int */ 125*7c478bd9Sstevel@tonic-gate #define ZSWR0_RESET_TXINT 0x28 /* reset transmitter interrupt */ 126*7c478bd9Sstevel@tonic-gate #define ZSWR0_RESET_ERRORS 0x30 /* reset read character errors */ 127*7c478bd9Sstevel@tonic-gate #define ZSWR0_CLR_INTR 0x38 /* Reset Interrupt In Service */ 128*7c478bd9Sstevel@tonic-gate #define ZSWR0_RESET_RXCRC 0x40 /* Reset Rx CRC generator */ 129*7c478bd9Sstevel@tonic-gate #define ZSWR0_RESET_TXCRC 0x80 /* Reset Tx CRC generator */ 130*7c478bd9Sstevel@tonic-gate #define ZSWR0_RESET_EOM 0xC0 /* Reset Tx underrun / EOM */ 131*7c478bd9Sstevel@tonic-gate 132*7c478bd9Sstevel@tonic-gate /* bits in WR1 */ 133*7c478bd9Sstevel@tonic-gate #define ZSWR1_SIE 0x01 /* status change master int enable */ 134*7c478bd9Sstevel@tonic-gate /* Also see R15 for individual enabs */ 135*7c478bd9Sstevel@tonic-gate #define ZSWR1_TIE 0x02 /* transmitter interrupt enable */ 136*7c478bd9Sstevel@tonic-gate #define ZSWR1_PARITY_SPECIAL 0x04 /* parity err causes special rx int */ 137*7c478bd9Sstevel@tonic-gate #define ZSWR1_RIE_FIRST_SPECIAL 0x08 /* r.i.e. on 1st char of msg */ 138*7c478bd9Sstevel@tonic-gate #define ZSWR1_RIE 0x10 /* receiver interrupt enable */ 139*7c478bd9Sstevel@tonic-gate #define ZSWR1_RIE_SPECIAL_ONLY 0x18 /* rie on special only */ 140*7c478bd9Sstevel@tonic-gate #define ZSWR1_REQ_IS_RX 0x20 /* REQ pin is for receiver */ 141*7c478bd9Sstevel@tonic-gate #define ZSWR1_REQ_NOT_WAIT 0x40 /* REQ/WAIT pin is REQ */ 142*7c478bd9Sstevel@tonic-gate #define ZSWR1_REQ_ENABLE 0x80 /* enable REQ/WAIT */ 143*7c478bd9Sstevel@tonic-gate /* There are other Receive interrupt options defined, see data sheet. */ 144*7c478bd9Sstevel@tonic-gate 145*7c478bd9Sstevel@tonic-gate /* bits in WR2 are defined above as R/WR2. */ 146*7c478bd9Sstevel@tonic-gate 147*7c478bd9Sstevel@tonic-gate /* bits in WR3 */ 148*7c478bd9Sstevel@tonic-gate #define ZSWR3_RX_ENABLE 0x01 /* receiver enable */ 149*7c478bd9Sstevel@tonic-gate #define ZSWR3_RXCRC_ENABLE 0x08 /* receiver CRC enable */ 150*7c478bd9Sstevel@tonic-gate #define ZSWR3_HUNT 0x10 /* enter hunt mode */ 151*7c478bd9Sstevel@tonic-gate #define ZSWR3_AUTO_CD_CTS 0x20 /* auto-enable CD&CTS rcv&xmit ctl */ 152*7c478bd9Sstevel@tonic-gate #define ZSWR3_RX_5 0x00 /* receive 5-bit characters */ 153*7c478bd9Sstevel@tonic-gate #define ZSWR3_RX_6 0x80 /* receive 6 bit characters */ 154*7c478bd9Sstevel@tonic-gate #define ZSWR3_RX_7 0x40 /* receive 7 bit characters */ 155*7c478bd9Sstevel@tonic-gate #define ZSWR3_RX_8 0xC0 /* receive 8 bit characters */ 156*7c478bd9Sstevel@tonic-gate 157*7c478bd9Sstevel@tonic-gate /* bits in WR4 */ 158*7c478bd9Sstevel@tonic-gate #define ZSWR4_PARITY_ENABLE 0x01 /* Gen/check parity bit */ 159*7c478bd9Sstevel@tonic-gate #define ZSWR4_PARITY_EVEN 0x02 /* Gen/check even parity */ 160*7c478bd9Sstevel@tonic-gate #define ZSWR4_1_STOP 0x04 /* 1 stop bit */ 161*7c478bd9Sstevel@tonic-gate #define ZSWR4_1_5_STOP 0x08 /* 1.5 stop bits */ 162*7c478bd9Sstevel@tonic-gate #define ZSWR4_2_STOP 0x0C /* 2 stop bits */ 163*7c478bd9Sstevel@tonic-gate #define ZSWR4_BISYNC 0x10 /* Bisync mode */ 164*7c478bd9Sstevel@tonic-gate #define ZSWR4_SDLC 0x20 /* SDLC mode */ 165*7c478bd9Sstevel@tonic-gate #define ZSWR4_X1_CLK 0x00 /* clock is 1x */ 166*7c478bd9Sstevel@tonic-gate #define ZSWR4_X16_CLK 0x40 /* clock is 16x */ 167*7c478bd9Sstevel@tonic-gate #define ZSWR4_X32_CLK 0x80 /* clock is 32x */ 168*7c478bd9Sstevel@tonic-gate #define ZSWR4_X64_CLK 0xC0 /* clock is 64x */ 169*7c478bd9Sstevel@tonic-gate 170*7c478bd9Sstevel@tonic-gate /* bits in WR5 */ 171*7c478bd9Sstevel@tonic-gate #define ZSWR5_TXCRC_ENABLE 0x01 /* transmitter CRC enable */ 172*7c478bd9Sstevel@tonic-gate #define ZSWR5_RTS 0x02 /* RTS output */ 173*7c478bd9Sstevel@tonic-gate #define ZSWR5_CRC16 0x04 /* Use CRC-16 for checksum */ 174*7c478bd9Sstevel@tonic-gate #define ZSWR5_TX_ENABLE 0x08 /* transmitter enable */ 175*7c478bd9Sstevel@tonic-gate #define ZSWR5_BREAK 0x10 /* send break continuously */ 176*7c478bd9Sstevel@tonic-gate #define ZSWR5_TX_5 0x00 /* transmit 5 bit chars or less */ 177*7c478bd9Sstevel@tonic-gate #define ZSWR5_TX_6 0x40 /* transmit 6 bit characters */ 178*7c478bd9Sstevel@tonic-gate #define ZSWR5_TX_7 0x20 /* transmit 7 bit characters */ 179*7c478bd9Sstevel@tonic-gate #define ZSWR5_TX_8 0x60 /* transmit 8 bit characters */ 180*7c478bd9Sstevel@tonic-gate #define ZSWR5_DTR 0x80 /* DTR output */ 181*7c478bd9Sstevel@tonic-gate 182*7c478bd9Sstevel@tonic-gate /* bits in WR6 -- Sync characters or SDLC address field. */ 183*7c478bd9Sstevel@tonic-gate 184*7c478bd9Sstevel@tonic-gate /* bits in WR7 -- Sync character or SDLC flag */ 185*7c478bd9Sstevel@tonic-gate 186*7c478bd9Sstevel@tonic-gate /* bits in WR8 -- transmit buffer. Same as writing to data port. */ 187*7c478bd9Sstevel@tonic-gate 188*7c478bd9Sstevel@tonic-gate /* 189*7c478bd9Sstevel@tonic-gate * bits in WR9 -- Master interrupt control and reset. Accessible thru 190*7c478bd9Sstevel@tonic-gate * either channel, there's only one of them. 191*7c478bd9Sstevel@tonic-gate */ 192*7c478bd9Sstevel@tonic-gate #define ZSWR9_VECTOR_INCL_STAT 0x01 /* Include status bits in int vector */ 193*7c478bd9Sstevel@tonic-gate #define ZSWR9_NO_VECTOR 0x02 /* Do not respond to int ack cycles */ 194*7c478bd9Sstevel@tonic-gate #define ZSWR9_DIS_LOWER_CHAIN 0x04 /* Disable ints lower in daisy chain */ 195*7c478bd9Sstevel@tonic-gate #define ZSWR9_MASTER_IE 0x08 /* Master interrupt enable */ 196*7c478bd9Sstevel@tonic-gate #define ZSWR9_STAT_HIGH 0x10 /* Modify ivec bits 6-4, not 1-3 */ 197*7c478bd9Sstevel@tonic-gate #define ZSWR9_RESET_CHAN_B 0x40 /* Reset just channel B */ 198*7c478bd9Sstevel@tonic-gate #define ZSWR9_RESET_CHAN_A 0x80 /* Reset just channel A */ 199*7c478bd9Sstevel@tonic-gate #define ZSWR9_RESET_WORLD 0xC0 /* Force hardware reset */ 200*7c478bd9Sstevel@tonic-gate 201*7c478bd9Sstevel@tonic-gate /* bits in WR10 -- SDLC, NRZI, FM control bits */ 202*7c478bd9Sstevel@tonic-gate #define ZSWR10_UNDERRUN_ABORT 0x04 /* send abort on TX underrun */ 203*7c478bd9Sstevel@tonic-gate #define ZSWR10_NRZI 0x20 /* NRZI mode (SDLC) */ 204*7c478bd9Sstevel@tonic-gate #define ZSWR10_PRESET_ONES 0x80 /* preset CRC to ones (SDLC) */ 205*7c478bd9Sstevel@tonic-gate 206*7c478bd9Sstevel@tonic-gate /* bits in WR11 -- clock mode control */ 207*7c478bd9Sstevel@tonic-gate #define ZSWR11_TRXC_XTAL 0x00 /* TRxC output = xtal osc */ 208*7c478bd9Sstevel@tonic-gate #define ZSWR11_TRXC_XMIT 0x01 /* TRxC output = xmitter clk */ 209*7c478bd9Sstevel@tonic-gate #define ZSWR11_TRXC_BAUD 0x02 /* TRxC output = baud rate gen */ 210*7c478bd9Sstevel@tonic-gate #define ZSWR11_TRXC_DPLL 0x03 /* TRxC output = Phase Locked Loop */ 211*7c478bd9Sstevel@tonic-gate #define ZSWR11_TRXC_OUT_ENA 0x04 /* TRxC output enable (unless input) */ 212*7c478bd9Sstevel@tonic-gate #define ZSWR11_TXCLK_RTXC 0x00 /* Tx clock is RTxC pin */ 213*7c478bd9Sstevel@tonic-gate #define ZSWR11_TXCLK_TRXC 0x08 /* Tx clock is TRxC pin */ 214*7c478bd9Sstevel@tonic-gate #define ZSWR11_TXCLK_BAUD 0x10 /* Tx clock is baud rate gen output */ 215*7c478bd9Sstevel@tonic-gate #define ZSWR11_TXCLK_DPLL 0x18 /* Tx clock is Phase Locked Loop o/p */ 216*7c478bd9Sstevel@tonic-gate #define ZSWR11_RXCLK_RTXC 0x00 /* Rx clock is RTxC pin */ 217*7c478bd9Sstevel@tonic-gate #define ZSWR11_RXCLK_TRXC 0x20 /* Rx clock is TRxC pin */ 218*7c478bd9Sstevel@tonic-gate #define ZSWR11_RXCLK_BAUD 0x40 /* Rx clock is baud rate gen output */ 219*7c478bd9Sstevel@tonic-gate #define ZSWR11_RXCLK_DPLL 0x60 /* Rx clock is Phase Locked Loop o/p */ 220*7c478bd9Sstevel@tonic-gate #define ZSWR11_RTXC_XTAL 0x80 /* RTxC uses crystal, not TTL signal */ 221*7c478bd9Sstevel@tonic-gate 222*7c478bd9Sstevel@tonic-gate /* bits in WR12 -- described above as R/WR12 */ 223*7c478bd9Sstevel@tonic-gate 224*7c478bd9Sstevel@tonic-gate /* bits in WR13 -- described above as R/WR13 */ 225*7c478bd9Sstevel@tonic-gate 226*7c478bd9Sstevel@tonic-gate /* bits in WR14 -- misc control bits, and DPLL control */ 227*7c478bd9Sstevel@tonic-gate #define ZSWR14_BAUD_ENA 0x01 /* enables baud rate counter */ 228*7c478bd9Sstevel@tonic-gate #define ZSWR14_BAUD_FROM_PCLK 0x02 /* Baud rate gen src = PCLK not RTxC */ 229*7c478bd9Sstevel@tonic-gate #define ZSWR14_DTR_IS_REQUEST 0x04 /* Changes DTR line to DMA Request */ 230*7c478bd9Sstevel@tonic-gate #define ZSWR14_AUTO_ECHO 0x08 /* Echoes RXD to TXD */ 231*7c478bd9Sstevel@tonic-gate #define ZSWR14_LOCAL_LOOPBACK 0x10 /* Echoes TX to RX in chip */ 232*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_NOP 0x00 /* These 8 commands are mut. exclu. */ 233*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_SEARCH 0x20 /* Enter search mode in DPLL */ 234*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_RESET 0x40 /* Reset missing clock in DPLL */ 235*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_DISABLE 0x60 /* Disable DPLL */ 236*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_SRC_BAUD 0x80 /* Source for DPLL is baud rate gen */ 237*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_SRC_RTXC 0xA0 /* Source for DPLL is RTxC pin */ 238*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_FM 0xC0 /* DPLL should run in FM mode */ 239*7c478bd9Sstevel@tonic-gate #define ZSWR14_DPLL_NRZI 0xE0 /* DPLL should run in NRZI mode */ 240*7c478bd9Sstevel@tonic-gate 241*7c478bd9Sstevel@tonic-gate /* bits in WR15 -- described above as R/WR15 */ 242*7c478bd9Sstevel@tonic-gate 243*7c478bd9Sstevel@tonic-gate /* 244*7c478bd9Sstevel@tonic-gate * UART register addressing 245*7c478bd9Sstevel@tonic-gate * 246*7c478bd9Sstevel@tonic-gate * It would be nice if they used 4 address pins to address 15 registers, 247*7c478bd9Sstevel@tonic-gate * but they only used 1. So you have to write to the control port then 248*7c478bd9Sstevel@tonic-gate * read or write it; the 2nd cycle is done to whatever register number 249*7c478bd9Sstevel@tonic-gate * you wrote in the first cycle. 250*7c478bd9Sstevel@tonic-gate * 251*7c478bd9Sstevel@tonic-gate * The data register can also be accessed as Read/Write register 8. 252*7c478bd9Sstevel@tonic-gate */ 253*7c478bd9Sstevel@tonic-gate 254*7c478bd9Sstevel@tonic-gate #ifdef _KERNEL 255*7c478bd9Sstevel@tonic-gate struct zscc_device { 256*7c478bd9Sstevel@tonic-gate volatile unsigned char zscc_control; 257*7c478bd9Sstevel@tonic-gate volatile unsigned char :8; /* Filler */ 258*7c478bd9Sstevel@tonic-gate volatile unsigned char zscc_data; 259*7c478bd9Sstevel@tonic-gate volatile unsigned char :8; /* Filler */ 260*7c478bd9Sstevel@tonic-gate }; 261*7c478bd9Sstevel@tonic-gate 262*7c478bd9Sstevel@tonic-gate #define ZSOFF 4 263*7c478bd9Sstevel@tonic-gate 264*7c478bd9Sstevel@tonic-gate 265*7c478bd9Sstevel@tonic-gate #endif /* _KERNEL */ 266*7c478bd9Sstevel@tonic-gate 267*7c478bd9Sstevel@tonic-gate #ifdef __cplusplus 268*7c478bd9Sstevel@tonic-gate } 269*7c478bd9Sstevel@tonic-gate #endif 270*7c478bd9Sstevel@tonic-gate 271*7c478bd9Sstevel@tonic-gate #endif /* !_SYS_SER_ZSCC_H */ 272