coreboot/src/drivers/spi
Aaron Durbin 3dc99c74ed UPSTREAM: drivers/spi: provide optional implementation of boot_device_rw()
On many x86 platforms the boot device is SPI which is memory
mapped. However, in order to write to the boot device one needs
to use the SPI api. Therefore, provide a common implementation
of boot_device_rw() which has no mmap() functionality. It only
reads, writes, and erases. This will be used in the existing
infrastructure but in a SPI agnostic way.

Two options are added:
1. BOOT_DEVICE_SPI_FLASH_RW_NOMMAP
2. BOOT_DEVICE_SPI_FLASH_RW_NOMMAP_EARLY

The former is auto-selected when COMMON_CBFS_SPI_WRAPPER is not
selected. The latter can be used to include the implementation
in the early stages such as bootblock, verstage, and romstage.

BUG=chrome-os-partner:56151
BRANCH=None
TEST=None

Signed-off-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-on: https://review.coreboot.org/16200
Reviewed-by: Furquan Shaikh <furquan@google.com>
Reviewed-by: Martin Roth <martinroth@google.com>

Change-Id: I2aa75f88409309e3f9b9bd79b52d27c0061139c8
Reviewed-on: https://chromium-review.googlesource.com/373362
Commit-Ready: Furquan Shaikh <furquan@chromium.org>
Tested-by: Furquan Shaikh <furquan@chromium.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
2016-08-21 12:04:56 -07:00
..
tpm UPSTREAM: tpm2: Fixed typo 2016-08-19 14:20:07 -07:00
adesto.c drivers/spi: Pass flash parameters from coreboot to payload 2015-04-17 09:21:07 +02:00
amic.c drivers/spi: Pass flash parameters from coreboot to payload 2015-04-17 09:21:07 +02:00
atmel.c drivers/spi: Pass flash parameters from coreboot to payload 2015-04-17 09:21:07 +02:00
boot_device_rw_nommap.c UPSTREAM: drivers/spi: provide optional implementation of boot_device_rw() 2016-08-21 12:04:56 -07:00
cbfs_spi.c UPSTREAM: lib/cbfs_spi: provide boot_device_rw() support 2016-08-19 14:20:26 -07:00
eon.c spi: Add function to read flash status register 2015-04-17 09:21:22 +02:00
gigadevice.c tree: drop last paragraph of GPL copyright header 2015-10-31 21:37:39 +01:00
Kconfig UPSTREAM: drivers/spi: provide optional implementation of boot_device_rw() 2016-08-21 12:04:56 -07:00
macronix.c tree: drop last paragraph of GPL copyright header 2015-10-31 21:37:39 +01:00
Makefile.inc UPSTREAM: drivers/spi: provide optional implementation of boot_device_rw() 2016-08-21 12:04:56 -07:00
spansion.c tree: drop last paragraph of GPL copyright header 2015-10-31 21:37:39 +01:00
spi_flash.c UPSTREAM: drivers/spi: ensure SPI flash is boot device for coreboot tables 2016-08-21 12:04:51 -07:00
spi_flash_internal.h spi: Add function to read flash status register 2015-04-17 09:21:22 +02:00
spiconsole.c UPSTREAM: Remove extra newlines from the end of all coreboot files. 2016-08-04 23:36:56 -07:00
sst.c spi/SST: fix write support for SST25VF064C 2016-03-11 18:55:51 +01:00
stmicro.c UPSTREAM: drivers/spi: Add support for Micron N25Q128A 2016-08-12 13:44:56 -07:00
winbond.c spi: Add support for Winbond W25Q256 2016-05-09 08:30:22 +02:00