mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-28 23:23:55 +08:00
4d1d49858c
This removes the dependency on GPIO framework and lets the SPI host driver handle the chip select. The SPI host driver is required to keep the CS active for the entire message unless cs_change says otherwise. This patch collects the two/three single SPI transfers into a message. Also the delay in read path in case use_dummy_writes are not used is moved into the SPI host driver. Tested-by: Mike Rapoport <mike@compulab.co.il> Tested-by: Andrey Yurovsky <andrey@cozybit.com> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Acked-by: Dan Williams <dcbw@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
30 lines
907 B
C
30 lines
907 B
C
/*
|
|
* board-specific data for the libertas_spi driver.
|
|
*
|
|
* Copyright 2008 Analog Devices Inc.
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation; either version 2 of the License, or (at
|
|
* your option) any later version.
|
|
*/
|
|
#ifndef _LIBERTAS_SPI_H_
|
|
#define _LIBERTAS_SPI_H_
|
|
|
|
struct spi_device;
|
|
|
|
struct libertas_spi_platform_data {
|
|
/* There are two ways to read data from the WLAN module's SPI
|
|
* interface. Setting 0 or 1 here controls which one is used.
|
|
*
|
|
* Usually you want to set use_dummy_writes = 1.
|
|
* However, if that doesn't work or if you are using a slow SPI clock
|
|
* speed, you may want to use 0 here. */
|
|
u16 use_dummy_writes;
|
|
|
|
/* Board specific setup/teardown */
|
|
int (*setup)(struct spi_device *spi);
|
|
int (*teardown)(struct spi_device *spi);
|
|
};
|
|
#endif
|