summaryrefslogtreecommitdiff
path: root/src/include/spi-generic.h
diff options
context:
space:
mode:
authorRichard Spiegel <richard.spiegel@amd.corp-partner.google.com>2019-09-03 11:54:55 -0700
committerMartin Roth <martinroth@google.com>2019-09-04 22:40:46 +0000
commit563b8694d247b718f6288b54f0d4055cefec40a8 (patch)
tree05d8a47de8ea82207a020b3619048fb5b27730ca /src/include/spi-generic.h
parent28086f0d2c6b8a321087d6bd201e8caa72996522 (diff)
drivers/spi/spi_flash.c: Add SPI vendor IDs
Currently SPI vendor IDs are magic numbers in spi_flash.c. These definitions are needed for AMD's fch_spi. So add the definitions to spi_generic.h and use it at spi_flash.c BUG=b:136595978 TEST=Build test of several platforms that don't use stoneyridge. Build and boot grunt (using stoneyridge new fch_spi). Change-Id: Ie39485d8c092151db8c9d88afaf02e19c507c93f Signed-off-by: Richard Spiegel <richard.spiegel@silverbackltd.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/35240 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Felix Held <felix-coreboot@felixheld.de> Reviewed-by: Martin Roth <martinroth@google.com>
Diffstat (limited to 'src/include/spi-generic.h')
-rw-r--r--src/include/spi-generic.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/include/spi-generic.h b/src/include/spi-generic.h
index ffd3d2d008..c8dbb6798a 100644
--- a/src/include/spi-generic.h
+++ b/src/include/spi-generic.h
@@ -28,6 +28,19 @@
#include <stdint.h>
#include <stddef.h>
+/* SPI vendor IDs */
+#define VENDOR_ID_ADESTO 0x1f
+#define VENDOR_ID_AMIC 0x37
+#define VENDOR_ID_ATMEL 0x1f
+#define VENDOR_ID_EON 0x1c
+#define VENDOR_ID_GIGADEVICE 0xc8
+#define VENDOR_ID_MACRONIX 0xc2
+#define VENDOR_ID_SPANSION 0x01
+#define VENDOR_ID_SST 0xbf
+#define VENDOR_ID_STMICRO 0x20
+#define VENDOR_ID_STMICRO_FF 0xff
+#define VENDOR_ID_WINBOND 0xef
+
/* Controller-specific definitions: */
struct spi_ctrlr;