Attention is currently required from: Edward O'Callaghan, Daniel Campello, Angel Pons.
Anastasia Klimchuk has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/60069 )
Change subject: flashrom.c: Make {read,write}_buf_from_include_args() public
......................................................................
Patch Set 3:
(1 comment)
File flash.h:
https://review.coreboot.org/c/flashrom/+/60069/comment/6a178741_26f42847
PS3, Line 353: read_buf_from_include_args
> It's a good idea in theory but read_buf_from_file() [sic. […]
Then maybe libflashrom.h? It has a bunch of layout-specific functions, and even flashrom_layout itself (at the bottom, starting from line 108).
--
To view, visit https://review.coreboot.org/c/flashrom/+/60069
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ia0abec655a682ca449d0e8ba620886a2d616b86d
Gerrit-Change-Number: 60069
Gerrit-PatchSet: 3
Gerrit-Owner: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Daniel Campello <campello(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-CC: Thomas Heijligen <src(a)posteo.de>
Gerrit-Attention: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Attention: Daniel Campello <campello(a)chromium.org>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Comment-Date: Thu, 20 Jan 2022 23:16:20 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Edward O'Callaghan <quasisec(a)chromium.org>
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-MessageType: comment
Nico Huber has submitted this change. ( https://review.coreboot.org/c/flashrom/+/60107 )
Change subject: Makefile: merge compiler, hwlibs, features targets into config target
......................................................................
Makefile: merge compiler, hwlibs, features targets into config target
These targets are all called together. No need to have them individual.
Change-Id: Ic76f923bca2beb6f95b8ea0cced4569b07e9b9ba
Signed-off-by: Thomas Heijligen <thomas.heijligen(a)secunet.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/60107
Tested-by: build bot (Jenkins) <no-reply(a)coreboot.org>
Reviewed-by: Nico Huber <nico.h(a)gmx.de>
---
M Makefile
1 file changed, 12 insertions(+), 25 deletions(-)
Approvals:
build bot (Jenkins): Verified
Nico Huber: Looks good to me, approved
diff --git a/Makefile b/Makefile
index 72d94c8..f26f701 100644
--- a/Makefile
+++ b/Makefile
@@ -899,15 +899,12 @@
LIBFLASHROM_OBJS = $(CHIP_OBJS) $(PROGRAMMER_OBJS) $(LIB_OBJS)
OBJS = $(CLI_OBJS) $(LIBFLASHROM_OBJS)
-all: hwlibs features $(PROGRAM)$(EXEC_SUFFIX) $(PROGRAM).8
+all: config $(PROGRAM)$(EXEC_SUFFIX) $(PROGRAM).8
ifeq ($(ARCH), x86)
@+$(MAKE) -C util/ich_descriptors_tool/ HOST_OS=$(HOST_OS) TARGET_OS=$(TARGET_OS)
endif
-# to define test programs we use verbatim variables, which get exported
-# to environment variables and are referenced with $$<varname> later
-
-compiler: featuresavailable
+config:
@echo -n "C compiler found: "
@if [ $(CC_WORKING) = yes ]; \
then $(CC) --version 2>/dev/null | head -1; \
@@ -921,8 +918,6 @@
echo " This might work but usually does not, please beware."; fi
@echo "Target endian: $(ENDIAN)"
@if [ $(ENDIAN) = unknown ]; then echo Aborting.; exit 1; fi
-
-hwlibs: compiler
@echo Dependency libpci found: $(HAS_LIBPCI)
@if [ $(HAS_LIBPCI) = yes ]; then \
echo " Checking for old \"pci_get_dev()\": $(HAS_PCI_OLD_GET_DEV)";\
@@ -950,30 +945,22 @@
echo " CFLAGS: $(CONFIG_LIBFTDI1_CFLAGS)"; \
echo " LDFLAGS: $(CONFIG_LIBFTDI1_LDFLAGS)"; \
fi
-
-features: hwlibs
@echo "Checking for header \"mtd/mtd-user.h\": $(HAS_LINUX_MTD)"
@echo "Checking for header \"linux/spi/spidev.h\": $(HAS_LINUX_SPI)"
@echo "Checking for header \"linux/i2c-dev.h\": $(HAS_LINUX_I2C)"
@echo "Checking for header \"linux/i2c.h\": $(HAS_LINUX_I2C)"
@echo "Checking for header \"sys/utsname.h\": $(HAS_UTSNAME)"
@echo "Checking for function \"clock_gettime\": $(HAS_CLOCK_GETTIME)"
+ @if ! [ "$(PROGRAMMER_OBJS)" ]; then \
+ echo "You have to enable at least one programmer driver!"; \
+ exit 1; \
+ fi
+ @if [ "$(UNSUPPORTED_FEATURES)" ]; then \
+ echo "The following features are unavailable on your machine: $(UNSUPPORTED_FEATURES)" \
+ exit 1; \
+ fi
-# If a user does not explicitly request a non-working feature, we should
-# silently disable it. However, if a non-working (does not compile) feature
-# is explicitly requested, we should bail out with a descriptive error message.
-# We also have to check that at least one programmer driver is enabled.
-featuresavailable:
-ifeq ($(PROGRAMMER_OBJS),)
- @echo "You have to enable at least one programmer driver!"
- @false
-endif
-ifneq ($(UNSUPPORTED_FEATURES), )
- @echo "The following features are unavailable on your machine: $(UNSUPPORTED_FEATURES)"
- @false
-endif
-
-%.o: %.c features
+%.o: %.c config
$(CC) -MMD $(CFLAGS) $(CPPFLAGS) $(FLASHROM_CFLAGS) $(FEATURE_CFLAGS) $(SCMDEF) -o $@ -c $<
$(PROGRAM)$(EXEC_SUFFIX): $(OBJS)
@@ -1053,7 +1040,7 @@
libpayload: clean
make CC="CC=i386-elf-gcc lpgcc" AR=i386-elf-ar RANLIB=i386-elf-ranlib
-.PHONY: all install clean distclean compiler hwlibs features _export export tarball featuresavailable libpayload
+.PHONY: all install clean distclean config _export export tarball libpayload
# Disable implicit suffixes and built-in rules (for performance and profit)
.SUFFIXES:
10 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
--
To view, visit https://review.coreboot.org/c/flashrom/+/60107
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ic76f923bca2beb6f95b8ea0cced4569b07e9b9ba
Gerrit-Change-Number: 60107
Gerrit-PatchSet: 14
Gerrit-Owner: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-MessageType: merged
Nico Huber has submitted this change. ( https://review.coreboot.org/c/flashrom/+/60836 )
Change subject: Makefile: reorder make targets
......................................................................
Makefile: reorder make targets
Use the order in which the targets get executed.
Change-Id: Ic45c2fc98c679ac7be4ee2860d72b517b8b67a17
Signed-off-by: Thomas Heijligen <thomas.heijligen(a)secunet.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/60836
Tested-by: build bot (Jenkins) <no-reply(a)coreboot.org>
Reviewed-by: Nico Huber <nico.h(a)gmx.de>
---
M Makefile
1 file changed, 36 insertions(+), 35 deletions(-)
Approvals:
build bot (Jenkins): Verified
Nico Huber: Looks good to me, approved
diff --git a/Makefile b/Makefile
index 40b3eac..72d94c8 100644
--- a/Makefile
+++ b/Makefile
@@ -904,34 +904,6 @@
@+$(MAKE) -C util/ich_descriptors_tool/ HOST_OS=$(HOST_OS) TARGET_OS=$(TARGET_OS)
endif
-$(PROGRAM)$(EXEC_SUFFIX): $(OBJS)
- $(CC) -o $(PROGRAM)$(EXEC_SUFFIX) $(OBJS) $(LDFLAGS)
-
-libflashrom.a: $(LIBFLASHROM_OBJS)
- $(AR) rcs $@ $^
- $(RANLIB) $@
-
-# TAROPTIONS reduces information leakage from the packager's system.
-# If other tar programs support command line arguments for setting uid/gid of
-# stored files, they can be handled here as well.
-TAROPTIONS = $(shell LC_ALL=C tar --version|grep -q GNU && echo "--owner=root --group=root")
-
-%.o: %.c features
- $(CC) -MMD $(CFLAGS) $(CPPFLAGS) $(FLASHROM_CFLAGS) $(FEATURE_CFLAGS) $(SCMDEF) -o $@ -c $<
-
-# Make sure to add all names of generated binaries here.
-# This includes all frontends and libflashrom.
-# We don't use EXEC_SUFFIX here because we want to clean everything.
-clean:
- rm -f $(PROGRAM) $(PROGRAM).exe libflashrom.a $(filter-out Makefile.d, $(wildcard *.d *.o)) $(PROGRAM).8 $(PROGRAM).8.html $(BUILD_DETAILS_FILE)
- @+$(MAKE) -C util/ich_descriptors_tool/ clean
-
-distclean: clean
- rm -f .libdeps
-
-strip: $(PROGRAM)$(EXEC_SUFFIX)
- $(STRIP) $(STRIP_ARGS) $(PROGRAM)$(EXEC_SUFFIX)
-
# to define test programs we use verbatim variables, which get exported
# to environment variables and are referenced with $$<varname> later
@@ -979,6 +951,14 @@
echo " LDFLAGS: $(CONFIG_LIBFTDI1_LDFLAGS)"; \
fi
+features: hwlibs
+ @echo "Checking for header \"mtd/mtd-user.h\": $(HAS_LINUX_MTD)"
+ @echo "Checking for header \"linux/spi/spidev.h\": $(HAS_LINUX_SPI)"
+ @echo "Checking for header \"linux/i2c-dev.h\": $(HAS_LINUX_I2C)"
+ @echo "Checking for header \"linux/i2c.h\": $(HAS_LINUX_I2C)"
+ @echo "Checking for header \"sys/utsname.h\": $(HAS_UTSNAME)"
+ @echo "Checking for function \"clock_gettime\": $(HAS_CLOCK_GETTIME)"
+
# If a user does not explicitly request a non-working feature, we should
# silently disable it. However, if a non-working (does not compile) feature
# is explicitly requested, we should bail out with a descriptive error message.
@@ -993,13 +973,15 @@
@false
endif
-features: hwlibs
- @echo "Checking for header \"mtd/mtd-user.h\": $(HAS_LINUX_MTD)"
- @echo "Checking for header \"linux/spi/spidev.h\": $(HAS_LINUX_SPI)"
- @echo "Checking for header \"linux/i2c-dev.h\": $(HAS_LINUX_I2C)"
- @echo "Checking for header \"linux/i2c.h\": $(HAS_LINUX_I2C)"
- @echo "Checking for header \"sys/utsname.h\": $(HAS_UTSNAME)"
- @echo "Checking for function \"clock_gettime\": $(HAS_CLOCK_GETTIME)"
+%.o: %.c features
+ $(CC) -MMD $(CFLAGS) $(CPPFLAGS) $(FLASHROM_CFLAGS) $(FEATURE_CFLAGS) $(SCMDEF) -o $@ -c $<
+
+$(PROGRAM)$(EXEC_SUFFIX): $(OBJS)
+ $(CC) -o $(PROGRAM)$(EXEC_SUFFIX) $(OBJS) $(LDFLAGS)
+
+libflashrom.a: $(LIBFLASHROM_OBJS)
+ $(AR) rcs $@ $^
+ $(RANLIB) $@
$(PROGRAM).8.html: $(PROGRAM).8
@groff -mandoc -Thtml $< >$@
@@ -1008,6 +990,19 @@
@# Add the man page change date and version to the man page
@sed -e 's#.TH FLASHROM 8 .*#.TH FLASHROM 8 "$(MAN_DATE)" "$(VERSION)" "$(MAN_DATE)"#' <$< >$@
+strip: $(PROGRAM)$(EXEC_SUFFIX)
+ $(STRIP) $(STRIP_ARGS) $(PROGRAM)$(EXEC_SUFFIX)
+
+# Make sure to add all names of generated binaries here.
+# This includes all frontends and libflashrom.
+# We don't use EXEC_SUFFIX here because we want to clean everything.
+clean:
+ rm -f $(PROGRAM) $(PROGRAM).exe libflashrom.a $(filter-out Makefile.d, $(wildcard *.d *.o)) $(PROGRAM).8 $(PROGRAM).8.html $(BUILD_DETAILS_FILE)
+ @+$(MAKE) -C util/ich_descriptors_tool/ clean
+
+distclean: clean
+ rm -f .libdeps
+
install: $(PROGRAM)$(EXEC_SUFFIX) $(PROGRAM).8
mkdir -p $(DESTDIR)$(PREFIX)/sbin
mkdir -p $(DESTDIR)$(MANDIR)/man8
@@ -1042,6 +1037,12 @@
export: _export
@echo "Exported $(EXPORTDIR)/flashrom-$(RELEASENAME)/"
+
+# TAROPTIONS reduces information leakage from the packager's system.
+# If other tar programs support command line arguments for setting uid/gid of
+# stored files, they can be handled here as well.
+TAROPTIONS = $(shell LC_ALL=C tar --version|grep -q GNU && echo "--owner=root --group=root")
+
tarball: _export
@tar -cj --format=ustar -f "$(EXPORTDIR)/flashrom-$(RELEASENAME).tar.bz2" -C $(EXPORTDIR)/ \
$(TAROPTIONS) "flashrom-$(RELEASENAME)/"
3 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
--
To view, visit https://review.coreboot.org/c/flashrom/+/60836
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ic45c2fc98c679ac7be4ee2860d72b517b8b67a17
Gerrit-Change-Number: 60836
Gerrit-PatchSet: 7
Gerrit-Owner: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-MessageType: merged
Attention is currently required from: Thomas Heijligen.
Felix Singer has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/61197 )
Change subject: meson: replace target_machine by host_machine
......................................................................
Patch Set 2: Code-Review+2
--
To view, visit https://review.coreboot.org/c/flashrom/+/61197
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I4a32c73052c3707607738c72256fb4366a2bf8ce
Gerrit-Change-Number: 61197
Gerrit-PatchSet: 2
Gerrit-Owner: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Felix Singer <felixsinger(a)posteo.net>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Peter Marheine <pmarheine(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-CC: Paul Menzel <paulepanter(a)mailbox.org>
Gerrit-Attention: Thomas Heijligen <src(a)posteo.de>
Gerrit-Comment-Date: Thu, 20 Jan 2022 15:35:47 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment