Merge tag 'gfs2-v5.16-rc2-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-block.git] / include / linux / spi / spi_gpio.h
CommitLineData
b2441318 1/* SPDX-License-Identifier: GPL-2.0 */
d29389de
DB
2#ifndef __LINUX_SPI_GPIO_H
3#define __LINUX_SPI_GPIO_H
4
5/*
6 * For each bitbanged SPI bus, set up a platform_device node with:
7 * - name "spi_gpio"
8 * - id the same as the SPI bus number it implements
9 * - dev.platform data pointing to a struct spi_gpio_platform_data
10 *
9b00bc7b 11 * Use spi_board_info with these busses in the usual way.
3c8e1a84 12 *
d29389de
DB
13 * If the bitbanged bus is later switched to a "native" controller,
14 * that platform_device and controller_data should be removed.
15 */
16
17/**
18 * struct spi_gpio_platform_data - parameter for bitbanged SPI master
d29389de 19 * @num_chipselect: how many slaves to allow
d29389de
DB
20 */
21struct spi_gpio_platform_data {
d29389de
DB
22 u16 num_chipselect;
23};
24
25#endif /* __LINUX_SPI_GPIO_H */