Annotation of researchv9/sys/sun3/eccreg.h, revision 1.1.1.1

1.1       root        1: /*      @(#)eccreg.h 1.1 86/02/03 SMI      */
                      2: 
                      3: /*
                      4:  * Copyright (c) 1985 by Sun Microsystems, Inc.
                      5:  */
                      6: 
                      7: #define        OBIO_ECCREG 0x1C0000    /* addr of ECC memory regsiters in obio space */
                      8: 
                      9: #define MAX_ECC                4       /* maximium number of ECC memory cards */
                     10: 
                     11: #define ECCREG_ADDR 0x0FFE8000 /* virtual address we map eccreg to be at */
                     12: 
                     13: #ifdef LOCORE
                     14: #define        ECCREG ECCREG_ADDR
                     15: #else
                     16: struct eccreg {
                     17:        struct eccena {
                     18:                u_int ena_type : 3;     /* r/o - board type identifier */
                     19:                u_int ena_mode : 2;     /* r/w - operation mode */
                     20: #define ENA_MODE_NORMAL                0
                     21: #define ENA_MODE_DIAG_GENERATE 1
                     22: #define ENA_MODE_DIAG_DETECT   2
                     23: #define ENA_MODE_DIAG_INIT     3
                     24:                u_int ena_size : 2;     /* r/o - board size */
                     25: #define ENA_SIZE_4MB           0
                     26: #define ENA_SIZE_8MB           1
                     27: #define ENA_SIZE_16MB          2
                     28: #define ENA_SIZE_32MB          3
                     29:                u_int ena_scrub : 1;    /* r/w - enable refresh scrub cycle */
                     30:                u_int ena_busena : 1;   /* r/w - enable mem bus ecc reporting */
                     31:                u_int ena_boardena : 1; /* r/w - overall board enable */
                     32:                u_int ena_addr : 6;     /* r/w - base address <A27..A22> */
                     33:                u_int : 16;
                     34:        } eccena;
                     35:        struct syndrome {
                     36:                u_int sy_synd : 8;      /* r/o - syndrome for first error */
                     37:                u_int : 1;
                     38:                u_int sy_addr : 22;     /* r/o - real addr bits <A24..A3> */
                     39:                u_int sy_ce : 1;        /* r/o - correctable error */
                     40:        } syndrome;
                     41:        struct eccdiag_reg {
                     42:                u_int : 8;
                     43:                u_int dr_cb32 : 1;      /* w/o - check bit 32 (data D<71>) */
                     44:                u_int : 16;
                     45:                u_int dr_cb16 : 1;      /* w/o - check bit 16 (data D<70>) */
                     46:                u_int : 32;
                     47:                u_int dr_cb8 : 1;       /* w/o - check bit 8  (data D<69>) */
                     48:                u_int dr_cb4 : 1;       /* w/o - check bit 4  (data D<68>) */
                     49:                u_int dr_cb2 : 1;       /* w/o - check bit 2  (data D<67>) */
                     50:                u_int dr_cb1 : 1;       /* w/o - check bit 1  (data D<66>) */
                     51:                u_int dr_cb0 : 1;       /* w/o - check bit 1  (data D<65>) */
                     52:                u_int dr_cbX : 1;       /* w/o - check bit X  (data D<64>) */
                     53:        } eccdiag_reg;
                     54:        u_char eccreg_pad[64 - sizeof (struct eccdiag_reg) -
                     55:            sizeof (struct syndrome) - sizeof (struct eccena)];
                     56: };
                     57: 
                     58: #define        ECCREG ((struct eccreg *)ECCREG_ADDR)
                     59: #endif
                     60: 
                     61: #define SYNDERR_BITS   "\20\10S32\7S16\6S8\5S4\4S2\3S1\2S0\1SX"

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.