summaryrefslogtreecommitdiffstats
path: root/spi.h
diff options
context:
space:
mode:
authorNico Huber <nico.h@gmx.de>2017-10-14 18:56:50 +0200
committerNico Huber <nico.h@gmx.de>2017-12-28 10:48:28 +0000
commit7e3c81ae7122120fe10d43fcba61a513e2461de9 (patch)
treef505342cd2879b9cc77c2cbf66dda0231869ee9c /spi.h
parent0ee2dc06839d2f4f3197dd0ef51202e51e945bea (diff)
downloadflashrom-7e3c81ae7122120fe10d43fcba61a513e2461de9.tar.gz
flashrom-7e3c81ae7122120fe10d43fcba61a513e2461de9.tar.bz2
flashrom-7e3c81ae7122120fe10d43fcba61a513e2461de9.zip
spi25: Merge remainder of spi4ba in
Change-Id: If581e24347e45cbb27002ea99ffd70e334c110cf Signed-off-by: Nico Huber <nico.h@gmx.de> Reviewed-on: https://review.coreboot.org/22388 Reviewed-by: David Hendricks <david.hendricks@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'spi.h')
-rw-r--r--spi.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/spi.h b/spi.h
index 41b02456e..4da7b73f3 100644
--- a/spi.h
+++ b/spi.h
@@ -138,6 +138,18 @@
#define JEDEC_WRSR_OUTSIZE 0x02
#define JEDEC_WRSR_INSIZE 0x00
+/* Enter 4-byte Address Mode */
+#define JEDEC_ENTER_4_BYTE_ADDR_MODE 0xB7
+
+/* Exit 4-byte Address Mode */
+#define JEDEC_EXIT_4_BYTE_ADDR_MODE 0xE9
+
+/* Write Extended Address Register */
+#define JEDEC_WRITE_EXT_ADDR_REG 0xC5
+
+/* Read Extended Address Register */
+#define JEDEC_READ_EXT_ADDR_REG 0xC8
+
/* Read the memory */
#define JEDEC_READ 0x03
#define JEDEC_READ_OUTSIZE 0x04
@@ -154,6 +166,14 @@
#define JEDEC_AAI_WORD_PROGRAM_CONT_OUTSIZE 0x03
#define JEDEC_AAI_WORD_PROGRAM_INSIZE 0x00
+/* Read the memory with 4-byte address
+ From ANY mode (3-bytes or 4-bytes) it works with 4-byte address */
+#define JEDEC_READ_4BA 0x13
+
+/* Write memory byte with 4-byte address
+ From ANY mode (3-bytes or 4-bytes) it works with 4-byte address */
+#define JEDEC_BYTE_PROGRAM_4BA 0x12
+
/* Error codes */
#define SPI_GENERIC_ERROR -1
#define SPI_INVALID_OPCODE -2