~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/include/linux/platform_data/spi-davinci.h

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* SPDX-License-Identifier: GPL-2.0-or-later */
  2 /*
  3  * Copyright 2009 Texas Instruments.
  4  */
  5 
  6 #ifndef __ARCH_ARM_DAVINCI_SPI_H
  7 #define __ARCH_ARM_DAVINCI_SPI_H
  8 
  9 #include <linux/platform_data/edma.h>
 10 
 11 #define SPI_INTERN_CS   0xFF
 12 
 13 enum {
 14         SPI_VERSION_1, /* For DM355/DM365/DM6467 */
 15         SPI_VERSION_2, /* For DA8xx */
 16 };
 17 
 18 /**
 19  * davinci_spi_platform_data - Platform data for SPI master device on DaVinci
 20  *
 21  * @version:    version of the SPI IP. Different DaVinci devices have slightly
 22  *              varying versions of the same IP.
 23  * @num_chipselect: number of chipselects supported by this SPI master
 24  * @intr_line:  interrupt line used to connect the SPI IP to the ARM interrupt
 25  *              controller withn the SoC. Possible values are 0 and 1.
 26  * @cshold_bug: set this to true if the SPI controller on your chip requires
 27  *              a write to CSHOLD bit in between transfers (like in DM355).
 28  * @dma_event_q: DMA event queue to use if SPI_IO_TYPE_DMA is used for any
 29  *              device on the bus.
 30  */
 31 struct davinci_spi_platform_data {
 32         u8                      version;
 33         u8                      num_chipselect;
 34         u8                      intr_line;
 35         u8                      prescaler_limit;
 36         bool                    cshold_bug;
 37         enum dma_event_q        dma_event_q;
 38 };
 39 
 40 /**
 41  * davinci_spi_config - Per-chip-select configuration for SPI slave devices
 42  *
 43  * @wdelay:     amount of delay between transmissions. Measured in number of
 44  *              SPI module clocks.
 45  * @odd_parity: polarity of parity flag at the end of transmit data stream.
 46  *              0 - odd parity, 1 - even parity.
 47  * @parity_enable: enable transmission of parity at end of each transmit
 48  *              data stream.
 49  * @io_type:    type of IO transfer. Choose between polled, interrupt and DMA.
 50  * @timer_disable: disable chip-select timers (setup and hold)
 51  * @c2tdelay:   chip-select setup time. Measured in number of SPI module clocks.
 52  * @t2cdelay:   chip-select hold time. Measured in number of SPI module clocks.
 53  * @t2edelay:   transmit data finished to SPI ENAn pin inactive time. Measured
 54  *              in number of SPI clocks.
 55  * @c2edelay:   chip-select active to SPI ENAn signal active time. Measured in
 56  *              number of SPI clocks.
 57  */
 58 struct davinci_spi_config {
 59         u8      wdelay;
 60         u8      odd_parity;
 61         u8      parity_enable;
 62 #define SPI_IO_TYPE_INTR        0
 63 #define SPI_IO_TYPE_POLL        1
 64 #define SPI_IO_TYPE_DMA         2
 65         u8      io_type;
 66         u8      timer_disable;
 67         u8      c2tdelay;
 68         u8      t2cdelay;
 69         u8      t2edelay;
 70         u8      c2edelay;
 71 };
 72 
 73 #endif  /* __ARCH_ARM_DAVINCI_SPI_H */
 74 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php