Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/54964 )
Change subject: platform: Fix endianness detection for Apple Silicon Macs
......................................................................
Patch Set 3:
(1 comment)
Patchset:
PS3:
> I was able to successfully (and repeatedly) read and write W25X40 SPI flash with CH341A-based progra […]
That tells us that libusb is working and probably a lot of USB programmers with it :)
--
To view, visit https://review.coreboot.org/c/flashrom/+/54964
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ifdb1523ee2c7023e657cfd7b823b091d5deef513
Gerrit-Change-Number: 54964
Gerrit-PatchSet: 3
Gerrit-Owner: Ivan V <root(a)pcm720.me>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
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-Comment-Date: Mon, 07 Jun 2021 13:06:43 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Ivan V <root(a)pcm720.me>
Comment-In-Reply-To: Nico Huber <nico.h(a)gmx.de>
Gerrit-MessageType: comment
Attention is currently required from: Angel Pons.
Hello Nico Huber,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/flashrom/+/55267
to look at the new patch set (#2).
Change subject: treewide: Drop unnecessary uses of memset/memcpy
......................................................................
treewide: Drop unnecessary uses of memset/memcpy
Simply provide an initialiser or use a direct assignment instead.
Change-Id: I07385375cd8eec8a95874001b402b2c17ec09e09
Signed-off-by: Angel Pons <th3fanbus(a)gmail.com>
---
M flashrom.c
M ichspi.c
M jlink_spi.c
M linux_mtd.c
M physmap.c
M raiden_debug_spi.c
M stlinkv3_spi.c
M usbblaster_spi.c
8 files changed, 21 insertions(+), 49 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/67/55267/2
--
To view, visit https://review.coreboot.org/c/flashrom/+/55267
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I07385375cd8eec8a95874001b402b2c17ec09e09
Gerrit-Change-Number: 55267
Gerrit-PatchSet: 2
Gerrit-Owner: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-MessageType: newpatchset
Attention is currently required from: Edward O'Callaghan, Angel Pons, Arthur Heymans, Anastasia Klimchuk.
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/55266 )
Change subject: treewide: Drop most cases of `sizeof(struct ...)`
......................................................................
Patch Set 1: Code-Review+2
(3 comments)
File flashrom.c:
https://review.coreboot.org/c/flashrom/+/55266/comment/108391d1_20fb8811
PS1, Line 1242: memcpy(flash->chip, chip, sizeof(*flash->chip));
NB. could even use an assignment w/o bypassing typechecks?
File ichspi.c:
https://review.coreboot.org/c/flashrom/+/55266/comment/e7bc05da_7a53f336
PS1, Line 1734: memset(&desc, 0x00, sizeof(desc));
Or initialize with `= { 0 }`.
File raiden_debug_spi.c:
https://review.coreboot.org/c/flashrom/+/55266/comment/dfa42b66_01def160
PS1, Line 1594: memcpy(spi_config, &spi_master_raiden_debug, sizeof(*spi_config));
NB. could even use an assignment w/o bypassing typechecks?
--
To view, visit https://review.coreboot.org/c/flashrom/+/55266
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Icc0b60ca6ef9f5ece6ed2a0e03600bb6ccd7dcc6
Gerrit-Change-Number: 55266
Gerrit-PatchSet: 1
Gerrit-Owner: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
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-Attention: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Attention: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Attention: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Attention: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Comment-Date: Mon, 07 Jun 2021 11:26:37 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Edward O'Callaghan, Anastasia Klimchuk.
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/54748 )
Change subject: dummyflasher.c: Fix data leak in params processing error paths
......................................................................
Patch Set 5:
(3 comments)
Commit Message:
https://review.coreboot.org/c/flashrom/+/54748/comment/7eb8ca94_0de7188e
PS4, Line 20:
> I haven't seen this tag before, is it used often? I saw people mention in commit message "follow-up […]
Heh, I actually prefer text over the Fixes: tag ;) The tag is
just what other people use... probably more common in coreboot.
Regarding CB:, it's a layer of indirection. Before a commit
is submitted to master, we can only reference the change,
because the commit hash is not final. Pro: Gerrit links
it conveniently. Con: Native Git tools know nothing about
it and one would have to search for the number manually.
For already merged commits, I prefer to use the commit
hash and summary. IIRC, if it's prefixed with `commit`,
Gerrit also links it. Eventually, this Gerrit instance
may not run anymore, but the Git history prevails.
NB. I'm not a fan of forward references, jumping back and
forth can make the review harder. There are exceptions ofc.
File dummyflasher.c:
https://review.coreboot.org/c/flashrom/+/54748/comment/150dc8e6_022d2882
PS1, Line 26: /* Remove the #define below if you don't want SPI flash chip emulation. */
: #define EMULATE_SPI_CHIP 1
> Just to confirm, you mean, let's assume (EMULATE_CHIP && EMULATE_SPI_CHIP) always true and drop the code outside the #if? So that dummy will always be dummy_spi? But then maybe have another one dummy_par? Maybe someone needs those different values.
`dummy` is already both `dummy_spi` and `dummy_par` at once. Both masters
are registered if the commandline says they should be supported. EMULATE*_
CHIP is only about emulating a flash chip connected to the bus. I don't
see why we couldn't have one chip on each bus at once.
Not sure what you mean with "drop the code outside the #if". All the
code is compiled in currently. There is no #else that would be dropped.
>
> I don't know what was the initial meaning of !EMULATE_CHIP use case. What dummy is doing if it is not emulating any chip? I see it can emulate spi or par, I can understand, but not emulating anything?
It's emulating buses, that's already enough to test flash probing for
instance. But the behavior should be the same as with `EMULATE_CHIP
== 1` and no chip given on the commandline, I guess. So I really don't
see a reason for the #if mess.
File dummyflasher.c:
https://review.coreboot.org/c/flashrom/+/54748/comment/c18345a1_f5a4b487
PS4, Line 994: dummy_buses_supported
> I was thinking about it, and my guess was, because it is only needed for init time, and not needed l […]
It is not only used for init. But there lies the answer: it's used get the
data pointer in get_data_from_context(); so it can't be part of it. However,
it seems unnecessary, `flash->mst` also has a `buses_supported` field?
Very odd.
--
To view, visit https://review.coreboot.org/c/flashrom/+/54748
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I04f55f77bb4703f1d88b2191c45a22be3c97bf87
Gerrit-Change-Number: 54748
Gerrit-PatchSet: 5
Gerrit-Owner: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Namyoon Woo <namyoon(a)google.com>
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-Attention: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Attention: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Comment-Date: Mon, 07 Jun 2021 11:06:54 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Nico Huber <nico.h(a)gmx.de>
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-MessageType: comment