1 /* 2 * Copyright (c) 1992, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Sony Corp. and Kazumasa Utashiro of Software Research Associates, Inc. 7 * 8 * %sccs.include.redist.c% 9 * 10 * from: $Hdr: machid.h,v 4.300 91/06/09 06:35:19 root Rel41 $ SONY 11 * 12 * @(#)machid.h 8.1 (Berkeley) 06/11/93 13 */ 14 15 #ifndef __MACHID__ 16 #define __MACHID__ 1 17 18 /* 19 * machine id number definition. 20 */ 21 #define ICK001 1 22 #define ICK00X 2 23 #define NWS799 3 24 #define NWS800 4 25 #define NWS801 5 26 #define NWS802 6 27 #define NWS711 7 28 #define NWS721 8 29 #define NWS1850 9 30 #define NWS810 10 31 #define NWS811 11 32 #define NWS1830 12 33 #define NWS1750 13 34 #define NWS1720 14 35 #define NWS1930 15 36 #define NWS1960 16 37 #define NWS712 17 38 #define NWS1860 18 39 #define PWS1630 19 40 #define NWS820 20 41 #define NWS821 21 42 #define NWS1760 22 43 #define NWS1710 23 44 #define NWS830 30 45 #define NWS831 31 46 #define NWS841 41 47 #define PWS1570 52 48 #define PWS1590 54 49 #define NWS1520 56 50 #define PWS1550 73 51 #define PWS1520 74 52 #define PWS1560 75 53 #define NWS1530 76 54 #define NWS1580 77 55 #define NWS1510 78 56 #define NWS1410 81 57 #define NWS1450 85 58 #define NWS1460 86 59 #define NWS891 91 60 #define NWS911 111 61 #define NWS921 121 62 #define NWB235 235 63 #define NWB235A 236 64 #define NWXRES 255 65 66 #ifdef mips 67 #define MACHID_MODEL(X) (((X)>>18)&0x1f) 68 #define MACHID_SERIAL(X) ((X)&0x3ffff) 69 #else /* mips */ 70 #define MACHID_MODEL(X) (((X)>>16)&0xff) 71 #define MACHID_SERIAL(X) ((X)&0xffff) 72 #endif /* mips */ 73 74 #ifndef LOCORE 75 76 /* 77 * MPU board id number definition. 78 */ 79 #define MPU0 0 /* not used */ 80 #define MPU1 1 /* ICKI */ 81 #define MPU2 2 /* 799/801/810/811/820/821 */ 82 #define MPU3 3 /* 802/830/841/911/921 */ 83 #define MPU4 4 /* 711 */ 84 #define MPU5 5 /* 1830/1850/1860/1930/1960 */ 85 #define MPU6 6 /* 712/721 */ 86 #define MPU7 7 /* 14XX/15XX */ 87 #define MPU8 8 /* 16XX/17XX */ 88 #define MPU9 9 /* */ 89 90 struct machid { 91 /*00*/ u_short m_pwb; /* MPU board number */ 92 /*02*/ u_short m_model; /* MPU dependent model code */ 93 /*04*/ u_int m_serial; /* machine serial number */ 94 /*08*/ u_int m_reserve0; 95 /*0c*/ u_int m_reserve1; 96 /*10*/ 97 }; 98 99 union omachid { 100 /*00*/ struct om_field { 101 u_int fi_reserve:2, 102 fi_pwb:7, /* MPU (printed wired) board number */ 103 fi_model:5, /* MPU dependent model code */ 104 fi_serial:18; /* machine serial number */ 105 } om_fi; 106 /*00*/ u_int om_data; 107 /*04*/ 108 }; 109 110 struct machine_type { 111 /*00*/ int m_model_id; 112 /*04*/ char *m_model_name; 113 /*08*/ char *m_machine_name; 114 /*0c*/ char *m_maincpu; 115 /*10*/ char *m_subcpu; 116 /*14*/ char *m_fpa; 117 /*18*/ int m_board_id; 118 /*1c*/ int m_cachecntl; 119 /*20*/ int m_maxusers; /* not used */ 120 /*24*/ int m_dcachesize; /* not used */ 121 /*28*/ int m_icachesize; /* not used */ 122 /*2c*/ 123 }; 124 125 #if defined(news700) || defined(news800) || defined(news1700) || defined(news1800) 126 struct idrom { 127 /*00*/ unsigned char id_model; 128 /*01*/ unsigned char id_serial[2]; 129 /*03*/ unsigned char id_lot; 130 /*04*/ unsigned char id_reserved[2]; 131 /*06*/ unsigned char id_chksum0[2]; 132 /*08*/ unsigned char id_ether[6]; 133 /*0e*/ unsigned char id_chksum1[2]; 134 /*10*/ 135 }; 136 #endif /* news700 || news800 || news1700 || news1800 */ 137 138 #if defined(news1200) || defined(news3400) || defined(news3800) 139 struct idrom { 140 /*00*/ unsigned char id_id; /* always 0xff */ 141 /*01*/ unsigned char id_netid[5]; /* network ID */ 142 /*06*/ unsigned short id_csum1; /* checksum 1 */ 143 /*08*/ unsigned char id_macadrs[6]; /* MAC (ethernet) address */ 144 /*0e*/ unsigned short id_csum2; /* checksum 2 */ 145 /*10*/ unsigned short id_boardid; /* CPU board ID */ 146 /*12*/ unsigned short id_modelid; /* model ID */ 147 /*14*/ unsigned int id_serial; /* serial number */ 148 /*18*/ unsigned short id_year; 149 /*1a*/ unsigned short id_month; 150 /*1c*/ unsigned char id_zone[4]; 151 /*20*/ char id_board[16]; 152 /*30*/ char id_model[16]; 153 /*40*/ char id_machine[16]; 154 /*50*/ char id_cpu[16]; 155 /*60*/ char id_iop[16]; 156 /*70*/ unsigned char id_reserved[12]; 157 /*7c*/ unsigned int id_csum3; 158 /*80*/ 159 }; 160 #endif /* news1200 || news3400 || news3800 */ 161 162 #endif /* !LOCORE */ 163 164 #endif /* __MACHID__ */ 165