Attention is currently required from: Antonio Vázquez Blanco.
Anastasia Klimchuk has posted comments on this change by Antonio Vázquez Blanco. ( https://review.coreboot.org/c/flashrom/+/85134?usp=email )
Change subject: Extract cli_output declarations to a separate header.
......................................................................
Patch Set 2: Code-Review+2
(1 comment)
Patchset:
PS2:
I leave this unresolved comment as a note this patch will be submitted after v1.5.0 tag is done.
ETA 6th December.
Perhaps you already know, but just in case, we are now preparing a release and only merging bugfixes.
See the thread for details:
https://mail.coreboot.org/hyperkitty/list/flashrom@flashrom.org/thread/WM4C…
So this is a special time now. At normal time, merging would be in 3 days, process documented here: https://flashrom.org/dev_guide/development_guide.html#merging-patches
--
To view, visit https://review.coreboot.org/c/flashrom/+/85134?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I4209d5ed205ca14c39e83aa923e103b7282a7059
Gerrit-Change-Number: 85134
Gerrit-PatchSet: 2
Gerrit-Owner: Antonio Vázquez Blanco <antoniovazquezblanco(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Antonio Vázquez Blanco <antoniovazquezblanco(a)gmail.com>
Gerrit-Comment-Date: Tue, 26 Nov 2024 02:34:09 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Attention is currently required from: Matt DeVillier.
Anastasia Klimchuk has posted comments on this change by Matt DeVillier. ( https://review.coreboot.org/c/flashrom/+/85159?usp=email )
Change subject: cli_classic.c: Make -r/-w/-v argument optional when using -i
......................................................................
Patch Set 8: Code-Review+2
(1 comment)
Patchset:
PS8:
I leave this unresolved comment as a note this patch will be submitted after v1.5.0 tag is done.
ETA 6th December.
Perhaps you already know, but just in case, we are now preparing a release and only merging bugfixes.
See the thread for details:
https://mail.coreboot.org/hyperkitty/list/flashrom@flashrom.org/thread/WM4C…
So this is a special time now. At normal time, merging would be in 3 days, process documented here: https://flashrom.org/dev_guide/development_guide.html#merging-patches
--
To view, visit https://review.coreboot.org/c/flashrom/+/85159?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I6eba095d478f1a7bdbc3854627a656f93dd9e452
Gerrit-Change-Number: 85159
Gerrit-PatchSet: 8
Gerrit-Owner: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Comment-Date: Tue, 26 Nov 2024 02:29:27 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Anastasia Klimchuk has posted comments on this change by Anastasia Klimchuk. ( https://review.coreboot.org/c/flashrom/+/85292?usp=email )
Change subject: libflashrom: Fix comparison of layout romentry regions
......................................................................
Patch Set 1:
(1 comment)
File libflashrom.c:
https://review.coreboot.org/c/flashrom/+/85292/comment/c1a1ccc7_5db26e7f?us… :
PS1, Line 309: static int compare_region_with_dump(const struct romentry *const a, const struct romentry *const b)
> It should always be zeroed, but that's true because `flashrom_layout_new` uses `calloc` and that doe […]
Alright, then I leave it as is. Thank you.
--
To view, visit https://review.coreboot.org/c/flashrom/+/85292?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I715969036c8e516aac8d90b46830f1f92ae6a160
Gerrit-Change-Number: 85292
Gerrit-PatchSet: 1
Gerrit-Owner: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Peter Marheine <pmarheine(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Tue, 26 Nov 2024 01:48:52 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Comment-In-Reply-To: Peter Marheine <pmarheine(a)chromium.org>
Attention is currently required from: Anastasia Klimchuk.
Peter Marheine has posted comments on this change by Anastasia Klimchuk. ( https://review.coreboot.org/c/flashrom/+/85292?usp=email )
Change subject: libflashrom: Fix comparison of layout romentry regions
......................................................................
Patch Set 1: Code-Review+2
(1 comment)
File libflashrom.c:
https://review.coreboot.org/c/flashrom/+/85292/comment/ec85ff10_0d9cbde8?us… :
PS1, Line 309: static int compare_region_with_dump(const struct romentry *const a, const struct romentry *const b)
> I am wondering whether `read_prot` and `write_prot` should be here. […]
It should always be zeroed, but that's true because `flashrom_layout_new` uses `calloc` and that doesn't seem like a guarantee the API actually makes- it would be easy to change things to not always zero a layout on creation and introduce a bug if this were to be reading fields that aren't meaningful, so I'm leaning toward not checking those fields.
--
To view, visit https://review.coreboot.org/c/flashrom/+/85292?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I715969036c8e516aac8d90b46830f1f92ae6a160
Gerrit-Change-Number: 85292
Gerrit-PatchSet: 1
Gerrit-Owner: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Peter Marheine <pmarheine(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Comment-Date: Mon, 25 Nov 2024 22:48:05 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Attention is currently required from: Anastasia Klimchuk.
Matt DeVillier has posted comments on this change by Matt DeVillier. ( https://review.coreboot.org/c/flashrom/+/85159?usp=email )
Change subject: cli_classic.c: Make -r/-w/-v argument optional when using -i
......................................................................
Patch Set 8:
(1 comment)
File doc/classic_cli_manpage.rst:
https://review.coreboot.org/c/flashrom/+/85159/comment/a30238cf_43736a37?us… :
PS5, Line 227: If filenames are specified for -r and -i args, then:
> That is only repro when generating manpage from rst, html is fine (I couldn't find in the tool the o […]
Done
--
To view, visit https://review.coreboot.org/c/flashrom/+/85159?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I6eba095d478f1a7bdbc3854627a656f93dd9e452
Gerrit-Change-Number: 85159
Gerrit-PatchSet: 8
Gerrit-Owner: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Comment-Date: Mon, 25 Nov 2024 14:23:47 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Matt DeVillier <matt.devillier(a)gmail.com>
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Attention is currently required from: Peter Marheine.
Anastasia Klimchuk has posted comments on this change by Anastasia Klimchuk. ( https://review.coreboot.org/c/flashrom/+/85292?usp=email )
Change subject: libflashrom: Fix comparison of layout romentry regions
......................................................................
Patch Set 1:
(1 comment)
File libflashrom.c:
https://review.coreboot.org/c/flashrom/+/85292/comment/6f73d737_d7317e88?us… :
PS1, Line 309: static int compare_region_with_dump(const struct romentry *const a, const struct romentry *const b)
I am wondering whether `read_prot` and `write_prot` should be here.
There are not filled in from dump, but that means they will have default values, and always the same? (so, won't make an effect on comparison).
--
To view, visit https://review.coreboot.org/c/flashrom/+/85292?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I715969036c8e516aac8d90b46830f1f92ae6a160
Gerrit-Change-Number: 85292
Gerrit-PatchSet: 1
Gerrit-Owner: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Peter Marheine <pmarheine(a)chromium.org>
Gerrit-Attention: Peter Marheine <pmarheine(a)chromium.org>
Gerrit-Comment-Date: Mon, 25 Nov 2024 10:33:26 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Anastasia Klimchuk has uploaded this change for review. ( https://review.coreboot.org/c/flashrom/+/85292?usp=email )
Change subject: libflashrom: Fix comparison of layout romentry regions
......................................................................
libflashrom: Fix comparison of layout romentry regions
Comparing structs (romentries in this case) with memcmp
won't work if the struct includes pointers.
Also in this case romentry region is compared to the one loaded
from dump, and from dump only start, end and name are filled in.
https://ticket.coreboot.org/issues/570
Prior effort: https://review.coreboot.org/c/flashrom/+/72433
Change-Id: I715969036c8e516aac8d90b46830f1f92ae6a160
Signed-off-by: Anastasia Klimchuk <aklm(a)flashrom.org>
---
M libflashrom.c
1 file changed, 10 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/92/85292/1
diff --git a/libflashrom.c b/libflashrom.c
index dfc86e6..78e5c9b 100644
--- a/libflashrom.c
+++ b/libflashrom.c
@@ -306,6 +306,15 @@
}
}
+static int compare_region_with_dump(const struct romentry *const a, const struct romentry *const b)
+{
+ if (a->region.start != b->region.end
+ || a->region.end != b->region.end
+ || strcmp(a->region.name, b->region.name))
+ return 1;
+ return 0;
+}
+
int flashrom_layout_read_from_ifd(struct flashrom_layout **const layout, struct flashctx *const flashctx,
const void *const dump, const size_t len)
{
@@ -343,7 +352,7 @@
const struct romentry *chip_entry = layout_next(chip_layout, NULL);
const struct romentry *dump_entry = layout_next(dump_layout, NULL);
- while (chip_entry && dump_entry && !memcmp(chip_entry, dump_entry, sizeof(*chip_entry))) {
+ while (chip_entry && dump_entry && !compare_region_with_dump(chip_entry, dump_entry)) {
chip_entry = layout_next(chip_layout, chip_entry);
dump_entry = layout_next(dump_layout, dump_entry);
}
--
To view, visit https://review.coreboot.org/c/flashrom/+/85292?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I715969036c8e516aac8d90b46830f1f92ae6a160
Gerrit-Change-Number: 85292
Gerrit-PatchSet: 1
Gerrit-Owner: Anastasia Klimchuk <aklm(a)chromium.org>
Antonio Vázquez Blanco has posted comments on this change by Antonio Vázquez Blanco. ( https://review.coreboot.org/c/flashrom/+/85073?usp=email )
Change subject: Use SPDX in cli_getop files
......................................................................
Patch Set 2:
(1 comment)
Patchset:
PS2:
Knowing that in general you want to keep a single header style among all prohect files, should I drop this in favour of you possibly changing all headers in all files at once? Thanks!
--
To view, visit https://review.coreboot.org/c/flashrom/+/85073?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: Ie523cf5b26a29de8e9e9efb56efe04a5ff86a59c
Gerrit-Change-Number: 85073
Gerrit-PatchSet: 2
Gerrit-Owner: Antonio Vázquez Blanco <antoniovazquezblanco(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Mon, 25 Nov 2024 08:48:41 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No