Attention is currently required from: Anastasia Klimchuk.
Hsuan-ting Chen has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/79229?usp=email )
Change subject: erase_func_algo: Avoid putting 0xff into buffers
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> In theory, there could be more than one way to erase. […]
Thanks for the detailed explaination!
Yes, I found this behaviour inconsistant while porting this to chromium flashrom. I would be grateful if there's any related performance materials that could share with me.
I'll abandon this change.
--
To view, visit https://review.coreboot.org/c/flashrom/+/79229?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: Ibe159f9f7cf35688cfdbe18245fea2d870386412
Gerrit-Change-Number: 79229
Gerrit-PatchSet: 1
Gerrit-Owner: Hsuan-ting Chen <roccochen(a)google.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: Thu, 23 Nov 2023 10:57:54 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Hsuan-ting Chen <roccochen(a)google.com>
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-MessageType: comment
Attention is currently required from: Hsuan-ting Chen.
Anastasia Klimchuk has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/79229?usp=email )
Change subject: erase_func_algo: Avoid putting 0xff into buffers
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> Hi Anastasia: […]
In theory, there could be more than one way to erase. In practice, the test is relying on the current implementation of erase/write which does it in one exact way.
If you are trying to adapt the test to chromium flashrom: last time I looked it had a different algorithm for erase/write. So don't be surprised if you see different erasers invocations for some of test cases. There was a plan for this year to merge two algos and get the best of both worlds. I measured the performance a year ago, and depending on the test case, one or other performed better. The plans did not happen, and now I guess it's up to you if you want to do that.
--
To view, visit https://review.coreboot.org/c/flashrom/+/79229?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: Ibe159f9f7cf35688cfdbe18245fea2d870386412
Gerrit-Change-Number: 79229
Gerrit-PatchSet: 1
Gerrit-Owner: Hsuan-ting Chen <roccochen(a)google.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Hsuan-ting Chen <roccochen(a)google.com>
Gerrit-Comment-Date: Thu, 23 Nov 2023 10:44:26 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Hsuan-ting Chen <roccochen(a)google.com>
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-MessageType: comment
Attention is currently required from: Anastasia Klimchuk.
Hsuan-ting Chen has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/79229?usp=email )
Change subject: erase_func_algo: Avoid putting 0xff into buffers
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> Hsuan-ting, I appreciate your effort to create a patch, but I don't understand what is the issue you […]
Hi Anastasia:
Here's my previous note:
https://review.coreboot.org/c/flashrom/+/67535/comment/5f7ed5b9_3f1e6037/
Thanks for the prompt reply. Yes, I think I am not really clear about this test.
I am not very clear about the "golden example" should be. For example,
```
.initial_buf = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff},
.written_buf = {0x0, 0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8,
0x9, 0xa, 0xb, 0xc, 0xd, 0xe, 0xf},
```
Should we erase all or should we aware that the initial buf is already 0xFFs so skip erasure?
Please let me know if there's anything I need to study or misunderstood.
--
To view, visit https://review.coreboot.org/c/flashrom/+/79229?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: Ibe159f9f7cf35688cfdbe18245fea2d870386412
Gerrit-Change-Number: 79229
Gerrit-PatchSet: 1
Gerrit-Owner: Hsuan-ting Chen <roccochen(a)google.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: Thu, 23 Nov 2023 10:07:07 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-MessageType: comment
Attention is currently required from: Alexander Goncharov, Fabrice Fontaine, Thomas Heijligen.
Hello Anastasia Klimchuk, Thomas Heijligen, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/flashrom/+/78930?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Verified+1 by build bot (Jenkins)
Change subject: Makefile: CONFIG_INTERNAL depends on raw mem access
......................................................................
Makefile: CONFIG_INTERNAL depends on raw mem access
CONFIG_INTERNAL depends on raw mem access resulting in the following
build failure on sh4 since version 1.3.0:
/home/thomas/autobuild/instance-3/output-1/per-package/flashrom/host/bin/../lib/gcc/sh4a-buildroot-linux-gnu/12.3.0/../../../../sh4a-buildroot-linux-gnu/bin/ld: libflashrom.a(internal.o): in function `internal_chip_readn':
internal.c:(.text+0x8): undefined reference to `mmio_readn'
Fixes the build raised by buildroot autobuilders with the following
options:
- CONFIG_FT2232_SPI=no
- CONFIG_USBBLASTER_SPI=no
- CONFIG_ENABLE_LIBUSB1_PROGRAMMERS=yes
- CONFIG_ENABLE_LIBPCI_PROGRAMMERS=yes
Here is the target information:
C compiler found: sh4a-buildroot-linux-gnu-gcc.br_real (Buildroot 2022.08-rc1-5515-gf1a47904b63) 12.3.0
Target arch: sh
Target OS: Linux
Target endian: little
Full build log:
- http://autobuild.buildroot.org/results/f74a9d315fb519f284428234713f43fcf4e3…
Change-Id: I7610f5f7cc5b114ffa90d5752155acc8b6b7c9f7
Signed-off-by: Fabrice Fontaine <fontaine.fabrice(a)gmail.com>
---
M Makefile
1 file changed, 1 insertion(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/30/78930/2
--
To view, visit https://review.coreboot.org/c/flashrom/+/78930?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I7610f5f7cc5b114ffa90d5752155acc8b6b7c9f7
Gerrit-Change-Number: 78930
Gerrit-PatchSet: 2
Gerrit-Owner: Fabrice Fontaine <fontaine.fabrice(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Alexander Goncharov <chat(a)joursoir.net>
Gerrit-Attention: Thomas Heijligen <src(a)posteo.de>
Gerrit-Attention: Fabrice Fontaine <fontaine.fabrice(a)gmail.com>
Gerrit-Attention: Alexander Goncharov <chat(a)joursoir.net>
Gerrit-MessageType: newpatchset
Attention is currently required from: Hsuan-ting Chen.
Anastasia Klimchuk has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/79229?usp=email )
Change subject: erase_func_algo: Avoid putting 0xff into buffers
......................................................................
Patch Set 1: Code-Review-1
(1 comment)
Patchset:
PS1:
Hsuan-ting, I appreciate your effort to create a patch, but I don't understand what is the issue you are trying to fix?
The test aims to run as close as possible to a real life scenario, and of course in real life there could be 0xff bytes in the chip memory. That's valid and should be tested and handled correctly by erase/write logic.
What do you mean by "ambiguous behavior"? The algorithm is deterministic, for a given state of memory on the chip and given image to write there is only one solution.
Maybe you can try explain the exact issue you are trying to fix, and I will try to help you?
--
To view, visit https://review.coreboot.org/c/flashrom/+/79229?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: Ibe159f9f7cf35688cfdbe18245fea2d870386412
Gerrit-Change-Number: 79229
Gerrit-PatchSet: 1
Gerrit-Owner: Hsuan-ting Chen <roccochen(a)google.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Hsuan-ting Chen <roccochen(a)google.com>
Gerrit-Comment-Date: Thu, 23 Nov 2023 10:01:24 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Alexander Goncharov, Fabrice Fontaine, Thomas Heijligen.
Anastasia Klimchuk has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/78930?usp=email )
Change subject: Makefile: CONFIG_INTERNAL depends on raw mem access
......................................................................
Patch Set 1:
(2 comments)
Commit Message:
https://review.coreboot.org/c/flashrom/+/78930/comment/b9f4704d_d3048704 :
PS1, Line 17:
If you could add here in commit message testing info (which environment with which exactly options you tested with) that would be great, thank you!
Patchset:
PS1:
> Thanks for the patch! […]
I opened the link from commit message, flashrom is build with the following:
> CONFIG_FT2232_SPI=no CONFIG_USBBLASTER_SPI=no CONFIG_ENABLE_LIBUSB1_PROGRAMMERS=yes CONFIG_ENABLE_LIBPCI_PROGRAMMERS=yes
which is without internal programmer.
I have another question that I am wondering about, it there anything to change in meson.build. I just looked through it, seems all good?
--
To view, visit https://review.coreboot.org/c/flashrom/+/78930?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I7610f5f7cc5b114ffa90d5752155acc8b6b7c9f7
Gerrit-Change-Number: 78930
Gerrit-PatchSet: 1
Gerrit-Owner: Fabrice Fontaine <fontaine.fabrice(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Alexander Goncharov <chat(a)joursoir.net>
Gerrit-Attention: Thomas Heijligen <src(a)posteo.de>
Gerrit-Attention: Fabrice Fontaine <fontaine.fabrice(a)gmail.com>
Gerrit-Attention: Alexander Goncharov <chat(a)joursoir.net>
Gerrit-Comment-Date: Thu, 23 Nov 2023 09:47:59 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Alexander Goncharov <chat(a)joursoir.net>
Gerrit-MessageType: comment
Attention is currently required from: Stanislav Ponomarev.
Hello Anastasia Klimchuk, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/flashrom/+/79112?usp=email
to look at the new patch set (#3).
Change subject: serial: Fix sp_flush_incoming for serprog TCP connections
......................................................................
serial: Fix sp_flush_incoming for serprog TCP connections
During the development of an esp32 serprog-compatible SPI programmer,
and implementation of the TCP over Wi-Fi for serprog,
I discovered that sp_flush_incoming() silently fails
if the underlying sp_fd descriptor is a TCP socket.
This patch adds a check for this case - tcflush returns ENOTTY,
meaning tcflush is not supported for not terminal objects,
in this case a fallback serialport_read_nonblock loop is used.
TESTED=esp32-serprog, TCP-over-WiFi mode, ~90% connection attempts fail to synchronize without patch; no synchronization issues with patch applied.
Signed-off-by: Stanislav Ponomarev <me(a)stasponomarev.com>
Change-Id: I9724a2fcd4a41dede2c15f83877efa6c3b0b7fae
---
M serial.c
1 file changed, 20 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/12/79112/3
--
To view, visit https://review.coreboot.org/c/flashrom/+/79112?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I9724a2fcd4a41dede2c15f83877efa6c3b0b7fae
Gerrit-Change-Number: 79112
Gerrit-PatchSet: 3
Gerrit-Owner: Stanislav Ponomarev <me(a)stasponomarev.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Stanislav Ponomarev <me(a)stasponomarev.com>
Gerrit-MessageType: newpatchset
Attention is currently required from: Anastasia Klimchuk.
Hsuan-ting Chen has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/79229?usp=email )
Change subject: erase_func_algo: Avoid putting 0xff into buffers
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
The build failure is:
```
make: *** [Makefile:1025: man8/flashrom.8] Error 1
make: *** Waiting for unfinished jobs....
Build step 'Execute shell' marked build as failure
```
it is for man, which seems not really related?
--
To view, visit https://review.coreboot.org/c/flashrom/+/79229?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: Ibe159f9f7cf35688cfdbe18245fea2d870386412
Gerrit-Change-Number: 79229
Gerrit-PatchSet: 1
Gerrit-Owner: Hsuan-ting Chen <roccochen(a)google.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: Thu, 23 Nov 2023 09:07:20 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Attention is currently required from: Anastasia Klimchuk.
Hsuan-ting Chen has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/67535?usp=email )
Change subject: tests: Unit tests for erase function selection algo
......................................................................
Patch Set 22:
(1 comment)
File tests/erase_func_algo.c:
https://review.coreboot.org/c/flashrom/+/67535/comment/5f7ed5b9_3f1e6037 :
PS22, Line 270: 0xff
Hi Anastasia:
I'd like to ask if this test should avoid putting 0xff into either initial_buf or written_buf:
If there are some addresses that are already 0xff, will there be multiple choice of erasure?
For example,
```
.initial_buf = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff},
.written_buf = {0x0, 0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8,
0x9, 0xa, 0xb, 0xc, 0xd, 0xe, 0xf},
```
It should be both valid that
(1) Erase all, then write
(2) Notice that the initial_buf are all 0xff, then skipped
IIUC, both cases are valid and it is not able to decide which should be the "golden example".
I am not really familiar about erasing algorithm, please let me know if I misunderstood anything.
---
I tried to create one: https://review.coreboot.org/c/flashrom/+/79229
--
To view, visit https://review.coreboot.org/c/flashrom/+/67535?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: main
Gerrit-Change-Id: I8f3fdefb76e71f6f8dc295d9dead5f38642aace7
Gerrit-Change-Number: 67535
Gerrit-PatchSet: 22
Gerrit-Owner: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Aarya <aarya.chaumal(a)gmail.com>
Gerrit-Reviewer: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Reviewer: Edward O'Callaghan <quasisec(a)chromium.org>
Gerrit-Reviewer: Peter Marheine <pmarheine(a)chromium.org>
Gerrit-Reviewer: Simon Buhrow
Gerrit-Reviewer: Thomas Heijligen <src(a)posteo.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Alexander Goncharov <chat(a)joursoir.net>
Gerrit-CC: Hsuan-ting Chen <roccochen(a)google.com>
Gerrit-CC: Nikolai Artemiev <nartemiev(a)google.com>
Gerrit-CC: Stefan Reinauer <stefan.reinauer(a)coreboot.org>
Gerrit-Attention: Anastasia Klimchuk <aklm(a)chromium.org>
Gerrit-Comment-Date: Thu, 23 Nov 2023 08:46:20 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment