summaryrefslogtreecommitdiff
path: root/include/spi.h
diff options
context:
space:
mode:
authorNikita Kiryanov <nikita@compulab.co.il>2013-10-16 17:23:26 +0300
committerAnatolij Gustschin <agust@denx.de>2013-11-12 10:03:45 +0100
commit4700219dce2b6b5163207fbbd9b57a2e1b03582d (patch)
treee9147b391895633d5b928579ebb96e1d069aaed9 /include/spi.h
parent5753d09b1064a669e3be8f27e0f1fd008b96934a (diff)
downloadu-boot-imx-4700219dce2b6b5163207fbbd9b57a2e1b03582d.zip
u-boot-imx-4700219dce2b6b5163207fbbd9b57a2e1b03582d.tar.gz
u-boot-imx-4700219dce2b6b5163207fbbd9b57a2e1b03582d.tar.bz2
spi: define SPI_XFER_ONCE
The flag combination "SPI_XFER_BEGIN | SPI_XFER_END" is a common use case of spi_xfer, and it can easily cause an already long line (spi_xfer takes 5 parameters) to go over the 80 character limit. define SPI_XFER_ONCE to be a shorter version of the above flag combination. Cc: Tom Rini <trini@ti.com> Cc: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com> Cc: Igor Grinberg <grinberg@compulab.co.il> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
Diffstat (limited to 'include/spi.h')
-rw-r--r--include/spi.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/spi.h b/include/spi.h
index 67da75c..e2563c9 100644
--- a/include/spi.h
+++ b/include/spi.h
@@ -29,6 +29,7 @@
#define SPI_XFER_END 0x02 /* Deassert CS after transfer */
#define SPI_XFER_MMAP 0x08 /* Memory Mapped start */
#define SPI_XFER_MMAP_END 0x10 /* Memory Mapped End */
+#define SPI_XFER_ONCE (SPI_XFER_BEGIN | SPI_XFER_END)
/* Header byte that marks the start of the message */
#define SPI_PREAMBLE_END_BYTE 0xec