Skip to content

Commit

Permalink
spi: tegra114: correct register name in definition
Browse files Browse the repository at this point in the history
According to "Tegra K1 Processor Technical Reference Manual" (p. 2448),
bit 20 of SPI_COMMAND1 is called CS_SW_VAL and not CS_SS_VAL.

Signed-off-by: Ralf Ramsauer <ralf.ramsauer@oth-regensburg.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Ralf Ramsauer authored and Mark Brown committed Oct 9, 2017
1 parent 2bd6bf0 commit 979a9af
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/spi/spi-tegra114.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
#define SPI_IDLE_SDA_PULL_LOW (2 << 18)
#define SPI_IDLE_SDA_PULL_HIGH (3 << 18)
#define SPI_IDLE_SDA_MASK (3 << 18)
#define SPI_CS_SS_VAL (1 << 20)
#define SPI_CS_SW_VAL (1 << 20)
#define SPI_CS_SW_HW (1 << 21)
/* SPI_CS_POL_INACTIVE bits are default high */
/* n from 0 to 3 */
Expand Down Expand Up @@ -705,9 +705,9 @@ static u32 tegra_spi_setup_transfer_one(struct spi_device *spi,

command1 |= SPI_CS_SW_HW;
if (spi->mode & SPI_CS_HIGH)
command1 |= SPI_CS_SS_VAL;
command1 |= SPI_CS_SW_VAL;
else
command1 &= ~SPI_CS_SS_VAL;
command1 &= ~SPI_CS_SW_VAL;

tegra_spi_writel(tspi, 0, SPI_COMMAND2);
} else {
Expand Down

0 comments on commit 979a9af

Please sign in to comment.