spi_gpio.h 724 B

12345678910111213141516171819202122232425
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef __LINUX_SPI_GPIO_H
  3. #define __LINUX_SPI_GPIO_H
  4. /*
  5. * For each bitbanged SPI bus, set up a platform_device node with:
  6. * - name "spi_gpio"
  7. * - id the same as the SPI bus number it implements
  8. * - dev.platform data pointing to a struct spi_gpio_platform_data
  9. *
  10. * Use spi_board_info with these busses in the usual way.
  11. *
  12. * If the bitbanged bus is later switched to a "native" controller,
  13. * that platform_device and controller_data should be removed.
  14. */
  15. /**
  16. * struct spi_gpio_platform_data - parameter for bitbanged SPI master
  17. * @num_chipselect: how many slaves to allow
  18. */
  19. struct spi_gpio_platform_data {
  20. u16 num_chipselect;
  21. };
  22. #endif /* __LINUX_SPI_GPIO_H */