summaryrefslogtreecommitdiff
path: root/include/spi.h
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2020-01-27 19:57:13 -0500
committerTom Rini <trini@konsulko.com>2020-01-27 19:57:13 -0500
commit86e42b3629c212d98c7a17e36bd6c0702dcd864c (patch)
treea7c9c9fb26d88d3bab2f529ddda92a03caf6996e /include/spi.h
parent0ab16bf3b72c3f89b29048fcd6d11a51aedd786d (diff)
parentdaa9405d7c4bdbabe257b03d268277f249bb3297 (diff)
Merge branch 'master' of https://gitlab.denx.de/u-boot/custodians/u-boot-spi
- spi cs accessing slaves (Bin Meng) - spi prevent overriding established bus (Marcin Wojtas) - support speed in spi command (Marek Vasut) - add W25N01GV spinand (Robert Marko) - move cadence_qspi to use spi-mem (Vignesh Raghavendra) - add octal mode (Vignesh Raghavendra)
Diffstat (limited to 'include/spi.h')
-rw-r--r--include/spi.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/spi.h b/include/spi.h
index ba2c8406b2e..852f570eaa8 100644
--- a/include/spi.h
+++ b/include/spi.h
@@ -30,6 +30,8 @@
#define SPI_RX_SLOW BIT(11) /* receive with 1 wire slow */
#define SPI_RX_DUAL BIT(12) /* receive with 2 wires */
#define SPI_RX_QUAD BIT(13) /* receive with 4 wires */
+#define SPI_TX_OCTAL BIT(14) /* transmit with 8 wires */
+#define SPI_RX_OCTAL BIT(15) /* receive with 8 wires */
/* Header byte that marks the start of the message */
#define SPI_PREAMBLE_END_BYTE 0xec
@@ -561,7 +563,8 @@ int spi_chip_select(struct udevice *slave);
* @bus: SPI bus to search
* @cs: Chip select to look for
* @devp: Returns the slave device if found
- * @return 0 if found, -ENODEV on error
+ * @return 0 if found, -EINVAL if cs is invalid, -ENODEV if no device attached,
+ * other -ve value on error
*/
int spi_find_chip_select(struct udevice *bus, int cs, struct udevice **devp);