1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 * Copyright (C) 2005 Stephen Street / StreetFire Sound Labs
5 #ifndef __linux_pxa2xx_spi_h
6 #define __linux_pxa2xx_spi_h
8 #include <linux/pxa2xx_ssp.h>
10 #define PXA2XX_CS_ASSERT (0x01)
11 #define PXA2XX_CS_DEASSERT (0x02)
15 /* device.platform_data for SSP controller devices */
16 struct pxa2xx_spi_controller {
22 /* DMA engine specific config */
23 bool (*dma_filter)(struct dma_chan *chan, void *param);
27 /* For non-PXA arches */
28 struct ssp_device ssp;
31 /* spi_board_info.controller_data for SPI slave devices,
32 * copied to spi_device.platform_data ... mostly for dma tuning
34 struct pxa2xx_spi_chip {
42 void (*cs_control)(u32 command);
45 #if defined(CONFIG_ARCH_PXA) || defined(CONFIG_ARCH_MMP)
47 #include <linux/clk.h>
49 extern void pxa2xx_set_spi_info(unsigned id, struct pxa2xx_spi_controller *info);