hw/arm/aspeed: anacapa: add FRU EEPROM data
Use frugen to generate FRU data for the following components: HPM MB, R-PDB, L-PDB, SCM, BSM, R Bridge Board, L Bridge Board, and HPM board ID. Signed-off-by: William de Abreu Pinho <williamdapinho@gmail.com> Reviewed-by: Cédric Le Goater <clg@redhat.com> Link: https://lore.kernel.org/qemu-devel/20260519-add-anacapa-machine-v3-3-56c23993a20a@gmail.com Signed-off-by: Cédric Le Goater <clg@redhat.com>
William de Abreu Pinho committed
May 19, 2026 at 10:48 UTC
f89ca1b3f6feeddf3d31a2b3a095714fcf9a794f
1 file changed
+217
-8
hw/arm/aspeed_ast2600_anacapa.c
+217
-8
@@ -20,6 +20,207 @@
20
#define ANACAPA_BMC_HW_STRAP2 0x00000000
21
#define ANACAPA_BMC_RAM_SIZE ASPEED_RAM_SIZE(2 * GiB)
22
23
+/*
24
+ * "Anacapa HPM (MB)" FRU data. Generated with frugen.
25
+ *
26
+ * {
27
+ * "board": { "mfg": "Inventec", "pname": "Anacapa QEMU MB EVT2",
28
+ * "pn": "00000000000", "serial": "00000000000000" },
29
+ * "product": { "mfg": "Inventec", "pname": "CI-Anacapa",
30
+ * "pn": "10000000001", "ver": "MP",
31
+ * "serial": "10000000000000", "atag": "QEMU" }
32
+ * }
33
+ */
34
+static const uint8_t hpm_eeprom[] = {
35
+ 0x01, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0xf6, 0x01, 0x07, 0x19, 0xb4,
36
+ 0xa4, 0xf2, 0xc8, 0x49, 0x6e, 0x76, 0x65, 0x6e, 0x74, 0x65, 0x63, 0xd4,
37
+ 0x41, 0x6e, 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x51, 0x45, 0x4d, 0x55,
38
+ 0x20, 0x4d, 0x42, 0x20, 0x45, 0x56, 0x54, 0x32, 0x47, 0x00, 0x00, 0x00,
39
+ 0x00, 0x00, 0x00, 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0xc0,
40
+ 0xc1, 0x00, 0x00, 0xb8, 0x01, 0x06, 0x19, 0xc8, 0x49, 0x6e, 0x76, 0x65,
41
+ 0x6e, 0x74, 0x65, 0x63, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e, 0x61, 0x63,
42
+ 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a, 0x82, 0x2d,
43
+ 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x71, 0xd9,
44
+ 0xd6, 0xc0, 0xc1, 0x0e
45
+};
46
+static const size_t hpm_eeprom_len = sizeof(hpm_eeprom);
47
+
48
+/*
49
+ * "Anacapa R-PDB" FRU data. Generated with frugen.
50
+ *
51
+ * {
52
+ * "board": { "mfg": "Inventec", "pname": "Anacapa QEMU RPDB",
53
+ * "pn": "00000000000", "serial": "00000000000000" },
54
+ * "product": { "mfg": "Inventec", "pname": "CI-Anacapa",
55
+ * "pn": "10000000001", "ver": "MP",
56
+ * "serial": "10000000000000", "atag": "QEMU" }
57
+ * }
58
+ */
59
+static const uint8_t rpdb_eeprom[] = {
60
+ 0x01, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0xf6, 0x01, 0x07, 0x19, 0x41,
61
+ 0x2d, 0xf2, 0xc8, 0x49, 0x6e, 0x76, 0x65, 0x6e, 0x74, 0x65, 0x63, 0xd1,
62
+ 0x41, 0x6e, 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x51, 0x45, 0x4d, 0x55,
63
+ 0x20, 0x52, 0x50, 0x44, 0x42, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
64
+ 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0xc0, 0xc1, 0x00, 0x00,
65
+ 0x00, 0x00, 0x00, 0x4d, 0x01, 0x06, 0x19, 0xc8, 0x49, 0x6e, 0x76, 0x65,
66
+ 0x6e, 0x74, 0x65, 0x63, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e, 0x61, 0x63,
67
+ 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a, 0x82, 0x2d,
68
+ 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x71, 0xd9,
69
+ 0xd6, 0xc0, 0xc1, 0x0e
70
+};
71
+static const size_t rpdb_eeprom_len = sizeof(rpdb_eeprom);
72
+
73
+/*
74
+ * "Anacapa L-PDB" FRU data. Generated with frugen.
75
+ *
76
+ * {
77
+ * "board": { "mfg": "Inventec", "pname": "Anacapa QEMU LPDB",
78
+ * "pn": "00000000000", "serial": "00000000000000" },
79
+ * "product": { "mfg": "Inventec", "pname": "CI-Anacapa",
80
+ * "pn": "10000000001", "ver": "MP",
81
+ * "serial": "10000000000000", "atag": "QEMU" }
82
+ * }
83
+ */
84
+static const uint8_t lpdb_eeprom[] = {
85
+ 0x01, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0xf6, 0x01, 0x07, 0x19, 0x41,
86
+ 0x2d, 0xf2, 0xc8, 0x49, 0x6e, 0x76, 0x65, 0x6e, 0x74, 0x65, 0x63, 0xd1,
87
+ 0x41, 0x6e, 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x51, 0x45, 0x4d, 0x55,
88
+ 0x20, 0x4c, 0x50, 0x44, 0x42, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
89
+ 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0xc0, 0xc1, 0x00, 0x00,
90
+ 0x00, 0x00, 0x00, 0x53, 0x01, 0x06, 0x19, 0xc8, 0x49, 0x6e, 0x76, 0x65,
91
+ 0x6e, 0x74, 0x65, 0x63, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e, 0x61, 0x63,
92
+ 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a, 0x82, 0x2d,
93
+ 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x71, 0xd9,
94
+ 0xd6, 0xc0, 0xc1, 0x0e
95
+};
96
+static const size_t lpdb_eeprom_len = sizeof(lpdb_eeprom);
97
+
98
+/*
99
+ * "Anacapa SCM" FRU data. Generated with frugen.
100
+ *
101
+ * {
102
+ * "board": { "mfg": "Quanta", "pname": "Anacapa SCM",
103
+ * "pn": "00000000000", "serial": "00000000000000" },
104
+ * "product": { "mfg": "Quanta", "pname": "CI-Anacapa",
105
+ * "pn": "10000000001", "ver": "MP",
106
+ * "serial": "10000000000000", "atag": "QEMU" }
107
+ * }
108
+ */
109
+static const uint8_t scm_eeprom[] = {
110
+ 0x01, 0x00, 0x00, 0x01, 0x07, 0x00, 0x00, 0xf7, 0x01, 0x06, 0x19, 0x41,
111
+ 0x2d, 0xf2, 0xc6, 0x51, 0x75, 0x61, 0x6e, 0x74, 0x61, 0xcb, 0x41, 0x6e,
112
+ 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x53, 0x43, 0x4d, 0x47, 0x00, 0x00,
113
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a,
114
+ 0xc0, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc5, 0x01, 0x06, 0x19, 0xc6,
115
+ 0x51, 0x75, 0x61, 0x6e, 0x74, 0x61, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e,
116
+ 0x61, 0x63, 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a,
117
+ 0x82, 0x2d, 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83,
118
+ 0x71, 0xd9, 0xd6, 0xc0, 0xc1, 0x00, 0x00, 0xe2
119
+};
120
+static const size_t scm_eeprom_len = sizeof(scm_eeprom);
121
+
122
+/*
123
+ * "Anacapa BMC Storage Module" FRU data. Generated with frugen.
124
+ *
125
+ * {
126
+ * "board": { "mfg": "Quanta", "pname": "Anacapa BMC Storage Module",
127
+ * "pn": "00000000000", "serial": "00000000000000" },
128
+ * "product": { "mfg": "Quanta", "pname": "CI-Anacapa",
129
+ * "pn": "10000000001", "ver": "MP",
130
+ * "serial": "10000000000000", "atag": "QEMU" }
131
+ * }
132
+ */
133
+static const uint8_t bsm_eeprom[] = {
134
+ 0x01, 0x00, 0x00, 0x01, 0x0a, 0x00, 0x00, 0xf4, 0x01, 0x09, 0x00, 0x00,
135
+ 0x00, 0x00, 0xc6, 0x51, 0x75, 0x61, 0x6e, 0x74, 0x61, 0xda, 0x41, 0x6e,
136
+ 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x42, 0x4d, 0x43, 0x20, 0x53, 0x74,
137
+ 0x6f, 0x72, 0x61, 0x67, 0x65, 0x20, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65,
138
+ 0xce, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30,
139
+ 0x30, 0x30, 0x30, 0xcb, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30,
140
+ 0x30, 0x30, 0x30, 0xc0, 0xc1, 0x00, 0x00, 0x10, 0x01, 0x08, 0x00, 0xc6,
141
+ 0x51, 0x75, 0x61, 0x6e, 0x74, 0x61, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e,
142
+ 0x61, 0x63, 0x61, 0x70, 0x61, 0xcb, 0x31, 0x30, 0x30, 0x30, 0x30, 0x30,
143
+ 0x30, 0x30, 0x30, 0x30, 0x31, 0xc2, 0x4d, 0x50, 0xce, 0x31, 0x30, 0x30,
144
+ 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0xc4,
145
+ 0x51, 0x45, 0x4d, 0x55, 0xc0, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x77,
146
+};
147
+static const size_t bsm_eeprom_len = sizeof(bsm_eeprom);
148
+
149
+/*
150
+ * "Anacapa R Bridge Board" FRU data. Generated with frugen.
151
+ *
152
+ * {
153
+ * "board": { "mfg": "Inventec", "pname": "Anacapa QEMU RBB EVT2",
154
+ * "pn": "00000000000", "serial": "00000000000000" },
155
+ * "product": { "mfg": "Inventec", "pname": "CI-Anacapa",
156
+ * "pn": "10000000001", "ver": "MP",
157
+ * "serial": "10000000000000", "atag": "QEMU" }
158
+ * }
159
+ */
160
+static const uint8_t rbb_eeprom[] = {
161
+ 0x01, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0xf6, 0x01, 0x07, 0x19, 0xb4,
162
+ 0xa4, 0xf2, 0xc8, 0x49, 0x6e, 0x76, 0x65, 0x6e, 0x74, 0x65, 0x63, 0xd5,
163
+ 0x41, 0x6e, 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x51, 0x45, 0x4d, 0x55,
164
+ 0x20, 0x52, 0x42, 0x42, 0x20, 0x45, 0x56, 0x54, 0x32, 0x47, 0x00, 0x00,
165
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a,
166
+ 0xc0, 0xc1, 0x00, 0x70, 0x01, 0x06, 0x19, 0xc8, 0x49, 0x6e, 0x76, 0x65,
167
+ 0x6e, 0x74, 0x65, 0x63, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e, 0x61, 0x63,
168
+ 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a, 0x82, 0x2d,
169
+ 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x71, 0xd9,
170
+ 0xd6, 0xc0, 0xc1, 0x0e
171
+};
172
+static const size_t rbb_eeprom_len = sizeof(rbb_eeprom);
173
+
174
+/*
175
+ * "Anacapa L Bridge Board" FRU data. Generated with frugen.
176
+ *
177
+ * {
178
+ * "board": { "mfg": "Inventec", "pname": "Anacapa QEMU LBB EVT2",
179
+ * "pn": "00000000000", "serial": "00000000000000" },
180
+ * "product": { "mfg": "Inventec", "pname": "CI-Anacapa",
181
+ * "pn": "10000000001", "ver": "MP",
182
+ * "serial": "10000000000000", "atag": "QEMU" }
183
+ * }
184
+ */
185
+static const uint8_t lbb_eeprom[] = {
186
+ 0x01, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0xf6, 0x01, 0x07, 0x19, 0xb4,
187
+ 0xa4, 0xf2, 0xc8, 0x49, 0x6e, 0x76, 0x65, 0x6e, 0x74, 0x65, 0x63, 0xd5,
188
+ 0x41, 0x6e, 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x51, 0x45, 0x4d, 0x55,
189
+ 0x20, 0x4c, 0x42, 0x42, 0x20, 0x45, 0x56, 0x54, 0x32, 0x47, 0x00, 0x00,
190
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a,
191
+ 0xc0, 0xc1, 0x00, 0x76, 0x01, 0x06, 0x19, 0xc8, 0x49, 0x6e, 0x76, 0x65,
192
+ 0x6e, 0x74, 0x65, 0x63, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e, 0x61, 0x63,
193
+ 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a, 0x82, 0x2d,
194
+ 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x71, 0xd9,
195
+ 0xd6, 0xc0, 0xc1, 0x0e
196
+};
197
+static const size_t lbb_eeprom_len = sizeof(lbb_eeprom);
198
+
199
+/*
200
+ * "Anacapa HPM BRD ID" FRU data. Generated with frugen.
201
+ *
202
+ * {
203
+ * "board": { "mfg": "Inventec", "pname": "Anacapa HPM BRD ID",
204
+ * "pn": "00000000000", "serial": "00000000000000" },
205
+ * "product": { "mfg": "Inventec", "pname": "CI-Anacapa",
206
+ * "pn": "10000000001", "ver": "MP",
207
+ * "serial": "10000000000000", "atag": "QEMU" }
208
+ * }
209
+ */
210
+static const uint8_t hpm_brd_id_eeprom[] = {
211
+ 0x01, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0xf6, 0x01, 0x07, 0x19, 0x41,
212
+ 0x2d, 0xf2, 0xc8, 0x49, 0x6e, 0x76, 0x65, 0x6e, 0x74, 0x65, 0x63, 0xd2,
213
+ 0x41, 0x6e, 0x61, 0x63, 0x61, 0x70, 0x61, 0x20, 0x48, 0x50, 0x4d, 0x20,
214
+ 0x42, 0x52, 0x44, 0x20, 0x49, 0x44, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00,
215
+ 0x00, 0x00, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0xc0, 0xc1, 0x00,
216
+ 0x00, 0x00, 0x00, 0x42, 0x01, 0x06, 0x19, 0xc8, 0x49, 0x6e, 0x76, 0x65,
217
+ 0x6e, 0x74, 0x65, 0x63, 0xca, 0x43, 0x49, 0x2d, 0x41, 0x6e, 0x61, 0x63,
218
+ 0x61, 0x70, 0x61, 0x46, 0x10, 0x00, 0x00, 0x00, 0x00, 0x1a, 0x82, 0x2d,
219
+ 0x0c, 0x47, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0x71, 0xd9,
220
+ 0xd6, 0xc0, 0xc1, 0x0e
221
+};
222
+static const size_t hpm_brd_id_eeprom_len = sizeof(hpm_brd_id_eeprom);
223
+
224
static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
225
{
226
/* Reference: aspeed-bmc-facebook-anacapa.dts */
@@ -50,7 +251,8 @@ static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
251
252
/* &i2c6 */
253
/* eeprom@50 */
53
- at24c_eeprom_init(i2c[6], 0x50, 32 * KiB);
254
+ at24c_eeprom_init_rom(i2c[6], 0x50, 32 * KiB,
255
+ hpm_eeprom, hpm_eeprom_len);
256
257
/* &i2c8 */
258
/* i2c-mux@72 (PCA9546) */
@@ -65,7 +267,8 @@ static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
267
i2c_slave_create_simple(pca954x_i2c_get_bus(i2c_mux, 0),
268
TYPE_PCA9552, 0x24);
269
/* eeprom@50 */
68
- at24c_eeprom_init(pca954x_i2c_get_bus(i2c_mux, 0), 0x50, 16 * KiB);
270
+ at24c_eeprom_init_rom(pca954x_i2c_get_bus(i2c_mux, 0), 0x50, 16 * KiB,
271
+ rpdb_eeprom, rpdb_eeprom_len);
272
273
/* i2c8mux ch1 */
274
/* pca9555@22 */
@@ -75,13 +278,16 @@ static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
278
i2c_slave_create_simple(pca954x_i2c_get_bus(i2c_mux, 1),
279
TYPE_PCA9552, 0x24);
280
/* eeprom@50 */
78
- at24c_eeprom_init(pca954x_i2c_get_bus(i2c_mux, 1), 0x50, 16 * KiB);
281
+ at24c_eeprom_init_rom(pca954x_i2c_get_bus(i2c_mux, 1), 0x50, 16 * KiB,
282
+ lpdb_eeprom, lpdb_eeprom_len);
283
284
/* &i2c9 */
285
/* eeprom@50 */
82
- at24c_eeprom_init(i2c[9], 0x50, 16 * KiB);
286
+ at24c_eeprom_init_rom(i2c[9], 0x50, 16 * KiB,
287
+ scm_eeprom, scm_eeprom_len);
288
/* eeprom@56 */
84
- at24c_eeprom_init(i2c[9], 0x56, 8 * KiB);
289
+ at24c_eeprom_init_rom(i2c[9], 0x56, 8 * KiB,
290
+ bsm_eeprom, bsm_eeprom_len);
291
292
/* &i2c10 */
293
/* i2c-mux@71 (PCA9548) */
@@ -92,7 +298,8 @@ static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
298
i2c_slave_create_simple(pca954x_i2c_get_bus(i2c_mux, 5),
299
TYPE_PCA9552, 0x22);
300
/* eeprom@52 */
95
- at24c_eeprom_init(pca954x_i2c_get_bus(i2c_mux, 5), 0x52, 32 * KiB);
301
+ at24c_eeprom_init_rom(pca954x_i2c_get_bus(i2c_mux, 5), 0x52, 32 * KiB,
302
+ rbb_eeprom, rbb_eeprom_len);
303
304
/* &i2c11 */
305
/* i2c-mux@71 (PCA9548) */
@@ -105,7 +312,8 @@ static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
312
i2c_slave_create_simple(pca954x_i2c_get_bus(i2c_mux, 5),
313
TYPE_PCA9552, 0x22);
314
/* eeprom@52 */
108
- at24c_eeprom_init(pca954x_i2c_get_bus(i2c_mux, 5), 0x52, 32 * KiB);
315
+ at24c_eeprom_init_rom(pca954x_i2c_get_bus(i2c_mux, 5), 0x52, 32 * KiB,
316
+ lbb_eeprom, lbb_eeprom_len);
317
318
/* &i2c13 */
319
/* i2c-mux@70 (PCA9548) */
@@ -116,7 +324,8 @@ static void anacapa_bmc_i2c_init(AspeedMachineState *bmc)
324
325
/* i2c13mux ch4 */
326
/* eeprom@51 */
119
- at24c_eeprom_init(pca954x_i2c_get_bus(i2c_mux, 4), 0x51, 32 * KiB);
327
+ at24c_eeprom_init_rom(pca954x_i2c_get_bus(i2c_mux, 4), 0x51, 32 * KiB,
328
+ hpm_brd_id_eeprom, hpm_brd_id_eeprom_len);
329
330
/* i2c13mux ch7 */
331
/* nfc@28 — no model */