summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorOleksandr Suvorov <oleksandr.suvorov@toradex.com>2020-02-21 15:00:18 +0200
committerMarcel Ziswiler <marcel.ziswiler@toradex.com>2020-03-09 13:44:55 +0100
commitf801d134e8f3b5b6d09d25e2dd7b48aa74d9ffbb (patch)
treec38c65a299acf85fd508c63fb8970014e2cd61d0 /drivers
parent6a04cac4f6f5a4848dd535e90f706c7d2981a197 (diff)
spi: spidev: fix debug message value
The debug message in spidev_message() shows wrong xfer speed: ... [ 1227.702714] spidev spi0.0: setup mode 0, 32 bits/w, 20000000 Hz max --> 0 (real speed sets to 20000000Hz) [ 1227.731801] spidev spi0.0: xfer len 4096 tx 32bits 0 usec 10000000Hz (debug message shows 10000000Hz that is the original max speed of this spidev set from DT) ... Fix the data source for the debug message. Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/spi/spidev.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c
index 2f7bb823ce1b..0140e51a4e2c 100644
--- a/drivers/spi/spidev.c
+++ b/drivers/spi/spidev.c
@@ -281,13 +281,13 @@ static int spidev_message(struct spidev_data *spidev,
#ifdef VERBOSE
dev_dbg(&spidev->spi->dev,
" xfer len %u %s%s%s%dbits %u usec %uHz\n",
- u_tmp->len,
- u_tmp->rx_buf ? "rx " : "",
- u_tmp->tx_buf ? "tx " : "",
- u_tmp->cs_change ? "cs " : "",
- u_tmp->bits_per_word ? : spidev->spi->bits_per_word,
- u_tmp->delay_usecs,
- u_tmp->speed_hz ? : spidev->spi->max_speed_hz);
+ k_tmp->len,
+ k_tmp->rx_buf ? "rx " : "",
+ k_tmp->tx_buf ? "tx " : "",
+ k_tmp->cs_change ? "cs " : "",
+ k_tmp->bits_per_word ? : spidev->spi->bits_per_word,
+ k_tmp->delay_usecs,
+ k_tmp->speed_hz ? : spidev->spi->max_speed_hz);
#endif
spi_message_add_tail(k_tmp, &msg);
}