Home | History | Annotate | Line # | Download | only in common
      1 /*	$NetBSD: mopdef.h,v 1.4 2009/10/20 00:51:13 snj Exp $	*/
      2 
      3 /*
      4  * Copyright (c) 1993-95 Mats O Jansson.  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:
      9  * 1. Redistributions of source code must retain the above copyright
     10  *    notice, this list of conditions and the following disclaimer.
     11  * 2. Redistributions in binary form must reproduce the above copyright
     12  *    notice, this list of conditions and the following disclaimer in the
     13  *    documentation and/or other materials provided with the distribution.
     14  *
     15  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
     16  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
     17  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
     18  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
     19  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
     20  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
     21  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
     22  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
     23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
     24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     25  *
     26  *	$NetBSD: mopdef.h,v 1.4 2009/10/20 00:51:13 snj Exp $
     27  *
     28  */
     29 
     30 #ifndef _MOPDEF_H_
     31 #define _MOPDEF_H_
     32 
     33 #define MOP_K_PROTO_DL          0x6001  /* MOP Load/Dump Protocol */
     34 #define MOP_K_PROTO_RC          0x6002  /* MOP Remote Console Protocol */
     35 #define MOP_K_PROTO_LP          0x9000  /* MOP Loopback Protocol */
     36 
     37 #define MOP_K_PROTO_802_DL	{ 0x08, 0x00, 0x2b, 0x60, 0x01 }
     38 #define MOP_K_PROTO_802_RC	{ 0x08, 0x00, 0x2b, 0x60, 0x02 }
     39 #define MOP_K_PROTO_802_LP	{ 0x08, 0x00, 0x2b, 0x90, 0x00 }
     40 
     41 #define MOP_K_PROTO_802_DSAP	0xaa
     42 #define MOP_K_PROTO_802_SSAP	0xaa
     43 #define MOP_K_PROTO_802_CNTL	0x03
     44 
     45 #define TRANS_ETHER		1	/* Packet in Ethernet format */
     46 #define TRANS_8023		2	/* Packet in 802.3 format */
     47 #define TRANS_AND		0x1000	/* Both Ethernet and 802.3 */
     48 
     49 /* The following constants are defined in module MOPDEF.SDL in MOM */
     50 
     51 #define MOP_K_CODE_MIN          0
     52 #define MOP_K_CODE_MLT          0       /* Memory Load with transfer address */
     53 #define MOP_K_CODE_DCM          1       /* Dump Complete */
     54 #define MOP_K_CODE_MLD          2       /* Memory Load */
     55 #define MOP_K_CODE_ASV          3       /* Assistance volunteer (NI only */
     56 #define MOP_K_CODE_RMD          4       /* Request memory dump */
     57 #define MOP_K_CODE_RID          5       /* Request ID */
     58 #define MOP_K_CODE_BOT          6       /* Boot */
     59 #define MOP_K_CODE_SID          7       /* System ID */
     60 #define MOP_K_CODE_RPR          8       /* Request program */
     61 #define MOP_K_CODE_RQC          9       /* Request Counters */
     62 #define MOP_K_CODE_RML          10      /* Request memory load */
     63 #define MOP_K_CODE_CNT          11      /* Counters */
     64 #define MOP_K_CODE_RDS          12      /* Request Dump Service */
     65 #define MOP_K_CODE_MMR          12      /* MOP Mode Running */
     66 #define MOP_K_CODE_RVC          13      /* Reserve Console */
     67 #define MOP_K_CODE_MDD          14      /* Memory dump data */
     68 #define MOP_K_CODE_RLC          15      /* Release Console */
     69 #define MOP_K_CODE_CCP          17      /* Console Command and Poll */
     70 #define MOP_K_CODE_CRA          19      /* Console Response and Acknnowledge */
     71 #define MOP_K_CODE_PLT          20      /* Parameter load with transfer address*/
     72 #define MOP_K_CODE_ALD          24      /* Active loop data */
     73 #define MOP_K_CODE_PLD          26      /* Passive looped data */
     74 #define MOP_K_CODE_MAX          26
     75 
     76 #define MOP_K_PGTY_MIN          0
     77 #define MOP_K_PGTY_SECLDR       0       /* Secondary Loader */
     78 #define MOP_K_PGTY_TERLDR       1       /* Tertiary Loader */
     79 #define MOP_K_PGTY_OPRSYS       2       /* Operating System */
     80 #define MOP_K_PGTY_MGNTFL       3       /* Management File */
     81 #define MOP_K_PGTY_MAX          3
     82 
     83 #define MOP_K_BPTY_MIN          0
     84 #define MOP_K_BPTY_SYS          0       /* System Processor */
     85 #define MOP_K_BPTY_COM          1       /* Communication Processor */
     86 #define MOP_K_BPTY_MAX          1
     87 
     88 #define MOP_K_RML_ERROR_MIN     0
     89 #define MOP_K_RML_ERROR_NONE    0       /* None */
     90 #define MOP_K_RML_ERROR_NO_LOAD 1       /* Image data not properly loaded */
     91 #define MOP_K_RML_ERROR_MAX     1
     92 
     93 #define MOP_K_PLTP_MIN          0
     94 #define MOP_K_PLTP_END          0       /* End Mark */
     95 #define MOP_K_PLTP_TSN          1       /* Target System Name */
     96 #define MOP_K_PLTP_TSA          2       /* Target System Address */
     97 #define MOP_K_PLTP_HSN          3       /* Host System Name */
     98 #define MOP_K_PLTP_HSA          4       /* Host System Address */
     99 #define MOP_K_PLTP_HST          5       /* Host System Time */
    100 #define MOP_K_PLTP_MAX          5
    101 
    102 #define MOP_K_BOT_CNTL_MIN      0
    103 #define MOP_K_BOT_CNTL_SERVER   0       /* Boot-Server */
    104 #define MOP_K_BOT_CNTL_DEVICE   1       /* Boot-Device */
    105 #define MOP_K_BOT_CNTL_MAX      1
    106 
    107 #define MOP_K_INFO_VER          1       /* Maintenance Version */
    108 #define MOP_K_INFO_MFCT         2       /* Maintenance Functions */
    109 #define MOP_K_INFO_CNU          3       /* Console User */
    110 #define MOP_K_INFO_RTM          4       /* Reservation Timer */
    111 #define MOP_K_INFO_CSZ          5       /* Console Command Size */
    112 #define MOP_K_INFO_RSZ          6       /* Console Response Size */
    113 #define MOP_K_INFO_HWA          7       /* Hardware Address */
    114 #define MOP_K_INFO_TIME         8       /* System Time */
    115 #define MOP_K_INFO_SOFD         100     /* Communication Device */
    116 #define MOP_K_INFO_SFID         200     /* Software ID */
    117 #define MOP_K_INFO_PRTY         300     /* System Processor */
    118 #define MOP_K_INFO_DLTY         400     /* Data Link Type */
    119 #define MOP_K_INFO_DLBSZ        401     /* Data Link Buffer Size */
    120 
    121 #define MOP_K_DLTY_MIN          1
    122 #define MOP_K_DLTY_NI           1       /* Ethernet */
    123 #define MOP_K_DLTY_DDCMP        2       /* DDCMP */
    124 #define MOP_K_DLTY_LAPB         3       /* LAPB (frame level of X.25) */
    125 #define MOP_K_DLTY_MAX          3
    126 
    127 #define MOP_K_PRTY_MIN          0
    128 #define MOP_K_PRTY_11           1       /* PDP-11 (UNIBUS) */
    129 #define MOP_K_PRTY_CMSV         2       /* Communication Server */
    130 #define MOP_K_PRTY_PRO          3       /* Professional */
    131 #define MOP_K_PRTY_SCO          4       /* Scorpio */
    132 #define MOP_K_PRTY_AMB          5       /* Amber */
    133 #define MOP_K_PRTY_BRI          6       /* XLII Bridge */
    134 #define MOP_K_PRTY_MAX          6
    135 
    136 #define MOP_K_SFID_FORM_MIN     -2
    137 #define MOP_K_SFID_FORM_MAINT   -2      /* Maintenance System */
    138 #define MOP_K_SFID_FORM_OPRSYS  -1      /* Standard Operating System */
    139 #define MOP_K_SFID_FORM_NONE    0       /* None */
    140 #define MOP_K_SFID_FORM_MAX     0
    141 
    142 #define MOP_K_SFID_CUST         'CP'    /* Customer product */
    143 #define MOP_K_SFID_DEC          'DP'    /* DEC product */
    144 #define MOP_K_SFID_DELIM_ID     '#'     /* Delimiter identifier */
    145 
    146 #define MOP_K_DLBSZ_DEFAULT     262     /* Buffersize */
    147 
    148 #define MOP_K_NILOOP_REPLY      1       /* Response */
    149 #define MOP_K_NILOOP_FORWARD    2       /* Forward Data */
    150 
    151 #define MOP_DL_MULTICAST	{ 0xab, 0x00, 0x00, 0x01, 0x00, 0x00 }
    152 #define MOP_RC_MULTICAST	{ 0xab, 0x00, 0x00, 0x02, 0x00, 0x00 }
    153 #define MOP_LP_MULTICAST	{ 0xcf, 0x00, 0x00, 0x00, 0x00, 0x00 }
    154 
    155 #define MOP_K_RPR_FORMAT_V3	1	/* Format Version of RPR */
    156 #define MOP_K_RPR_FORMAT	4	/* Format Version of RPR */
    157 
    158 #define IHD_C_MINCODE		-1	/* Low bound of ALIAS value */
    159 #define IHD_C_NATIVE		-1	/* Native mode image */
    160 #define IHD_C_RSX		0	/* RSX image produced by TKB */
    161 #define IHD_C_BPA		1	/* BASIC plus analog */
    162 #define IHD_C_ALIAS		2	/* Last 126 bytes contains ASCIC of image to activate */
    163 #define IHD_C_CLI		3	/* Image is CLI, run LOGINOUT */
    164 #define IHD_C_PMAX		4	/* PMAX system image */
    165 #define IHD_C_ALPHA		5	/* ALPHA system image */
    166 #define IHD_C_MAXCODE		5	/* High bound of ALIAS value */
    167 
    168 #define IHD_W_SIZE		0
    169 #define IHD_W_ACTIVOFF		2
    170 #define IHD_B_HDRBLKCNT		16
    171 #define IHD_W_ALIAS		510
    172 #define	ISD_W_PAGCNT		2
    173 #define ISD_V_VPN		4
    174 #define ISD_M_VPN		0x1fffff
    175 #define IHA_L_TFRADR1		0
    176 #define EISD_L_SECSIZE		12
    177 #define EIHD_L_ISDOFF		12
    178 #define EIHD_L_HDRBLKCNT	76
    179 
    180 #define L_BSA			0x08	/* RSX base address */
    181 #define L_BLDZ			0x0e	/* RSX image size (* 64) */
    182 #define L_BXFR			0xe8	/* RSX transfer address */
    183 #define L_BBLK			0xf0	/* RSX header block count */
    184 
    185 #ifndef MOPDEF_SUPRESS_EXTERN
    186 extern char dl_mcst[];
    187 extern char rc_mcst[];
    188 extern char dl_802_proto[];
    189 extern char rc_802_proto[];
    190 extern char lp_802_proto[];
    191 #endif	/* MOPDEF_SUPRESS_EXTERN */
    192 
    193 #endif /* _MOPDEF_H_ */
    194