mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 13:53:33 +00:00
spi: pxa2xx: Get rid of unused enable_loopback member
There is no user of the enable_loopback member in the struct pxa2xx_spi_chip. Remote this legacy member completely. The mentioned in the documentation the testing phase can be performed with spidev_test tool. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20211123192723.44537-3-andriy.shevchenko@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
a9c8f68ce2
commit
8393961c53
3 changed files with 2 additions and 10 deletions
|
@ -101,7 +101,6 @@ device. All fields are optional.
|
||||||
u8 rx_threshold;
|
u8 rx_threshold;
|
||||||
u8 dma_burst_size;
|
u8 dma_burst_size;
|
||||||
u32 timeout;
|
u32 timeout;
|
||||||
u8 enable_loopback;
|
|
||||||
int gpio_cs;
|
int gpio_cs;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -128,11 +127,6 @@ dependent on the SPI bus speed ("spi_board_info.max_speed_hz") and the specific
|
||||||
slave device. Please note that the PXA2xx SSP 1 does not support trailing byte
|
slave device. Please note that the PXA2xx SSP 1 does not support trailing byte
|
||||||
timeouts and must busy-wait any trailing bytes.
|
timeouts and must busy-wait any trailing bytes.
|
||||||
|
|
||||||
The "pxa2xx_spi_chip.enable_loopback" field is used to place the SSP porting
|
|
||||||
into internal loopback mode. In this mode the SSP controller internally
|
|
||||||
connects the SSPTX pin to the SSPRX pin. This is useful for initial setup
|
|
||||||
testing.
|
|
||||||
|
|
||||||
NOTE: the SPI driver cannot control the chip select if SSPFRM is used, so the
|
NOTE: the SPI driver cannot control the chip select if SSPFRM is used, so the
|
||||||
chipselect is dropped after each spi_transfer. Most devices need chip select
|
chipselect is dropped after each spi_transfer. Most devices need chip select
|
||||||
asserted around the complete message. Use SSPFRM as a GPIO (through a descriptor)
|
asserted around the complete message. Use SSPFRM as a GPIO (through a descriptor)
|
||||||
|
|
|
@ -1289,7 +1289,6 @@ static int setup(struct spi_device *spi)
|
||||||
chip_info = spi->controller_data;
|
chip_info = spi->controller_data;
|
||||||
|
|
||||||
/* chip_info isn't always needed */
|
/* chip_info isn't always needed */
|
||||||
chip->cr1 = 0;
|
|
||||||
if (chip_info) {
|
if (chip_info) {
|
||||||
if (chip_info->timeout)
|
if (chip_info->timeout)
|
||||||
chip->timeout = chip_info->timeout;
|
chip->timeout = chip_info->timeout;
|
||||||
|
@ -1300,9 +1299,9 @@ static int setup(struct spi_device *spi)
|
||||||
if (chip_info->rx_threshold)
|
if (chip_info->rx_threshold)
|
||||||
rx_thres = chip_info->rx_threshold;
|
rx_thres = chip_info->rx_threshold;
|
||||||
chip->dma_threshold = 0;
|
chip->dma_threshold = 0;
|
||||||
if (chip_info->enable_loopback)
|
|
||||||
chip->cr1 = SSCR1_LBM;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
chip->cr1 = 0;
|
||||||
if (spi_controller_is_slave(drv_data->controller)) {
|
if (spi_controller_is_slave(drv_data->controller)) {
|
||||||
chip->cr1 |= SSCR1_SCFR;
|
chip->cr1 |= SSCR1_SCFR;
|
||||||
chip->cr1 |= SSCR1_SCLKDIR;
|
chip->cr1 |= SSCR1_SCLKDIR;
|
||||||
|
|
|
@ -42,7 +42,6 @@ struct pxa2xx_spi_chip {
|
||||||
u8 rx_threshold;
|
u8 rx_threshold;
|
||||||
u8 dma_burst_size;
|
u8 dma_burst_size;
|
||||||
u32 timeout;
|
u32 timeout;
|
||||||
u8 enable_loopback;
|
|
||||||
int gpio_cs;
|
int gpio_cs;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue