Attention is currently required from: Nico Huber, Thomas Heijligen, Angel Pons, Steve Markgraf.

Nico Huber uploaded patch set #7 to the change originally created by Steve Markgraf.

View Change

programmer: Add bitbanging programmer driver for Linux libgpiod

With this driver, any single board computer, old smartphone, etc. with
a few spare GPIOs can be used for flashrom.

Tested by reading of a 2048 kB flash chip on a Qualcomm MSM8916 SoC
@800 MHz, ran the following command:

time flashrom -p linux_gpiod:gpiochip=0,cs=18,sck=19,mosi=13,miso=56 -r test.bin

This command uses /dev/gpiochip0 with the specified GPIO numbers for the
SPI lines. All arguments are mandatory.

Output:
[...]
Found GigaDevice flash chip "GD25LQ16" (2048 kB, SPI) on linux_gpiod.
[...]
real 1m 33.96s

Retested after renaming and small changes by reading a SST25VF020B
attached to the GPIO lines of a Raspberry Pi B:

time ./flashrom -p linux_gpio_spi:dev=/dev/gpiochip0,cs=2,sck=17,mosi=4,miso=3 -r /tmp/dump

Output:
[...]
Found SST flash chip "SST25VF020B" (256 kB, SPI) on linux_gpio_spi.
[...]
real 0m42.416s

Change-Id: Icad3eb7764f28feaea51bda3a7893da724c86d06
Signed-off-by: Steve Markgraf <steve@steve-m.de>
Signed-off-by: Nico Huber <nico.h@gmx.de>
---
M MAINTAINERS
M Makefile
M README
M doc/classic_cli_manpage.rst
M doc/dev_guide/building_from_source.rst
M include/programmer.h
A linux_gpio_spi.c
M meson.build
M meson_options.txt
M programmer_table.c
M test_build.sh
M util/manibuilder/Dockerfile.alpine
M util/manibuilder/Dockerfile.debian-debootstrap
M util/manibuilder/Dockerfile.fedora
M util/manibuilder/Dockerfile.ubuntu-debootstrap
M util/shell.nix
16 files changed, 324 insertions(+), 17 deletions(-)

git pull ssh://review.coreboot.org:29418/flashrom refs/changes/01/71801/7

To view, visit change 71801. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Icad3eb7764f28feaea51bda3a7893da724c86d06
Gerrit-Change-Number: 71801
Gerrit-PatchSet: 7
Gerrit-Owner: Steve Markgraf <steve@steve-m.de>
Gerrit-Reviewer: Anastasia Klimchuk <aklm@chromium.org>
Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com>
Gerrit-Reviewer: Nico Huber <nico.h@gmx.de>
Gerrit-Reviewer: Thomas Heijligen <src@posteo.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-Attention: Nico Huber <nico.h@gmx.de>
Gerrit-Attention: Thomas Heijligen <src@posteo.de>
Gerrit-Attention: Angel Pons <th3fanbus@gmail.com>
Gerrit-Attention: Steve Markgraf <steve@steve-m.de>
Gerrit-MessageType: newpatchset