3 Broadcom Sonics Silicon Backplane bus SPROM data modification tool
5 Copyright (c) 2006-2007 Michael Buesch <mb@bu3sch.de>
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; see the file COPYING. If not, write to
19 the Free Software Foundation, Inc., 51 Franklin Steet, Fifth Floor,
20 Boston, MA 02110-1301, USA.
24 #ifndef SSB_SPROMTOOL_H_
25 #define SSB_SPROMTOOL_H_
29 #define VERSION ssb_stringify(VERSION_)
31 #define SPROM_SIZE 128 /* bytes */
32 #define SPROM4_SIZE 440
35 #define SPROM_SUBP (0x02 * 2)
36 #define SPROM4_SUBP (0x00 * 2)
37 #define SPROM_SUBV (0x03 * 2)
38 #define SPROM_PPID (0x04 * 2)
39 #define SPROM4_PPID (0x02 * 2)
40 #define SPROM_BFLHI (0x1C * 2)
41 #define SPROM_IL0MACADDR (0x24 * 2)
42 #define SPROM_ET0MACADDR (0x27 * 2)
43 #define SPROM_ET1MACADDR (0x2a * 2)
44 #define SPROM3_IL0MACADDR (0x25 * 2)
45 #define SPROM3_ET0MACADDR (0x28 * 2)
46 #define SPROM3_ET1MACADDR (0x28 * 2)
47 #define SPROM4_IL0MACADDR (0x26 * 2)
48 #define SPROM4_ET0MACADDR (0x18 * 2)
49 #define SPROM4_ET1MACADDR (0x26 * 2)
50 #define SPROM_ETHPHY (0x2d * 2)
51 #define SPROM_BOARDREV (0x2e * 2)
52 #define SPROM4_BOARDREV (0x21 * 2)
53 #define SPROM4_ANTAVAIL (0x2e * 2)
54 #define SPROM4_COUNTRY (0x29 * 2)
55 #define SPROM_PA0B0 (0x2f * 2)
56 #define SPROM_PA0B1 (0x30 * 2)
57 #define SPROM_PA0B2 (0x31 * 2)
58 #define SPROM_WL0GPIO0 (0x32 * 2)
59 #define SPROM_WL0GPIO2 (0x33 * 2)
60 #define SPROM4_WL0GPIO0 (0x2b * 2)
61 #define SPROM4_WL0GPIO2 (0x2c * 2)
62 #define SPROM_MAXPWR (0x34 * 2)
63 #define SPROM4_MAXPWR (0x45 * 2)
64 #define SPROM_PA1B0 (0x35 * 2)
65 #define SPROM_PA1B1 (0x36 * 2)
66 #define SPROM_PA1B2 (0x37 * 2)
67 #define SPROM_IDL_TSSI_TGT (0x38 * 2)
68 #define SPROM4_IDL_TSSI_TGT (0x40 * 2)
69 #define SPROM_BOARDFLAGS (0x39 * 2)
70 #define SPROM4_BOARDFLAGS (0x22 * 2)
71 #define SPROM_ANTENNA_GAIN (0x3a * 2)
72 #define SPROM4_ANTENNA_GAIN (0x2f * 2)
73 #define SPROM_VERSION (0x3f * 2)
74 #define SPROM4_VERSION (0xdb * 2)
80 VALUE_FIRST = VALUE_SUBP,
115 VALUE_LAST = VALUE_SVER,
118 struct cmdline_vparm {
132 struct cmdline_args {
139 #define MAX_VPARM 512
140 struct cmdline_vparm vparm[MAX_VPARM];
143 extern struct cmdline_args cmdargs;
145 #endif /* SSB_SPROMTOOL_H_ */