Fix lpc17_40_spi.c:341:12: error: variable 'regval' set but not use

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao 2022-11-02 20:30:08 +08:00 committed by Petro Karashchenko
parent 923c779c83
commit 116ba80ad5
1 changed files with 1 additions and 1 deletions

View File

@ -352,7 +352,7 @@ static void spi_setbits(struct spi_dev_s *dev, int nbits)
regval &= ~SPI_CR_BITS_MASK;
regval |= (nbits << SPI_CR_BITS_SHIFT) & SPI_CR_BITS_MASK;
regval |= SPI_CR_BITENABLE;
regval = getreg32(LPC17_40_SPI_CR);
putreg32(regval, LPC17_40_SPI_CR);
/* Save the selection so that subsequent re-configurations will be
* faster.