Edward O'Callaghan has submitted this change. ( https://review.coreboot.org/c/flashrom/+/67722 )
Change subject: layout.c: Validate _layout_entry_by_name() arguments before use
......................................................................
layout.c: Validate _layout_entry_by_name() arguments before use
It may be the case that a layout could not be derived which
would result in layout logic being fed a NULL pointer. Validate
this case and be defensive to validate the name argument as well.
BUG=b:247055486
TEST=builds
Change-Id: I2a19c0e586f8575b8b3c2c02b5afad312efacfc9
Signed-off-by: Edward O'Callaghan <quasisec(a)google.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/67722
Tested-by: build bot (Jenkins) <no-reply(a)coreboot.org>
Reviewed-by: Angel Pons <th3fanbus(a)gmail.com>
Reviewed-by: Felix Singer <felixsinger(a)posteo.net>
---
M layout.c
1 file changed, 23 insertions(+), 0 deletions(-)
Approvals:
build bot (Jenkins): Verified
Felix Singer: Looks good to me, approved
Angel Pons: Looks good to me, approved
diff --git a/layout.c b/layout.c
index 5916d66..0212699 100644
--- a/layout.c
+++ b/layout.c
@@ -58,6 +58,8 @@
const struct flashrom_layout *const layout, const char *name)
{
struct romentry *entry = NULL;
+ if (!layout || !name)
+ return NULL;
while ((entry = mutable_layout_next(layout, entry))) {
if (!strcmp(entry->name, name))
return entry;
--
To view, visit https://review.coreboot.org/c/flashrom/+/67722
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I2a19c0e586f8575b8b3c2c02b5afad312efacfc9
Gerrit-Change-Number: 67722
Gerrit-PatchSet: 6
Gerrit-Owner: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Felix Singer <felixsinger(a)posteo.net>
Gerrit-Reviewer: Nikolai Artemiev <nartemiev(a)google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-MessageType: merged
Attention is currently required from: Thomas Heijligen.
Edward O'Callaghan has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/67655 )
Change subject: atapromise.c: Use fallback_map instead of own identical implementation
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit https://review.coreboot.org/c/flashrom/+/67655
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Iea16d42015bdbe838364cc65cff895d9edaf03a7
Gerrit-Change-Number: 67655
Gerrit-PatchSet: 1
Gerrit-Owner: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Jonathon Hall <jonathon.hall(a)puri.sm>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Thomas Heijligen <src(a)posteo.de>
Gerrit-Comment-Date: Tue, 27 Sep 2022 00:18:04 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Jean THOMAS.
Thomas Heijligen has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/67878 )
Change subject: dirtyjtag: Add DirtyJTAG programmer
......................................................................
Patch Set 1:
(4 comments)
Patchset:
PS1:
On first look it seems fine, there are a few minor thinks to do. But I want to have a further look when I'm back from vacation.
Thanks for contributing.
File dirtyjtag_spi.c:
https://review.coreboot.org/c/flashrom/+/67878/comment/cab8673e_b8e96e02
PS1, Line 108: static int dirtyjtag_spi_shutdown(void *data)
the usb interface should also be released
https://review.coreboot.org/c/flashrom/+/67878/comment/5402a410_7911eb82
PS1, Line 194: int ret = libusb_init(NULL);
please use an own libusb_contest and not the default ine (NULL), even if other programmera do so. it can be stored in the djtag_data
https://review.coreboot.org/c/flashrom/+/67878/comment/f5910700_b47025ff
PS1, Line 214: ret = libusb_set_auto_detach_kernel_driver(handle, 1);
this function is only available on new libusb versions. please use explicit detach and attach in shutdown. have a look at the latest patchen on ch341a_spi
--
To view, visit https://review.coreboot.org/c/flashrom/+/67878
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ic43e9a014ed7d04e429e73b30c9dcfdde1a78913
Gerrit-Change-Number: 67878
Gerrit-PatchSet: 1
Gerrit-Owner: Jean THOMAS <virgule(a)jeanthomas.me>
Gerrit-Reviewer: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Jean THOMAS <virgule(a)jeanthomas.me>
Gerrit-Comment-Date: Mon, 26 Sep 2022 21:37:25 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: Patrick Georgi, Edward O'Callaghan, Angel Pons.
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/67860 )
Change subject: test_build.sh: Move build test procedure to repository
......................................................................
Patch Set 1: Verified+1
(1 comment)
Patchset:
PS1:
Overriding Jenkins as this one can't pass without the next commit and vice versa.
--
To view, visit https://review.coreboot.org/c/flashrom/+/67860
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: 1.2.x
Gerrit-Change-Id: I37a8e925d1b283c3b8f87cb3d0f1ed8920f2cf95
Gerrit-Change-Number: 67860
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Patrick Georgi <patrick(a)coreboot.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Patrick Georgi <patrick(a)coreboot.org>
Gerrit-Attention: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Comment-Date: Mon, 26 Sep 2022 17:14:43 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment