David Hendricks has posted comments on this change. ( https://review.coreboot.org/23025 )
Change subject: Modify test_v2.sh to work with upstream
......................................................................
Patch Set 5:
(5 comments)
https://review.coreboot.org/#/c/23025/4/tests/tests_v2/test_v2.sh
File tests/tests_v2/test_v2.sh:
https://review.coreboot.org/#/c/23025/4/tests/tests_v2/test_v2.sh@461
PS4, Line 461: exit $EXIT_FAILURE
: fi
:
: #
: # Setup.
: #
:
: # Naive path check
: if
Changed to a naive path check.
https://review.coreboot.org/#/c/23025/4/tests/tests_v2/test_v2.sh@484
PS4, Line 484: exit $EXIT_FAILURE
: fi
:
: # print $1 and store it in the script log file
: print_and_log()
: {
: printf "$1" | tee -a "${LOCAL_TMPDIR}/${LOGS}/${SCRIPT_LOGFILE}"
: }
:
: # Copy files from local tmpdir to remote host tmpdir
: copy_to_remote()
: {
: for F in $@; do
Removed. Logging has been supported for some time now.
https://review.coreboot.org/#/c/23025/4/tests/tests_v2/test_v2.sh@740
PS4, Line 740:
Not relevant to upstream (at least not yet).
https://review.coreboot.org/#/c/23025/4/tests/tests_v2/test_v2.sh@783
PS4, Line 783: elif [ $REGION_MODE -eq $R
--noverify-all is committed upstream
https://review.coreboot.org/#/c/23025/4/tests/tests_v2/test_v2.sh@791
PS4, Line 791: fi
:
: if [ $SMALL_REGION -eq 1 ]; then
: PA
Not relevant to upstream.
--
To view, visit https://review.coreboot.org/23025
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I9ace99fdb8d779804fe1887fe49f6409f8aff02e
Gerrit-Change-Number: 23025
Gerrit-PatchSet: 5
Gerrit-Owner: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Mon, 22 Jan 2018 00:49:12 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
Hello Paul Menzel, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/23025
to look at the new patch set (#5).
Change subject: Modify test_v2.sh to work with upstream
......................................................................
Modify test_v2.sh to work with upstream
This updates a few minor things so that the test script works with upstream
flashrom:
- Do not depend on git/repo to check if we're in the flashrom directory.
- Assume logging is supported in both flashrom binaries.
- Use upstream's "--chip-size" command and filter superfluous output.
- Clean-up places where "--ignore-fmap" is used.
- Use "--noverify-all" instead of "--fast-verify".
Change-Id: I9ace99fdb8d779804fe1887fe49f6409f8aff02e
Signed-off-by: David Hendricks <dhendricks(a)fb.com>
---
M tests/tests_v2/test_v2.sh
1 file changed, 16 insertions(+), 26 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/25/23025/5
--
To view, visit https://review.coreboot.org/23025
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I9ace99fdb8d779804fe1887fe49f6409f8aff02e
Gerrit-Change-Number: 23025
Gerrit-PatchSet: 5
Gerrit-Owner: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Hello Paul Menzel, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/23024
to look at the new patch set (#5).
Change subject: test_v2.sh: Minor fixups
......................................................................
test_v2.sh: Minor fixups
- Copy layout to local tempdir in local-layout mode. The layout file
wasn't being copied to the local tempdir when using layout as the
region mode and doing the test entirely locally.
- Err out if backup image fails to write.
BUG=none
BRANCH=none
TEST=ran test in layout mode locally
Change-Id: Ia2328d367ee3df5ac1c481c16e4502a81d69fd98
Signed-off-by: David Hendricks <dhendrix(a)chromium.org>
---
M tests/tests_v2/test_v2.sh
1 file changed, 5 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/24/23024/5
--
To view, visit https://review.coreboot.org/23024
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ia2328d367ee3df5ac1c481c16e4502a81d69fd98
Gerrit-Change-Number: 23024
Gerrit-PatchSet: 5
Gerrit-Owner: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Hello Carl-Daniel Hailfinger, Arthur Heymans, Nicola Corna, Paul Menzel, build bot (Jenkins), Nico Huber,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/23021
to look at the new patch set (#12).
Change subject: layout: Add -i <region>[:<file>] support.
......................................................................
layout: Add -i <region>[:<file>] support.
Add an optional sub-parameter to the -i parameter to allow building the
image to be written from multiple files. This will also allow regions to
be read from flash and written to separate image files.
This is a rebase of a patch that was ported from chromiumos. A lot of
things have changed, but the idea is the same.
Original patch by Louis Yung-Chieh Lo <yjlou(a)chromium.org>:
Summary: Support -i partition:file feature for both read and write.
Commit: 9c7525f
Review URL: http://codereview.chromium.org/6611015
Ported version by Stefan Tauner <stefan.tauner(a)student.tuwien.ac.at>
and Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006(a)gmx.net>:
Summary: [PATCH 2/6] layout: Add -i <region>[:<file>] support.
Review URL: https://mail.coreboot.org/pipermail/flashrom/2013-October/011729.html
Change-Id: Ic5465659605d8431d931053967b40290195cfd99
Signed-off-by: David Hendricks <dhendrix(a)chromium.org>
Signed-off-by: Stefan Tauner <stefan.tauner(a)student.tuwien.ac.at>
Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006(a)gmx.net>
Signed-off-by: Arthur Heymans <arthur(a)aheymans.xyz>
---
M cli_classic.c
M dummyflasher.c
M flash.h
M flashrom.8.tmpl
M flashrom.c
M layout.c
M layout.h
7 files changed, 292 insertions(+), 41 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/21/23021/12
--
To view, visit https://review.coreboot.org/23021
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic5465659605d8431d931053967b40290195cfd99
Gerrit-Change-Number: 23021
Gerrit-PatchSet: 12
Gerrit-Owner: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006(a)gmx.net>
Gerrit-Reviewer: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Nicola Corna <nicola(a)corna.info>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Hello Arthur Heymans, Louis Yung-Chieh Lo, Paul Menzel, build bot (Jenkins), Nico Huber,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/23022
to look at the new patch set (#12).
Change subject: make args for -r/-w/-v non-positional and optional
......................................................................
make args for -r/-w/-v non-positional and optional
Ported from chromiumos:
https://chromium-review.googlesource.com/#/c/60515/
This makes a filename following -r, -w, and -v operations non-
positional. The first argument that does not begin with a hyphen (-)
is the filename for -r/-w/-v. If no such argument exists, then
-r/-w/-v options apply to files specified for individually included
regions via -i.
This has a few side-effects:
1. It allows us to omit the ROM-sized filename entirely when a
filename is provided for a particular region when using -i. For
example, "flashrom -i FOO:foo.bin -r".
2. It allows, for better or worse, the filename be specified anywhere
on the command line after the program name. Our scripts and docs
should still specify the file after -r/-w/-v for clarity.
For our purposes, if a filename is given for every included region
(-i region:filename) then the user does not need to specify a filename
after -r/-w/-v. However, if any -i option does not specify a filename,
then a file must be specified after -r/-w/-v.
The syntax will be backwards compatible for now so that one can still
mix -i options with and without the added filename specifier for each
region.
BUG=chromium:263495
BRANCH=none
TEST=manual (see notes below)
1. Write random data to RW_UNUSED region (on snow in this case)
without requiring an argument to -w. See that only RW_UNUSED
is erased and written, and that verify works:
dd if=/dev/urandom of=rw_unused.bin bs=1k count=1 conv=notrunc
flashrom -p host -i RW_UNUSED:rw_unused.bin -w -V
flashrom -p host -i RW_UNUSED:rw_unused.bin -v -V
2. Same as above, but specify a dummy file to test syntax
backwards compatibility:
dd if=/dev/urandom of=rw_unused.bin bs=1k count=1 conv=notrunc
dd if=/dev/urandom of=random_4M.bin bs=1M count=4
flashrom -p host -i RW_UNUSED:rw_unused.bin -w random_4M.bin -V
flashrom -p host -i RW_UNUSED:rw_unused.bin -v random_4M.bin -V
3. Test that dumping RW_UNUSED and GBB regions without -r arg dumps
two files and that they can be used to verify the content:
flashrom -p host -i RW_UNUSED:rw_unused.bin -i GBB:gbb.bin -r
flashrom -p host -i RW_UNUSED:rw_unused.bin -i GBB:gbb.bin -v
4. Same as above, but with dummy file:
flashrom -p host -i RW_UNUSED:rw_unused.bin -i GBB:gbb.bin -r x.bin
flashrom -p host -i RW_UNUSED:rw_unused.bin -i GBB:gbb.bin -v x.bin
Change-Id: Iefbcb7dc4fefe26f5afd1292dfd5c1687fa62803
Reviewed-on: https://gerrit.chromium.org/gerrit/60515
Reviewed-by: Yung-Chieh Lo <yjlou(a)chromium.org>
Commit-Queue: David Hendricks <dhendrix(a)chromium.org>
Tested-by: David Hendricks <dhendrix(a)chromium.org>
Signed-off-by: Arthur Heymans <arthur(a)aheymans.xyz>
---
M cli_classic.c
M flashrom.8.tmpl
2 files changed, 108 insertions(+), 23 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/22/23022/12
--
To view, visit https://review.coreboot.org/23022
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Iefbcb7dc4fefe26f5afd1292dfd5c1687fa62803
Gerrit-Change-Number: 23022
Gerrit-PatchSet: 12
Gerrit-Owner: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Louis Yung-Chieh Lo <yjlou(a)chromium.org>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Shawn Anastasio has posted comments on this change. ( https://review.coreboot.org/23057 )
Change subject: buspirate_spi: Add support for variable serial speeds
......................................................................
Patch Set 6:
(3 comments)
https://review.coreboot.org/#/c/23057/6/buspirate_spi.c
File buspirate_spi.c:
https://review.coreboot.org/#/c/23057/6/buspirate_spi.c@443
PS6, Line 443: 5.5
> Where is this written? This page talks about 5.2: […]
Firmware versions 5.2-5.4 do support setting custom baud rates, but without the improved SPI mode in 5.5 you run into a lot of buffer overruns which slow down the read/write and defeat the purpose of increasing the baud rate.
https://review.coreboot.org/#/c/23057/6/buspirate_spi.c@451
PS6, Line 451: " Continue at your own risk.\n");
> I did some research, v2 can work with the same firmware and uses the […]
This repository which seems to contain the latest firmware states that only boards v3 and v4 are supported: https://github.com/BusPirate/Bus_Pirate.
I could still remove the warning if you'd like, but I think leaving it there until someone with a v2 comes along and tests it isn't a bad idea.
https://review.coreboot.org/#/c/23057/6/buspirate_spi.c@473
PS6, Line 473: sleep(1);
> Is this specified somewhere? It seems incredibly long.
It's really just a safe value. I could try to optimize it to the lowest value that works on my v3 but I'm not sure if it's worth it, especially if it causes breakage on other models.
--
To view, visit https://review.coreboot.org/23057
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I3706f17a94fdf056063f2ad4a5f0a219665cdcbf
Gerrit-Change-Number: 23057
Gerrit-PatchSet: 6
Gerrit-Owner: Shawn Anastasio <shawnanastasio(a)yahoo.com>
Gerrit-Reviewer: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: Shawn Anastasio <shawnanastasio(a)yahoo.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Sun, 21 Jan 2018 22:37:49 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
Nico Huber has uploaded this change for review. ( https://review.coreboot.org/23344
Change subject: [NOTFORMERGE] Do not try to map SPI flash chips
......................................................................
[NOTFORMERGE] Do not try to map SPI flash chips
Trying to map SPI chips seems superfluous and might not work at all.
Though, it would require a very deep investigation to find out if
this is always the case for all programmers. If somebody has the time
for that, it's probably better spent on (re)moving the mapping stuff
altogether.
Change-Id: I57350f65211b4c0ae2a285ee1b1151a6e6bfa031
Signed-off-by: Nico Huber <nico.h(a)gmx.de>
---
M flashrom.c
1 file changed, 8 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/44/23344/1
diff --git a/flashrom.c b/flashrom.c
index ac987fd..a8bef3a 100644
--- a/flashrom.c
+++ b/flashrom.c
@@ -1111,6 +1111,10 @@
void unmap_flash(struct flashctx *flash)
{
+ /* FIXME: The whole (un)mapping should be handled at programmer level. */
+ if ((flash->chip->bustype & BUS_NONSPI) == 0)
+ return;
+
if (flash->virtual_registers != (chipaddr)ERROR_PTR) {
programmer_unmap_flash_region((void *)flash->virtual_registers, flash->chip->total_size * 1024);
flash->physical_registers = 0;
@@ -1126,6 +1130,10 @@
int map_flash(struct flashctx *flash)
{
+ /* FIXME: The whole (un)mapping should be handled at programmer level. */
+ if ((flash->chip->bustype & BUS_NONSPI) == 0)
+ return 0;
+
/* Init pointers to the fail-safe state to distinguish them later from legit values. */
flash->virtual_memory = (chipaddr)ERROR_PTR;
flash->virtual_registers = (chipaddr)ERROR_PTR;
--
To view, visit https://review.coreboot.org/23344
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I57350f65211b4c0ae2a285ee1b1151a6e6bfa031
Gerrit-Change-Number: 23344
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
David Hendricks has posted comments on this change. ( https://review.coreboot.org/23021 )
Change subject: layout: Add -i <region>[:<file>] support.
......................................................................
Patch Set 7:
(3 comments)
https://review.coreboot.org/#/c/23021/5/flashrom.c
File flashrom.c:
https://review.coreboot.org/#/c/23021/5/flashrom.c@1379
PS5, Line 1379:
> I could think of a future use that might be useful if/once fmap support is implemented: if you use a […]
More specifically, to make sure that the include args for write operations don't overlap. For reading it should be fine.
https://review.coreboot.org/#/c/23021/7/flashrom.c
File flashrom.c:
https://review.coreboot.org/#/c/23021/7/flashrom.c@1380
PS7, Line 1380: if (!entry->included || !entry->file)
: continue;
> Optionally: […]
Actually, I don't think we should check for entry->file here. Doing so will require that all included entries have a file specified which is not always desirable.
The higher-level logic should check if an argument to -w was specified to decide what to do here:
- If a file is specified for -w, then we do not need a file specified for each -i arg.
- If a file is not specified for -w, then we need a file specified for each -i arg.
Removing the check here will also obviate the need for my get_num_include_args_with_files() hack in PS11.
https://review.coreboot.org/#/c/23021/11/layout.c
File layout.c:
https://review.coreboot.org/#/c/23021/11/layout.c@174
PS11, Line 174: Use the -l/--layout parameter to specify\n"
: "a layout file.
We should probably clarify this comment or get rid of the latter half since the layout can come from a few different sources (layout file, IFD, and soon FMAP).
--
To view, visit https://review.coreboot.org/23021
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic5465659605d8431d931053967b40290195cfd99
Gerrit-Change-Number: 23021
Gerrit-PatchSet: 7
Gerrit-Owner: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006(a)gmx.net>
Gerrit-Reviewer: David Hendricks <david.hendricks(a)gmail.com>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Nicola Corna <nicola(a)corna.info>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Sun, 21 Jan 2018 09:00:11 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No