# 2.11BSD#431 - /usr/src/sys/pdpuba/dhvreg.h

##### Macros

    DHV_BA2_DMAGO     X
    DHV_BA2_XBA       X
    DHV_BRK           X
    DHV_CAR           X
    DHV_CSH_NXM       X
    DHV_CSH_TI        X
    DHV_CSH_TLN       X
    DHV_CS_DFAIL      X
    DHV_CS_IAP        X
    DHV_CS_MCLR       X
    DHV_CS_RI         X
    DHV_CS_RIE        X
    DHV_CS_TIE        X
    DHV_CTS           X
    DHV_DSR           X
    DHV_DTR           X
    DHV_IE            X
    DHV_LC2_TXEN      X
    DHV_LC_BREAK      X
    DHV_LC_DTR        X
    DHV_LC_FXOFF      X
    DHV_LC_IAUTOF     X
    DHV_LC_MAINT      X
    DHV_LC_MODEM      X
    DHV_LC_OAUTOF     X
    DHV_LC_RTS        X
    DHV_LC_RXEN       X
    DHV_LC_TXABORT    X
    DHV_LE            X
    DHV_LP_BITS6      X
    DHV_LP_BITS7      X
    DHV_LP_BITS8      X
    DHV_LP_EPAR       X
    DHV_LP_PENABLE    X
    DHV_LP_RSPEED     X
    DHV_LP_TSPEED     X
    DHV_LP_TWOSB      X
    DHV_OFF           X
    DHV_ON            X
    DHV_RB_DIAG       X
    DHV_RB_DO         X
    DHV_RB_FE         X
    DHV_RB_PE         X
    DHV_RB_RDS        X
    DHV_RB_RLN        X
    DHV_RB_STAT       X
    DHV_RB_VALID      X
    DHV_RNG           X
    DHV_RTS           X
    DHV_RX_LINE       X
    DHV_SELECT        X
    DHV_ST_CTS        X
    DHV_ST_DCD        X
    DHV_ST_DHU        X
    DHV_ST_DSR        X
    DHV_ST_RI         X
    DHV_TX_LINE       X
    DHV_XBA_SHIFT     X
    dhvbyte           X
    dhvcsr            X
    dhvcsrh           X
    dhvcsrl           X
    dhvfifo           X
    dhvrbuf           X
    dhvsize           X
    dhvstat           X
    dhvtimo           X

##### struct's

    dhvdevice         X

       1: /*
       2:  * Copyright (c) 1986 Regents of the University of California.
       3:  * All rights reserved.  The Berkeley software License Agreement
       4:  * specifies the terms and conditions for redistribution.
       5:  *
       6:  *	@(#)dhvreg.h	1.2 (2.11BSD) 1997/5/1
       7:  */
       8:
       9: /*
      10:  * DHV-11 device register definitions.
      11:  */
      12: struct dhvdevice {
      13:     union {
      14:         u_short csr;        /* control-status register */
      15:         struct {
      16:             char    csrl;   /* low byte for line select */
      17:             char    csrh;   /* high byte for tx line */
      18:         } cb;
      19:     } un1;
      20: #define dhvcsr  un1.csr
      21: #define dhvcsrl un1.cb.csrl
      22: #define dhvcsrh un1.cb.csrh
      23:     union {
      24:         u_short rbuf;       /* recv.char/ds.change register (R) */
      25:         u_short timo;       /* delay between recv -> intr (W) */
      26:     } un2;
      27: #define dhvrbuf un2.rbuf
      28: #define dhvtimo un2.timo
      29:     u_short dhvlpr;         /* line parameter register */
      30:     union {
      31:         char    fbyte[1];   /* fifo data byte (low byte only) (W) */
      32:         u_short fdata;      /* fifo data word (W) */
      33:         char    sbyte[2];   /* line status/fifo size (R) */
      34:     } un3;
      35: #define dhvbyte un3.fbyte[0]
      36: #define dhvfifo un3.fdata
      37: #define dhvsize un3.sbyte[0]
      38: #define dhvstat un3.sbyte[1]
      39:     u_short dhvlcr;         /* line control register */
      40:     u_short dhvbar1;        /* buffer address register 1 */
      41:     char    dhvbar2;        /* buffer address register 2 */
      42:     char    dhvlcr2;        /* xmit enable bit */
      43:     short   dhvbcr;         /* buffer count register */
      44: };
      45:
      46: /* Bits in dhvcsr */
      47: #define DHV_CS_TIE  0x4000      /* transmit interrupt enable */
      48: #define DHV_CS_DFAIL    0x2000      /* diagnostic fail */
      49: #define DHV_CS_RI   0x0080      /* receiver interrupt */
      50: #define DHV_CS_RIE  0x0040      /* receiver interrupt enable */
      51: #define DHV_CS_MCLR 0x0020      /* master clear */
      52: #define DHV_CS_IAP  0x0007      /* indirect address pointer */
      53:
      54: #define DHV_IE  (DHV_CS_TIE|DHV_CS_RIE)
      55:
      56: /* map unit into iap register select */
      57: #define DHV_SELECT(unit)    ((unit) & DHV_CS_IAP)
      58:
      59: /* Transmitter bits in high byte of dhvcsr */
      60: #define DHV_CSH_TI  0x80        /* transmit interrupt */
      61: #define DHV_CSH_NXM 0x10        /* transmit dma err: non-exist-mem */
      62: #define DHV_CSH_TLN 0x0f        /* transmit line number */
      63:
      64: /* map csrh line bits into line */
      65: #define DHV_TX_LINE(csrh)   ((csrh) & DHV_CSH_TLN)
      66:
      67: /* Bits in dhvrbuf */
      68: #define DHV_RB_VALID    0x8000      /* data valid */
      69: #define DHV_RB_STAT 0x7000      /* status bits */
      70: #define DHV_RB_DO   0x4000      /* data overrun */
      71: #define DHV_RB_FE   0x2000      /* framing error */
      72: #define DHV_RB_PE   0x1000      /* parity error */
      73: #define DHV_RB_RLN  0x0f00      /* receive line number */
      74: #define DHV_RB_RDS  0x00ff      /* receive data/status */
      75: #define DHV_RB_DIAG 0x0001      /* if DHV_RB_STAT -> diag vs modem */
      76:
      77: /* map rbuf line bits into line */
      78: #define DHV_RX_LINE(rbuf)   (((rbuf) & DHV_RB_RLN) >> 8)
      79:
      80: /* Bits in dhvlpr */
      81: #define DHV_LP_TSPEED   0xf000
      82: #define DHV_LP_RSPEED   0x0f00
      83: #define DHV_LP_TWOSB    0x0080
      84: #define DHV_LP_EPAR 0x0040
      85: #define DHV_LP_PENABLE  0x0020
      86: #define DHV_LP_BITS8    0x0018
      87: #define DHV_LP_BITS7    0x0010
      88: #define DHV_LP_BITS6    0x0008
      89:
      90: /* Bits in dhvstat */
      91: #define DHV_ST_DSR  0x80        /* data set ready */
      92: #define DHV_ST_RI   0x20        /* ring indicator */
      93: #define DHV_ST_DCD  0x10        /* carrier detect */
      94: #define DHV_ST_CTS  0x08        /* clear to send */
      95: #define DHV_ST_DHU  0x01        /* always one on a dhu, zero on dhv */
      96:
      97: /* Bits in dhvlcr */
      98: #define DHV_LC_RTS  0x1000      /* request to send */
      99: #define DHV_LC_DTR  0x0200      /* data terminal ready */
     100: #define DHV_LC_MODEM    0x0100      /* modem control enable */
     101: #define DHV_LC_MAINT    0x00c0      /* maintenance mode */
     102: #define DHV_LC_FXOFF    0x0020      /* force xoff */
     103: #define DHV_LC_OAUTOF   0x0010      /* output auto flow */
     104: #define DHV_LC_BREAK    0x0008      /* break control */
     105: #define DHV_LC_RXEN 0x0004      /* receiver enable */
     106: #define DHV_LC_IAUTOF   0x0002      /* input auto flow */
     107: #define DHV_LC_TXABORT  0x0001      /* transmitter abort */
     108:
     109: /* Bits in dhvlcr2 */
     110: #define DHV_LC2_TXEN    0x80        /* transmitter enable */
     111:
     112: /* Bits in dhvbar2 */
     113: #define DHV_BA2_DMAGO   0x80        /* transmit dma start */
     114: #define DHV_BA2_XBA 0x03        /* top two bits of dma address */
     115: #define DHV_XBA_SHIFT   16      /* amount to shift xba bits */
     116:
     117: /* Bits for dhvmctl only:  stat bits are shifted up 16 */
     118: #define DHV_ON  (DHV_LC_DTR|DHV_LC_RTS|DHV_LC_MODEM)
     119: #define DHV_OFF DHV_LC_MODEM
     120:
     121: #define DHV_DSR ((long)DHV_ST_DSR << 16)
     122: #define DHV_RNG ((long)DHV_ST_RI << 16)
     123: #define DHV_CAR ((long)DHV_ST_DCD << 16)
     124: #define DHV_CTS ((long)DHV_ST_CTS << 16)
     125:
     126: #define DHV_RTS DHV_LC_RTS
     127: #define DHV_DTR DHV_LC_DTR
     128: #define DHV_BRK DHV_LC_BREAK
     129: #define DHV_LE  DHV_LC_MODEM

#### Defined struct's

dhvdevice defined in line 12; used 30 times

- in /usr/src/sys/autoconfig/dhvauto.c line 15(2)
- in /usr/src/sys/pdpuba/dhv.c line 133(2), 141(2), 257(2), 263(2), 456-461(4), 519(2), 528(2), 572(2), 578(2), 646-649(4), 685(2), 693(2)

#### Defined macros

DHV_BA2_DMAGO defined in line 113; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 630-632(2)

DHV_BA2_XBA defined in line 114; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 630

DHV_BRK defined in line 128; used 3 times

- in /usr/src/sys/pdpuba/dhv.c line 208, 390-393(2)

DHV_CAR defined in line 123; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 439

DHV_CSH_NXM defined in line 61; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 534

DHV_CSH_TI defined in line 60; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 529

DHV_CSH_TLN defined in line 62; used 1 times

- in line 65

DHV_CS_DFAIL defined in line 48; used 1 times

- in /usr/src/sys/autoconfig/dhvauto.c line 20

DHV_CS_IAP defined in line 52; used 1 times

- in line 57

DHV_CS_MCLR defined in line 51; used 2 times

- in /usr/src/sys/autoconfig/dhvauto.c line 18-20(2)

DHV_CS_RI defined in line 49; used 1 times

- in /usr/src/sys/autoconfig/dhvauto.c line 22

DHV_CS_RIE defined in line 50; used 2 times

- in line 54
- in /usr/src/sys/autoconfig/dhvauto.c line 22

DHV_CS_TIE defined in line 47; used 1 times

- in line 54

DHV_CTS defined in line 124; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 440

DHV_DSR defined in line 121; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 437

DHV_DTR defined in line 127; used 4 times

- in /usr/src/sys/pdpuba/dhv.c line 396-399(2), 426, 442

DHV_IE defined in line 54; used 8 times

- in /usr/src/sys/pdpuba/dhv.c line 147, 177, 491, 543, 602, 625, 666, 695

DHV_LC2_TXEN defined in line 110; used 3 times

- in /usr/src/sys/pdpuba/dhv.c line 503, 669, 719

DHV_LC_BREAK defined in line 104; used 1 times

- in line 128

DHV_LC_DTR defined in line 99; used 2 times

- in line 118, 127

DHV_LC_FXOFF defined in line 102; never used
DHV_LC_IAUTOF defined in line 106; never used
DHV_LC_MAINT defined in line 101; never used
DHV_LC_MODEM defined in line 100; used 3 times

- in line 118-119(2), 129

DHV_LC_OAUTOF defined in line 103; used 3 times

- in /usr/src/sys/pdpuba/dhv.c line 498-501(2), 718

DHV_LC_RTS defined in line 98; used 2 times

- in line 118, 126

DHV_LC_RXEN defined in line 105; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 716

DHV_LC_TXABORT defined in line 107; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 626, 667

DHV_LE defined in line 129; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 427, 443

DHV_LP_BITS6 defined in line 88; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 475

DHV_LP_BITS7 defined in line 87; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 479

DHV_LP_BITS8 defined in line 86; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 477, 486

DHV_LP_EPAR defined in line 84; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 481

DHV_LP_PENABLE defined in line 85; used 3 times

- in /usr/src/sys/pdpuba/dhv.c line 475-479(2), 487

DHV_LP_RSPEED defined in line 82; never used
DHV_LP_TSPEED defined in line 81; never used
DHV_LP_TWOSB defined in line 83; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 490

DHV_OFF defined in line 119; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 209, 470

DHV_ON defined in line 118; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 176

DHV_RB_DIAG defined in line 75; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 281

DHV_RB_DO defined in line 70; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 311, 319

DHV_RB_FE defined in line 71; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 311, 327

DHV_RB_PE defined in line 72; used 3 times

- in /usr/src/sys/pdpuba/dhv.c line 311-313(2), 352

DHV_RB_RDS defined in line 74; never used
DHV_RB_RLN defined in line 73; used 1 times

- in line 78

DHV_RB_STAT defined in line 69; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 276(2)

DHV_RB_VALID defined in line 68; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 272, 323

DHV_RNG defined in line 122; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 438

DHV_RTS defined in line 126; used 4 times

- in /usr/src/sys/pdpuba/dhv.c line 396-399(2), 425, 441

DHV_RX_LINE defined in line 78; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 274

DHV_SELECT defined in line 57; used 8 times

- in /usr/src/sys/pdpuba/dhv.c line 147, 177, 491, 543, 602, 625, 666, 695

DHV_ST_CTS defined in line 94; used 3 times

- in line 124
- in /usr/src/sys/pdpuba/dhv.c line 293, 607

DHV_ST_DCD defined in line 93; used 3 times

- in line 123
- in /usr/src/sys/pdpuba/dhv.c line 178, 290

DHV_ST_DHU defined in line 95; never used
DHV_ST_DSR defined in line 91; used 1 times

- in line 121

DHV_ST_RI defined in line 92; used 1 times

- in line 122

DHV_TX_LINE defined in line 65; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 531

DHV_XBA_SHIFT defined in line 115; never used
dhvbyte defined in line 35; never used
dhvcsr defined in line 20; used 8 times

- in /usr/src/sys/autoconfig/dhvauto.c line 18-24(4)
- in /usr/src/sys/pdpuba/dhv.c line 147, 177, 491, 695

dhvcsrh defined in line 22; used 1 times

- in /usr/src/sys/pdpuba/dhv.c line 529

dhvcsrl defined in line 21; used 4 times

- in /usr/src/sys/pdpuba/dhv.c line 543, 602, 625, 666

dhvfifo defined in line 36; never used
dhvrbuf defined in line 27; used 2 times

- in /usr/src/sys/pdpuba/dhv.c line 272, 323

dhvsize defined in line 37; never used
dhvstat defined in line 38; used 3 times

- in /usr/src/sys/pdpuba/dhv.c line 178, 607, 700

dhvtimo defined in line 28; never used

#### Usage of this include

dhvreg.h used 2 times

- in /usr/src/sys/autoconfig/dhvauto.c line 12
- in /usr/src/sys/pdpuba/dhv.c line 31

Last modified: 1997-05-02 Generated: 2016-12-26 | Generated by src2html V0.67 page hit count: 1263 |