aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorHaolin Li2021-11-06 03:03:34 -0700
committerStefano Babic2022-02-05 13:38:39 +0100
commit6f753d8cea77e1c3bda84237be786118d0cc719d (patch)
treeae9716278432f74bc696c35bde94a16924c37bd3 /drivers
parent556523b95530709a7049ec0ba26d1a2f9f262573 (diff)
spi: mxc_spi: remove redundant code in spi_xchg_single()
The value of cnt is overwritten without being used. Signed-off-by: Haolin Li <li.haolin@qq.com> Reviewed-by: Fabio Estevam <festevam@gmail.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/spi/mxc_spi.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/spi/mxc_spi.c b/drivers/spi/mxc_spi.c
index 3c53de165dd..5adfdf8b5fc 100644
--- a/drivers/spi/mxc_spi.c
+++ b/drivers/spi/mxc_spi.c
@@ -391,8 +391,6 @@ int spi_xchg_single(struct mxc_spi_slave *mxcs, unsigned int bitlen,
nbytes = DIV_ROUND_UP(bitlen, 8);
- cnt = nbytes % 32;
-
if (bitlen % 32) {
data = reg_read(&regs->rxdata);
cnt = (bitlen % 32) / 8;