summaryrefslogtreecommitdiff
path: root/sysutils/flashrom
diff options
context:
space:
mode:
authornia <nia@pkgsrc.org>2019-06-05 07:52:58 +0000
committernia <nia@pkgsrc.org>2019-06-05 07:52:58 +0000
commit85648dc052952ab76a6a2ce495ddab240d51a20c (patch)
treee82408472f5eee541052cf5804b7822883fe1345 /sysutils/flashrom
parent967c507137c70e54caf2952ae027ca5301e2c3b4 (diff)
downloadpkgsrc-85648dc052952ab76a6a2ce495ddab240d51a20c.tar.gz
flashrom: Update to 1.0.1
Tested by flashing and reading an internal Winbond ROM on NetBSD-current. # flashrom/1.0.1 6b9e934f linux_spi: Reduce maximum read chunksize Improves compatibility with older Linux kernels that interpreted the interface differently. 30c4cecd Makefile: Disable `-Werror=deprecated-declarations` on release branch Just to be able to compile the 1.0.x branch on newer systems. 5639af64 linux_spi: Hardcode default spispeed of 2MHz Default speed of kernel drivers isn't always sane (any more). 993e162d dediprog: Fix small, unaligned reads An actual bug, discovered during experiments with arbitrary layouts. ec8b8a7f board_enable.c: Fix dmi_match string for ThinkPad X201 Probably just wasn't tested before. 69f96f60 Fix verification with sparse layouts A regression that sneaked into flashrom-1.0: When verifying the whole flash after a partial write with a sparse layout (i.e. a layout whose regions don't cover the whole chip), flashrom tried to verify against the wrong data and failed. a3db7ed5 Fix erasing of unaligned regions This never worked correctly from the beginning. We completely erased every block that touched an included layout region. Now, we restore surrounding data in case a block expands beyond the region. # flashrom/1.0 New major user-visible features Support layouts for read and erase commands New command line switch --noverify-all (-N) allows flashing of individual regions without reading the whole flash chip (particular useful with locked down Intel ME firmware) New command line switch --ifd to read the layout from an Intel Firmware Descriptor on flash We got rid of the delay-loop calibration (if the OS provides an accurate timer through clock_gettime()) Reading speed of USB programmers should have increased (reading bigger chunks at once, we reduce the overhead) Support Intel 100 series PCHs (Sunrise Point, coupled with Skylake and Kaby Lake) and C620 series PCHs (Lewisburg paired with Workstation/Server versions of the former) New programmers Intel 100 series / C620 series PCHs Intel I210 NICs (EEPROM and SPI) AMD Merlin Falcon (FP4) New chips W25Q128.W # flashrom/0.9.9 New major user-visible features Allow to link flashrom statically (with make CONFIG_STATIC=yes) Ease debugging of build problems with libraries Output way more debug information to build_details.txt Provide list of set make configuration variables that make builds fail Allow to easily disable groups of programmers depending on a library (make CONFIG_ENABLE_LIBUSB0_PROGRAMMERS=no CONFIG_ENABLE_LIBUSB1_PROGRAMMERS=no CONFIG_ENABLE_LIBPCI_PROGRAMMERS=no) Ignore 0x00 as a flash chip manufacturer ID in the generic match to avoid ambiguous messages Various improvements for serprog-based programmers Support arbitrary UART baud rates on Windows New programmers Enable the dediprog module by default, add support for Dediprog SF600 and the new communication protocol of the SF100 with newer firmware. WCH CH341A VIA VT8251 Add support to update the firmware of Promise UltraATA controllers New chips ESI ES25P40, ES25P80 and ES25P16 GigaDevice GD25VQ41B, GD25Q128C, GD25VQ21B, GD25VQ40C, GD25VQ80C and GD25VQ16C, GD25LQ40, GD25LQ80, GD25LQ16, GD25LQ64(B), GD25LQ128 PMC Pm25LQ020, Pm25LQ040, Pm25LQ080, Pm25LQ016, Pm25LQ032C Sanyo LE25FU406C/LE25U40CMC SST SST25WF020A, SST25WF040B, SST25WF080B Winbond W29C512A/W29EE512 Infrastructural improvements and fixes Add support for libftdi1 (previous libftdi support still in place for backward compatibility but will eventually be removed) Add infrastructure for libusb1 and use it for new programmers (existing code will be migrated from libusb0 continuously in the future) Many cross-platform and cross-architecture improvements: Fix compilation on OSX and Solaris-based systems Add support for GNU Hurd Add support for musl libc Use nanosleep() instead of usleep() where available (enables building with uclibc) Support compilation on Android (bionic libc) Partial architecture support for alpha hppa m68k sh s39 Rigorously check integrity of I/O stream data (e.g. to notice full filesystems when writing flash data to a file) Add make parameters for easier disabling/enabling of various classes of programmers: CONFIG_NOTHING=yes CONFIG_EVERYTHING=yes CONFIG_ENABLE_LIBUSB0_PROGRAMMERS=no CONFIG_ENABLE_LIBUSB1_PROGRAMMERS=no CONFIG_ENABLE_LIBPCI_PROGRAMMERS=no # flashrom/0.9.8 New major user-visible features A bunch of newly supported architectures: ARM 64bit, big-endian ARM, PowerPC 64bit, SPARC. Better support for AMD chipsets in general (speed selection, more conservative defaults etc.). Add new programmer support: AMD Yangtze's SPI controller (found in Kabini and Tamesh) as well as the one in Bolton FCHs (A78, A88X, A77E). Intel Silvermont chipsets (Bay Trail, Rangeley and Avoton) and Wildcat Point (for Broadwell). ITE IT8212F parallel programmer as it8212 (found on PCI SATA RAID controllers). VIA VT6421A LPC programmer as atavia (found on PCI SATA controllers). EEPROMs on Intel network cards based on the 82580 NIC (nicintel_eeprom). Intel 82599 10 GbE NICs boot PROMs (part of nicintel_spi). Microchip PICkit 2 MSTAR I²C ISP protocol (not compiled in by default). Rewrites the firmware of your screen over VGA/DVI(!). Extension of the rayer_spi module to supported various similar devices (Altera ByteBlasterMV, Atmel STK200/300, Wiggler LPT). Switching betweens chips on boards with GIGABYTE's DualBIOS (using the dualbiosindex programmer parameter). Enable fwh_idsel parameter for C-ICH and ICH2/3/4/5 chipsets. Finer-grained display of support status used for flash chip operations, chipsets, mainboards and programmers (new states: configuration-dependent, not applicable). New chips 29GL series of chip families (EON EN29GL, ISSI (PMC) IS29GL, Macronix MX29GL (+MX68GL1G0F), Winbond W29GL) Atmel (now Adesto) AT45DB family + AT45CS1282, as well as AT25DL081 and AT25DL161. Atmel AT49LH004 and AT49LH00B4 Eon EN25P family Eon EN29LV040 and EN29LV040A ESMT F25L32PA Fujitsu MBM29LV160BE/TE Macronix MX23L1654, MX23L3254, MX23L6454, MX23L12854 (the first supported mask ROMs) Macronix MX25L6495F Macronix MX25U12835F Macronix MX29F022(N)B and MX29F022(N)T Sanyo LE25FW106, LE25FW406A and LE25FU406B Spansion S25FL127S, S25FL128P, S25FL129P, S25FL132K and S25FL164K SST25LF020A, SST25WF080, SST25VF512A, SST25VF020 and SST25VF020B ST M50LPW080 Winbond W25Q40.V Infrastructural improvements and fixes Automatic unmapping and rounding of memory maps. Using an internal DMI decoder instead of relying on dmidecode. Addition of getrevision.sh to retrieve various data from SCM systems. Removal of yet another bunch of exit() calls and other code that interferes with the creation of libflashrom. First huge step to refactor Intel Chipset Enables. Various cross-platform improvements (e.g. a more unified operating system and CPU architecture detection). By setting CONFIG_EVERYTHING=yes at compile time all modules that are disabled by default will be compiled in.
Diffstat (limited to 'sysutils/flashrom')
-rw-r--r--sysutils/flashrom/Makefile12
-rw-r--r--sysutils/flashrom/distinfo12
-rw-r--r--sysutils/flashrom/patches/patch-flashrom.c22
-rw-r--r--sysutils/flashrom/patches/patch-hwaccess.c72
4 files changed, 11 insertions, 107 deletions
diff --git a/sysutils/flashrom/Makefile b/sysutils/flashrom/Makefile
index 67acc88b1bc..2b3f39d8c3a 100644
--- a/sysutils/flashrom/Makefile
+++ b/sysutils/flashrom/Makefile
@@ -1,14 +1,14 @@
-# $NetBSD: Makefile,v 1.9 2016/02/26 10:24:12 jperkin Exp $
+# $NetBSD: Makefile,v 1.10 2019/06/05 07:52:58 nia Exp $
#
-DISTNAME= flashrom-0.9.7
-PKGNAME= ${DISTNAME:S/-r/pre/}
+DISTNAME= flashrom-v1.0.1
+PKGNAME= ${DISTNAME:S/-v/-/}
CATEGORIES= sysutils
-MASTER_SITES= http://download.flashrom.org/releases/
+MASTER_SITES= https://download.flashrom.org/releases/
EXTRACT_SUFX= .tar.bz2
MAINTAINER= jakllsch@NetBSD.org
-HOMEPAGE= http://www.flashrom.org/
+HOMEPAGE= https://www.flashrom.org/
COMMENT= Universal (coreboot/LinuxBIOS) flash utility
LICENSE= gnu-gpl-v2
@@ -42,6 +42,6 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/flashrom ${DESTDIR}${PREFIX}/sbin/flashrom
${INSTALL_MAN} ${WRKSRC}/flashrom.8 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8/flashrom.8
-.include "../../devel/libftdi/buildlink3.mk"
+.include "../../devel/libftdi1/buildlink3.mk"
.include "../../sysutils/pciutils/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/sysutils/flashrom/distinfo b/sysutils/flashrom/distinfo
index bc6fe24a0cf..b6cb388a976 100644
--- a/sysutils/flashrom/distinfo
+++ b/sysutils/flashrom/distinfo
@@ -1,8 +1,6 @@
-$NetBSD: distinfo,v 1.10 2016/12/22 21:07:17 joerg Exp $
+$NetBSD: distinfo,v 1.11 2019/06/05 07:52:58 nia Exp $
-SHA1 (flashrom-0.9.7.tar.bz2) = d08b4073ea3ebf63f03c3e502f4291f50ef348ee
-RMD160 (flashrom-0.9.7.tar.bz2) = e160e0ac1e0e138702f3f467707175df96b7e6b1
-SHA512 (flashrom-0.9.7.tar.bz2) = a226c1ac3f9c7822b74ca14b7f9b53013110b2cdb66b1f936593c693ee54f19d643cc3a97a9635c05f2c959aca817668006f609ddb503a84d0bf5d510065674e
-Size (flashrom-0.9.7.tar.bz2) = 408883 bytes
-SHA1 (patch-flashrom.c) = 9867fa7ff7d0a55bff5fc0e6c8c6c901af6211f8
-SHA1 (patch-hwaccess.c) = a76c1def47b8b3a79c8d024c43c510f3989bd6d9
+SHA1 (flashrom-v1.0.1.tar.bz2) = d81f845c78584b037862b5f73065b28d900c5628
+RMD160 (flashrom-v1.0.1.tar.bz2) = 6cf0e87c11feac88a38b7041a6c7379c0e26da80
+SHA512 (flashrom-v1.0.1.tar.bz2) = 77332d8a8f22c38a2a1a306d8b6969e3e96082cd768dcc4f13de989a634b33813412ca1a939737f6c020b36743eaca87a2d46d071fe11f7b0d64efc80f6b8080
+Size (flashrom-v1.0.1.tar.bz2) = 325720 bytes
diff --git a/sysutils/flashrom/patches/patch-flashrom.c b/sysutils/flashrom/patches/patch-flashrom.c
deleted file mode 100644
index d4d10b3bcf9..00000000000
--- a/sysutils/flashrom/patches/patch-flashrom.c
+++ /dev/null
@@ -1,22 +0,0 @@
-$NetBSD: patch-flashrom.c,v 1.1 2014/03/06 15:46:39 joerg Exp $
-
---- flashrom.c.orig 2014-03-02 13:42:29.000000000 +0000
-+++ flashrom.c
-@@ -1738,7 +1738,7 @@ int selfcheck(void)
- * For 'flashchips' we check the first element to be non-null. In the
- * other cases there exist use cases where the first element can be
- * null. */
-- if (flashchips == NULL || flashchips[0].vendor == NULL) {
-+ if (flashchips[0].vendor == NULL) {
- msg_gerr("Flashchips table miscompilation!\n");
- ret = 1;
- }
-@@ -1746,7 +1746,7 @@ int selfcheck(void)
- if (selfcheck_eraseblocks(chip))
- ret = 1;
-
--#if CONFIG_INTERNAL == 1
-+#if 0 && CONFIG_INTERNAL == 1
- if (chipset_enables == NULL) {
- msg_gerr("Chipset enables table does not exist!\n");
- ret = 1;
diff --git a/sysutils/flashrom/patches/patch-hwaccess.c b/sysutils/flashrom/patches/patch-hwaccess.c
deleted file mode 100644
index fe0c320186c..00000000000
--- a/sysutils/flashrom/patches/patch-hwaccess.c
+++ /dev/null
@@ -1,72 +0,0 @@
-$NetBSD: patch-hwaccess.c,v 1.1 2016/12/22 21:07:17 joerg Exp $
-
-It is UB whether define() is not handled inside macro expansions.
-
---- hwaccess.c.orig 2016-12-22 15:40:41.401773946 +0000
-+++ hwaccess.c
-@@ -18,16 +18,40 @@
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
- */
-
--#define IS_X86 (defined(__i386__) || defined(__x86_64__) || defined(__amd64__))
--#define IS_MIPS (defined (__mips) || defined (__mips__) || defined (__MIPS__) || defined (mips))
--#define IS_PPC (defined(__powerpc__) || defined(__powerpc64__) || defined(__ppc__) || defined(__ppc64__))
--#define IS_ARM (defined (__arm__) || defined (_ARM))
-+#if defined(__i386__) || defined(__x86_64__) || defined(__amd64__)
-+#define IS_X86 1
-+#else
-+#define IS_X86 0
-+#endif
-+#if defined (__mips) || defined (__mips__) || defined (__MIPS__) || defined (mips)
-+#define IS_MIPS 1
-+#else
-+#define IS_MIPS 0
-+#endif
-+#if defined(__powerpc__) || defined(__powerpc64__) || defined(__ppc__) || defined(__ppc64__)
-+#define IS_PPC 1
-+#else
-+#define IS_PPC 0
-+#endif
-+#if defined (__arm__) || defined (_ARM)
-+#define IS_ARM 1
-+#else
-+#define IS_ARM 0
-+#endif
- #if !(IS_X86 || IS_MIPS || IS_PPC || IS_ARM)
- #error Unknown architecture
- #endif
-
--#define IS_LINUX (defined(__gnu_linux__) || defined(__linux__))
--#define IS_MACOSX (defined(__APPLE__) && defined(__MACH__))
-+#if defined(__gnu_linux__) || defined(__linux__)
-+#define IS_LINUX 1
-+#else
-+#define IS_LINUX 0
-+#endif
-+#if defined(__APPLE__) && defined(__MACH__)
-+#define IS_MACOSX 1
-+#else
-+#define IS_MACOSX 0
-+#endif
- #if !(IS_LINUX || IS_MACOSX || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) || defined(__DJGPP__) || defined(__LIBPAYLOAD__) || defined(__sun))
- #error "Unknown operating system"
- #endif
-@@ -45,8 +69,16 @@
- #include "flash.h"
- #include "hwaccess.h"
-
--#define USE_IOPL (IS_LINUX || IS_MACOSX || defined(__NetBSD__) || defined(__OpenBSD__))
--#define USE_DEV_IO (defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__))
-+#if IS_LINUX || IS_MACOSX || defined(__NetBSD__) || defined(__OpenBSD__)
-+#define USE_IOPL 1
-+#else
-+#define USE_IOPL 0
-+#endif
-+#if (defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__))
-+#define USE_DEV_IO 1
-+#else
-+#define USE_DEV_IO 0
-+#endif
-
- #if IS_X86 && USE_DEV_IO
- int io_fd;