Skip to content

Commit c2558fa

Browse files
author
stefanct
committed
Add a bunch of new/tested stuff and various small changes 24.
Tested mainboards: OK: - ASRock G31M-GS Reported by Александр Трубицын - ASRock G41M-VS3 Reported by Александр Трубицын - ASRock N68C-S UCC Reported by Alexey Belyaev - ASRock AMCP7AION-HT (ION 330HT(-BD)) Reported by Stefan Tauner - ASUS P5K SE Reported by Александр Трубицын - ASUS P5KPL-VM Reported by Marin Vlah - ASUS RAMPAGE III GENE Reported by stevessss on IRC - GIGABYTE GA-945GM-S2 Reported by Александр Трубицын - GIGABYTE GA-945GCM-S2 (rev. 3.0) Reported by Александр Трубицын - GIGABYTE GA-965P-S3 Reported by Александр Трубицын - GIGABYTE GA-EG43M-S2H Reported by Александр Трубицын - GIGABYTE GA-EP31-DS3L (rev. 1.0) Reported by Александр Трубицын - GIGABYTE GA-G33M-S2 Reported by Александр Трубицын - GIGABYTE GA-G33M-S2L Reported by Александр Трубицын - GIGABYTE GA-H55M-S2 Reported by Александр Трубицын - GIGABYTE GA-J1900N-D3V Reported by Marcos Truchado and Guillermo von Hünefeld - GIGABYTE GA-K8NS Reported by nicolae788 - GIGABYTE GA-M56S-S3 Reported by Estevo Paz Freire - GIGABYTE GA-P31-DS3L Reported by Александр Трубицын - GIGABYTE GA-P31-S3G Reported by Александр Трубицын - MSI MS-7336 Reported by Benjamin Bellec - MSI X79A-GD45 (8D) (MS-7760)" Reported by mortehu on IRC - Supermicro A1SAi-2550F Reported by Bernard Grymonpon - Supermicro X7DWT Reported by Steven Stremciuc Laptop: - ASUS U38N Reported by Ultra on IRC - Dell Latitude D630 Reported by Márton Miklós - Fujitsu Amilo Xi 3650 Reported by Elmar Stellnberger - Lenovo T400 (whitelisting only) Chipsets: - Mark 8086:1f38 (Intel Avoton/Rangeley) as tested Reported by Jeremy Porter and Bernard Grymonpon - Add Intel Sunrise Point IDs but no support yet. Flash chips: - Atmel AT45DB321D to PREW (+PREW) Reported by The Raven - Eon EN25QH32 to PREW (+PREW) Reported by Josua Mayer - Eon EN25QH64 to PREW (+EW) Reported by David s. Alessio - GigaDevice GD25LQ64(B) to PREW (+PREW) Reported by Greg Tippit - Intel 28F001BN/BX-T to PREW (+EW) Reported by Lu Xie - Micron M25P10-A to PREW (+W) Reported by the Raven - Micron M25PE40 Reported by David Wood - Micron N25Q128..3E to PREW (+PREW) Reported by Miklós Márton - Macronix MX25L3273E to PREW (+PREW) Reported by Roklobsta on IRC - Macronix MX23L6454 to PR (+PR) Reported by Steven Honeyman - Macronix MX25U6435E/F to PREW (+PREW) Reported by Marcos Truchado and Guillermo von Hünefeld - PMC Pm25LQ032C to PREW (+EW) Reported by Dirk Knop - Spansion S25FL016A to PREW (+EW) Reported by Márton Miklós - Spansion S25FL128S......0 to PREW (+PREW) Reported by Jim Houston - Spansion S25FL204K to PR (+PR) Reported by Thomas Debrunner - SST SST49LF016C to PREW (+EW) Reported by Steven Stremciuc - SST SST39VF040 to PREW (+PREW) Reported by Xavier Bourgeois - SST SST49LF040B to PREW (+EW) Reported by Rikard Åhlund - ST M25P10-A to PREW (+W) Reported by Martijn Schiedon - Winbond W39V040FA to PREW (+EW) Reported by Евгений Черкашин - Winbond W39V080FA to PREW (+EW) Reported by protagonist0 on IRC - Winbond W25Q80.W to PREW (+PREW) Reported by Miklós Márton - Winbond W25X64 to PREW (+REW) Reported by Johannes Krampf and Manuel Dejonghe - Fix ID of AMIC A25LQ64 Reported by Roman Titov - Fix page size of Spansion S25FL129P......1 Copy and paste error from the 128S uniform 256kB variant, probably. - Add Micron/Numonyx phase-change memory IDs Miscellaneous: - Detect Android target OS. No changes are required to build flashrom (excluding programmers with NEED_PCI) on Android. - Update rayerspi (spipgm) URL - Fix max_data_write handling of at45db. - Minor refinement of the README - Mark board enable for the GA-K8NS variants as tested. Tested by "nicolae788" on a board with socket 754. - Mark "Multi-system" chassis as non-laptop case. - Remove W836xx log requests. We got enough (and no one is looking at them for the time being anyway). - serprog: improve invalid reply error message, contributed by Urja Rannikko. - Remove default include paths for MinGW. - Disable implicit rules in the Makefile because we don't need them and they just make the build (imperceptibly) slower. - Enable our own strnlen() implementation not only on DJGPP but also if HAVE_STRNLEN is not defined. This is needed to get older BSDs (e.g. NetBSD 6.0, FreeBSD < 8.0) to work. - Tiny other stuff. Signed-off-by: Stefan Tauner <[email protected]> Acked-by: Stefan Tauner <[email protected]>
1 parent 4ef943f commit c2558fa

20 files changed

+143
-92
lines changed

Makefile

+4-4
Original file line numberDiff line numberDiff line change
@@ -186,11 +186,8 @@ EXEC_SUFFIX := .exe
186186
# MinGW doesn't have the ffs() function, but we can use gcc's __builtin_ffs().
187187
FLASHROM_CFLAGS += -Dffs=__builtin_ffs
188188
# Some functions provided by Microsoft do not work as described in C99 specifications. This macro fixes that
189-
# for MinGW. See http://sourceforge.net/apps/trac/mingw-w64/wiki/printf%20and%20scanf%20family */
189+
# for MinGW. See http://sourceforge.net/p/mingw-w64/wiki2/printf%20and%20scanf%20family/ */
190190
FLASHROM_CFLAGS += -D__USE_MINGW_ANSI_STDIO=1
191-
# libusb-win32/libftdi stuff is usually installed in /usr/local.
192-
CPPFLAGS += -I/usr/local/include
193-
LDFLAGS += -L/usr/local/lib
194191
# For now we disable all PCI-based programmers on Windows/MinGW (no libpci).
195192
ifeq ($(CONFIG_INTERNAL), yes)
196193
UNSUPPORTED_FEATURES += CONFIG_INTERNAL=yes
@@ -1126,4 +1123,7 @@ libpayload: clean
11261123

11271124
.PHONY: all install clean distclean compiler hwlibs features export tarball djgpp-dos featuresavailable libpayload
11281125

1126+
# Disable implicit suffixes and built-in rules (for performance and profit)
1127+
.SUFFIXES:
1128+
11291129
-include $(OBJS:.o=.d)

README

+6-5
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,13 @@ in-system using a supported mainboard, but it also supports flashing of network
88
cards (NICs), SATA controller cards, and other external devices which can
99
program flash chips.
1010

11-
It supports a wide range of DIP32, PLCC32, DIP8, SO8/SOIC8, TSOP32, and TSOP40
12-
chips, which use various protocols such as LPC, FWH, parallel flash, or SPI.
11+
It supports a wide range of flash chips (most commonly found in SOIC8, DIP8,
12+
SOIC16, WSON8, PLCC32, DIP32, TSOP32, and TSOP40 packages), which use various
13+
protocols such as LPC, FWH, parallel flash, or SPI.
1314

14-
Do not use flashrom on laptops! The embedded controller (EC) present in many
15-
laptops interacts badly with any flash attempts and can brick your laptop
16-
permanently.
15+
Do not use flashrom on laptops (yet)! The embedded controller (EC) present in
16+
many laptops might interact badly with any attempts to communicate with the
17+
flash chip and may brick your laptop.
1718

1819
Please make a backup of your flash chip before writing to it.
1920

at45db.c

+7-3
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,10 @@ static unsigned int at45db_get_sector_count(struct flashctx *flash)
9999
static uint8_t at45db_prettyprint_protection_register(struct flashctx *flash, uint8_t opcode, const char *regname)
100100
{
101101
const uint8_t cmd[] = { opcode, 0, 0, 0 };
102+
const size_t sec_count = at45db_get_sector_count(flash);
103+
if (sec_count < 2)
104+
return 0;
105+
102106
/* The first two sectors share the first result byte. */
103107
uint8_t buf[at45db_get_sector_count(flash) - 1];
104108

@@ -332,7 +336,7 @@ static int at45db_erase(struct flashctx *flash, uint8_t opcode, unsigned int at4
332336
/* Wait for completion. */
333337
ret = at45db_wait_ready(flash, stepsize, retries);
334338
if (ret != 0)
335-
msg_cerr("%s: chip did not became ready again after sending the erase command!\n", __func__);
339+
msg_cerr("%s: chip did not become ready again after sending the erase command!\n", __func__);
336340

337341
return ret;
338342
}
@@ -463,7 +467,7 @@ static int at45db_fill_buffer1(struct flashctx *flash, const uint8_t *bytes, uns
463467
}
464468

465469
/* Create a suitable buffer to store opcode, address and data chunks for buffer1. */
466-
const unsigned int max_data_write = flash->mst->spi.max_data_write;
470+
const int max_data_write = flash->mst->spi.max_data_write - 4;
467471
const unsigned int max_chunk = (max_data_write > 0 && max_data_write <= page_size) ?
468472
max_data_write : page_size;
469473
uint8_t buf[4 + max_chunk];
@@ -504,7 +508,7 @@ static int at45db_commit_buffer1(struct flashctx *flash, unsigned int at45db_add
504508
/* Wait for completion (typically a few ms). */
505509
ret = at45db_wait_ready(flash, 250, 200); // 50 ms
506510
if (ret != 0) {
507-
msg_cerr("%s: chip did not became ready again!\n", __func__);
511+
msg_cerr("%s: chip did not become ready again!\n", __func__);
508512
return ret;
509513
}
510514

board_enable.c

+9-7
Original file line numberDiff line numberDiff line change
@@ -333,12 +333,9 @@ void probe_superio_winbond(void)
333333
continue;
334334
}
335335
}
336-
msg_pinfo("Active config mode, unknown reg 0x20 ID: %02x.\n", model);
337-
msg_pinfo("Please send the output of \"flashrom -V -p internal\" to \n"
338-
"[email protected] with W836xx: your board name: flashrom -V\n"
339-
"as the subject to help us finish support for your Super I/O. Thanks.\n");
336+
msg_pdbg("Active config mode, unknown reg 0x20 ID: %02x.\n", model);
340337
continue;
341-
}
338+
}
342339
/* The Super I/O reacts to W836xx enter and exit config mode, it's probably Winbond. */
343340
w836xx_ext_enter(s.port);
344341
s.model = sio_read(s.port, 0x20);
@@ -1156,6 +1153,7 @@ static int nvidia_mcp_gpio8_raise(void)
11561153
/*
11571154
* Suited for:
11581155
* - GIGABYTE GA-K8NS Pro-939: Socket 939 + NVIDIA nForce3 + CK8
1156+
* - Probably other versions of the GA-K8NS
11591157
*/
11601158
static int nvidia_mcp_gpio0a_raise(void)
11611159
{
@@ -2387,8 +2385,10 @@ const struct board_match board_matches[] = {
23872385
{0x8086, 0x24dd, 0x1043, 0x80a6, 0x8086, 0x2570, 0x1043, 0x8157, NULL, NULL, NULL, P3, "ASUS", "P5PE-VM", 0, OK, intel_ich_gpio21_raise},
23882386
{0x8086, 0x2443, 0x1043, 0x8027, 0x8086, 0x1130, 0x1043, 0x8027, "^CUSL2-C", NULL, NULL, P3, "ASUS", "CUSL2-C", 0, OK, intel_ich_gpio21_raise},
23892387
{0x8086, 0x2443, 0x1043, 0x8027, 0x8086, 0x1130, 0x1043, 0x8027, "^TUSL2-C", NULL, NULL, P3, "ASUS", "TUSL2-C", 0, NT, intel_ich_gpio21_raise},
2388+
{0x1022, 0x780E, 0x1043, 0x1437, 0x1022, 0x780B, 0x1043, 0x1437, "^U38N$", NULL, NULL, P2, "ASUS", "U38N", 0, OK, p2_whitelist_laptop},
23902389
{0x1106, 0x3059, 0x1106, 0x4161, 0x1106, 0x3065, 0x1106, 0x0102, NULL, NULL, NULL, P3, "Bcom/Clientron", "WinNET P680", 0, OK, w836xx_memw_enable_2e},
23912390
{0x1106, 0x3177, 0x1106, 0x3177, 0x1106, 0x3116, 0x1106, 0x3116, "^KM266-8235$", "biostar", "m7viq", P3, "Biostar", "M7VIQ", 0, NT, w83697xx_memw_enable_2e},
2391+
{0x8086, 0x283e, 0x1028, 0x01f9, 0x8086, 0x2a01, 0, 0, "^Latitude D630", NULL, NULL, P2, "Dell", "Latitude D630", 0, OK, p2_whitelist_laptop},
23922392
{0x10b7, 0x9055, 0x1028, 0x0082, 0x8086, 0x7190, 0, 0, NULL, NULL, NULL, P3, "Dell", "OptiPlex GX1", 0, OK, intel_piix4_gpo30_lower},
23932393
{0x8086, 0x3590, 0x1028, 0x016c, 0x1000, 0x0030, 0x1028, 0x016c, NULL, NULL, NULL, P3, "Dell", "PowerEdge 1850", 0, OK, intel_ich_gpio23_raise},
23942394
{0x1106, 0x3189, 0x1106, 0x3189, 0x1106, 0x3177, 0x1106, 0x3177, "^AD77", "dfi", "ad77", P3, "DFI", "AD77", 0, NT, w836xx_memw_enable_2e},
@@ -2401,6 +2401,7 @@ const struct board_match board_matches[] = {
24012401
{0x10EC, 0x8139, 0x1695, 0x9001, 0x11C1, 0x5811, 0x1695, 0x9015, NULL, NULL, NULL, P3, "EPoX", "EP-8RDA3+", 0, OK, nvidia_mcp_gpio31_raise},
24022402
{0x8086, 0x7110, 0, 0, 0x8086, 0x7190, 0, 0, NULL, "epox", "ep-bx3", P3, "EPoX", "EP-BX3", 0, NT, intel_piix4_gpo22_raise},
24032403
{0x10de, 0x02f0, 0x105b, 0x0d01, 0x10de, 0x0264, 0x105b, 0x0d01, NULL, NULL, NULL, P3, "Foxconn", "6150K8MD-8EKRSH", 0, NT, nvidia_mcp_gpio2_raise},
2404+
{0x8086, 0x2A40, 0x1734, 0x1148, 0x8086, 0x2930, 0x1734, 0x1148, "^XY680", NULL, NULL, P2, "Fujitsu", "Amilo Xi 3650", 0, OK, p2_whitelist_laptop},
24042405
{0x8086, 0x2443, 0x8086, 0x2442, 0x8086, 0x1130, 0x8086, 0x1130, "^6IEM ", NULL, NULL, P3, "GIGABYTE", "GA-6IEM", 0, NT, intel_ich_gpio25_raise},
24052406
{0x1106, 0x0686, 0x1106, 0x0686, 0x1106, 0x3058, 0x1458, 0xa000, NULL, NULL, NULL, P3, "GIGABYTE", "GA-7ZM", 512, OK, NULL},
24062407
{0x8086, 0x2570, 0x1458, 0x2570, 0x8086, 0x24d0, 0, 0, "^8IP775/-G$",NULL, NULL, P3, "GIGABYTE", "GA-8IP775", 0, OK, intel_ich_gpio32_raise},
@@ -2410,7 +2411,7 @@ const struct board_match board_matches[] = {
24102411
{0x1039, 0x0651, 0x1039, 0x0651, 0x1039, 0x7002, 0x1458, 0x5004, "^GA-8SIMLH$",NULL, NULL, P3, "GIGABYTE", "GA-8SIMLH", 0, OK, sis_gpio0_raise_and_w836xx_memw},
24112412
{0x10DE, 0x02F1, 0x1458, 0x5000, 0x10DE, 0x0261, 0x1458, 0x5001, NULL, NULL, NULL, P3, "GIGABYTE", "GA-K8N51GMF", 0, OK, nvidia_mcp_gpio3b_raise},
24122413
{0x10DE, 0x026C, 0x1458, 0xA102, 0x10DE, 0x0260, 0x1458, 0x5001, NULL, NULL, NULL, P3, "GIGABYTE", "GA-K8N51GMF-9", 0, OK, nvidia_mcp_gpio3b_raise},
2413-
{0x10de, 0x00e4, 0x1458, 0x0c11, 0x10de, 0x00e0, 0x1458, 0x0c11, NULL, NULL, NULL, P3, "GIGABYTE", "GA-K8NS Pro-939", 0, NT, nvidia_mcp_gpio0a_raise},
2414+
{0x10DE, 0x00E4, 0x1458, 0x0C11, 0x10DE, 0x00E0, 0x1458, 0x0C11, NULL, NULL, NULL, P3, "GIGABYTE", "GA-K8NS", 0, OK, nvidia_mcp_gpio0a_raise},
24142415
{0x10DE, 0x0050, 0x1458, 0x0C11, 0x10DE, 0x005e, 0x1458, 0x5000, NULL, NULL, NULL, P3, "GIGABYTE", "GA-K8N-SLI", 0, OK, nvidia_mcp_gpio21_raise},
24152416
{0x8086, 0x2415, 0x103c, 0x1250, 0x10b7, 0x9200, 0x103c, 0x1247, NULL, NULL, NULL, P3, "HP", "e-Vectra P2706T", 0, OK, board_hp_p2706t},
24162417
{0x1166, 0x0223, 0x103c, 0x320d, 0x14e4, 0x1678, 0x103c, 0x703e, NULL, "hp", "dl145_g3", P3, "HP", "ProLiant DL145 G3", 0, OK, board_hp_dl145_g3_enable},
@@ -2426,10 +2427,11 @@ const struct board_match board_matches[] = {
24262427
{0x8086, 0x7190, 0, 0, 0x8086, 0x7110, 0, 0, "^SE440BX-2$", NULL, NULL, P3, "Intel", "SE440BX-2", 0, NT, intel_piix4_gpo27_lower},
24272428
{0x1022, 0x7468, 0, 0, 0x1022, 0x7460, 0, 0, NULL, "iwill", "dk8_htx", P3, "IWILL", "DK8-HTX", 0, OK, w83627hf_gpio24_raise_2e},
24282429
{0x8086, 0x27A0, 0x8086, 0x27a0, 0x8086, 0x27b8, 0x8086, 0x27b8, NULL, "kontron", "986lcd-m", P3, "Kontron", "986LCD-M", 0, OK, board_kontron_986lcd_m},
2430+
{0x8086, 0x2917, 0x17AA, 0x20F5, 0x8086, 0x2930, 0x17AA, 0x20F9, "^ThinkPad T400", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad T400", 0, OK, p2_whitelist_laptop},
24292431
{0x8086, 0x1E22, 0x17AA, 0x21F6, 0x8086, 0x1E55, 0x17AA, 0x21F6, "^ThinkPad T530", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad T530", 0, OK, p2_whitelist_laptop},
24302432
{0x8086, 0x27a0, 0x17aa, 0x2015, 0x8086, 0x27b9, 0x17aa, 0x2009, "^ThinkPad T60", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad T60", 0, OK, p2_whitelist_laptop},
24312433
{0x8086, 0x27a0, 0x17aa, 0x2017, 0x8086, 0x27b9, 0x17aa, 0x2009, "^ThinkPad T60", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad T60(s)", 0, OK, p2_whitelist_laptop},
2432-
{0x8086, 0x2917, 0x17AA, 0x20F5, 0x8086, 0x2930, 0x17AA, 0x20F9, "^ThinkPad X200$", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad X200", 0, OK, p2_whitelist_laptop},
2434+
{0x8086, 0x2917, 0x17AA, 0x20F5, 0x8086, 0x2930, 0x17AA, 0x20F9, "^ThinkPad X200", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad X200", 0, OK, p2_whitelist_laptop},
24332435
{0x8086, 0x3B07, 0x17AA, 0x2166, 0x8086, 0x3B30, 0x17AA, 0x2167, "^Lenovo X201", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad X201", 0, OK, p2_whitelist_laptop},
24342436
{0x8086, 0x1E22, 0x17AA, 0x21FA, 0x8086, 0x1E55, 0x17AA, 0x21FA, "^ThinkPad X230", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad X230", 0, OK, p2_whitelist_laptop},
24352437
{0x8086, 0x27A0, 0x17AA, 0x2017, 0x8086, 0x27B9, 0x17AA, 0x2009, "^ThinkPad X60", NULL, NULL, P2, "IBM/Lenovo", "ThinkPad X60(s)", 0, OK, p2_whitelist_laptop},

chipset_enable.c

+10-3
Original file line numberDiff line numberDiff line change
@@ -1632,7 +1632,7 @@ const struct penable chipset_enables[] = {
16321632
{0x8086, 0x1e5d, NT, "Intel", "HM75", enable_flash_pch7},
16331633
{0x8086, 0x1e5e, NT, "Intel", "HM70", enable_flash_pch7},
16341634
{0x8086, 0x1e5f, DEP, "Intel", "NM70", enable_flash_pch7},
1635-
{0x8086, 0x1f38, NT, "Intel", "Avoton/Rangeley", enable_flash_silvermont},
1635+
{0x8086, 0x1f38, DEP, "Intel", "Avoton/Rangeley", enable_flash_silvermont},
16361636
{0x8086, 0x1f39, NT, "Intel", "Avoton/Rangeley", enable_flash_silvermont},
16371637
{0x8086, 0x1f3a, NT, "Intel", "Avoton/Rangeley", enable_flash_silvermont},
16381638
{0x8086, 0x1f3b, NT, "Intel", "Avoton/Rangeley", enable_flash_silvermont},
@@ -1781,6 +1781,10 @@ const struct penable chipset_enables[] = {
17811781
{0x8086, 0x9cc7, NT, "Intel", "Broadwell Y Premium", enable_flash_pch9},
17821782
{0x8086, 0x9cc9, NT, "Intel", "Broadwell Y Base", enable_flash_pch9},
17831783
{0x8086, 0x9ccb, NT, "Intel", "Broadwell H", enable_flash_pch9},
1784+
{0x8086, 0x9d41, BAD, "Intel", "Sunrise Point (Skylake LP Sample)", NULL},
1785+
{0x8086, 0x9d43, BAD, "Intel", "Sunrise Point (Skylake-U Base)", NULL},
1786+
{0x8086, 0x9d48, BAD, "Intel", "Sunrise Point (Skylake-U Premium)", NULL},
1787+
{0x8086, 0x9d46, BAD, "Intel", "Sunrise Point (Skylake-Y Premium)", NULL},
17841788
#endif
17851789
{0},
17861790
};
@@ -1816,6 +1820,10 @@ int chipset_flash_enable(void)
18161820
chipset_enables[i].device_id);
18171821
msg_pinfo(".\n");
18181822

1823+
if (chipset_enables[i].status == BAD) {
1824+
msg_perr("ERROR: This chipset is not supported yet.\n");
1825+
return ERROR_FATAL;
1826+
}
18191827
if (chipset_enables[i].status == NT) {
18201828
msg_pinfo("This chipset is marked as untested. If "
18211829
"you are using an up-to-date version\nof "
@@ -1826,8 +1834,7 @@ int chipset_flash_enable(void)
18261834
"(-V) log.\nThank you!\n");
18271835
}
18281836
msg_pinfo("Enabling flash write... ");
1829-
ret = chipset_enables[i].doit(dev,
1830-
chipset_enables[i].device_name);
1837+
ret = chipset_enables[i].doit(dev, chipset_enables[i].device_name);
18311838
if (ret == NOT_DONE_YET) {
18321839
ret = -2;
18331840
msg_pinfo("OK - searching further chips.\n");

dmi.c

+1
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ static const struct {
9090
{0x11, 0, "Main Server Chassis"},
9191
{0x17, 0, "Rack Mount Chassis"},
9292
{0x18, 0, "Sealed-case PC"}, /* used by Supermicro (X8SIE) */
93+
{0x19, 0, "Multi-system"}, /* used by Supermicro (X7DWT) */
9394
};
9495

9596
#if CONFIG_INTERNAL_DMI == 1

dummyflasher.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -376,8 +376,8 @@ int dummy_init(void)
376376
/* We will silently (in default verbosity) ignore the file if it does not exist (yet) or the size does
377377
* not match the emulated chip. */
378378
if (!stat(emu_persistent_image, &image_stat)) {
379-
msg_pdbg("Found persistent image %s, size %li ",
380-
emu_persistent_image, (long)image_stat.st_size);
379+
msg_pdbg("Found persistent image %s, %jd B ",
380+
emu_persistent_image, (intmax_t)image_stat.st_size);
381381
if (image_stat.st_size == emu_chip_size) {
382382
msg_pdbg("matches.\n");
383383
msg_pdbg("Reading %s\n", emu_persistent_image);

flash.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ void tolower_string(char *str);
260260
#ifdef __MINGW32__
261261
char* strtok_r(char *str, const char *delim, char **nextp);
262262
#endif
263-
#if defined(__DJGPP__)
263+
#if defined(__DJGPP__) || !defined(HAVE_STRNLEN)
264264
size_t strnlen(const char *str, size_t n);
265265
#endif
266266

0 commit comments

Comments
 (0)